A new lua binding layer for cocos2dx base on lua gc

A new lua binding layer for cocos2dx base on lua gc
0

Recently, i design a new lua binding layer for cocos2dx, and it controls life cycle of c++ object by lua gc.

Feature:

  1. manage c++ object by lua gc, it more friendly to developer.
  2. the exported lua binding code is more simple and efficient.
  3. support more lambda function binding(schedule, scheduleOnce, …).
  4. support more api for spine, fairygui, dragonbose.
  5. the binding layer is more simple then tolua++.

The below code it is safety for cocos-lua, and not safety for cocos2d-x official lua binding.

local sprite = cc.Sprite:create()
local funtion update(dt)
    sprite:setFlippedY(true)
end

see more detail: https://github.com/zhongfq/cocos-lua

2 Likes

It looks very nice, I would like to test it .

Have you used it in commercial games?

i use it in my company project, but the project just start for few weeks