🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

If the static functions have the same name, how to register them respective ?

Started by
1 comment, last by zopenge 16 years, 4 months ago
class A { static void Do( ); }; class B { static void Do( ); }; How to register Do() function of A and B ? thnaks !
Advertisement
You need to give the different names in AngelScript, e.g.

engine->RegisterGlobalFunction("void A_Do()", asFUNCTION(A::Do), asCALL_CDECL);
engine->RegisterGlobalFunction("void B_Do()", asFUNCTION(B::Do), asCALL_CDECL);

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

Thanks :)~

This topic is closed to new replies.

Advertisement