cocos2d-x lua中class的定义

在lua中要实现对类的定义通常都是经过metatable来作到的。。例如:python Fjs = {} function Fjs:new(name) local out = {} setmetatable(out, self) self.__index = self out.name = name return out end function Fjs:sayHello() p
相关文章
相关标签/搜索