Skip to content
This repository

Simple C++ bindings for Lua

branch: master

LuaCppBridge51 is a library to expose C++ classes to Lua. You pick a class from the library to derive from, add the desired methods, properties, etc and register it into Lua. It is a very simple wrapper that does not aim to expose already existing C++ classes. There are lots of libraries for that (Simple Lua Binder, LuaBind, OOLua, etc).

LuaCppBridge51 builds on ideas from binding classes using Lunar and Lua Technical Note 5. It builds on Lunar, adding the following:

  • allows you to define properties, by means of getter/setter methods in C++.
  • retrieve Lua instances from C++ callbacks

The following were already present in Lunar:

  • add new class methods from Lua
  • simple inheritance (make a C++ class inherit from a "class" in Lua, or viceversa)

More detailed documentation is available on the wiki

Something went wrong with that request. Please try again.