mandag, november 19, 2007

Extension: LuaBindings

Extension name:

LuaBindings

Location:

http://www.daimi.au.dk/~abachn/oe/extensions/LuaBindings/

Purpose:

Create a abstract base class for integrating Lua into OpenEngine. This class should be used as a super class for your more specific extension that wants to execute lua scripts.

Dependencies:


Implementation details:

We have used the standard lua C API to implement the lua integration in OpenEngine. This abstract class gives the ability to run scripts or run entire lua files. Before each run a Pre() method is called and a Post() method os called after the script has run. These can be overwritten in a subclass, but are here given the default behavior of nothing. A default environment is setup before each run. Subclasses have to specify a Init() method when subclassing from this class. This Init method is used to export functions from C++ to lua.

Ingen kommentarer: