Overriding cc.ParticleSystemQuad:updateQuadWithParticle in Lua

Overriding cc.ParticleSystemQuad:updateQuadWithParticle in Lua
0.0 0


I would like to override this method like in the C++ version so I can catch the positions of the particles but cannot figure out how to do so in Lua. Is it possible to override virtual functions in Lua? If not, is there a workaround to get the position of the particles in Lua?


how to inherite native C++ Object and override its functions ?
Hope it can help you.
By the way, it’s in Chinese.


This is not a true override. I essentially want override a virtual method in C*+ so that the ParticleSystem code calls from C*+ into the Lua stack. I don’t think this is possible without some work on registering script handlers. The struct “tParticle” is also not exposed in Lua. Thanks anyway though.


Actually, recently I has gotton a method to solve it.
Here is my blog:[[http://blog.csdn.net/bewithwen/article/details/17094799]]
My GitHub: https://github.com/BeWithWen
I think it would help you.
But it’s also in Chinese. If you cann’t understand it, please send me a email.
Have fun.