lanice/elemate — pull request #73 by lanice (2014-01-13 20:59:27+00:00)
Title: Scripting 54

This pull request adds Lua bindings to our C++ project. To use Lua scripts do the following:

* add a .lua script into the scripts/ folder
* instanciate LuaWrapper to initialize Lua (note: PhysicsWrapper already has a LuaWrapper as member m_lua)
* load luascript with m_lua->loadScript("scripts/customscript.lua")
* IMPORTANT: call a function of the lua script with m_lua->callFunc("function", numberOfReturnValues, Arguments...)
* IMPORTANT: Immediately after callFunc(), call m_lua->fetchResults(ResultVariables...) to receive return value(s)

To setup Lua, see https://github.com/lanice/elemate/wiki/Setup-lua