Omnomasaur

I'm in your city, eatin' your buildings.

C++ and Lua

 

Last Friday (April 25, 2012) I was given the impromptu task of programming something “cool” in 1 hour.

I decided that I would attempt to implement Lua scripting with C++.

One hour (and countless linker errors) later I had managed to get a program to run scripts from a .lua file, Hello World for this project.

Even knowing that Lua was created to be a scripting language embedded within other programs, I was still surprised at just how easy this was to do, and while due to the time restriction I was unable to implement some of the more advanced features (such as exposing c++ variables, classes, and methods for use in Lua scripts) it was still a good project.

In the future I plan to experiment with the more advanced features I couldn’t get to, as well as implement Lua scripting capabilities into future games I create.

Source Code:

http://www.omnomasaur.com/content/upload/lua-test.zip

||

This entry was posted on Wednesday, April 25th, 2012 at 2:14 am and is filed under Programming. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

Leave a Reply





XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>