I'm tring to open box2d debugDraw in Lua. As I know in Cpp, we need to override CCLayer:draw() function. But in Lua, I can't get the override work done. Did you guys have idea about it?
Asked
Active
Viewed 209 times
1
-
1which Box2D binding are you using? – Tiago Costa Aug 01 '13 at 13:24
-
Hi Tiago, I'm using Tolua++. Actually, I've found a way to get it done. I implement a class in C++ which override the draw method then add it into the layer, it works. – Alex1989 Aug 02 '13 at 01:40
1 Answers
1
I implement a class derived from CCNode in C++ which override the draw method then binding with Lua. Whenever you add it into, it works!

Alex1989
- 21
- 2