add character bindings to remove special cases in ScreenStage

This commit is contained in:
Glenn Maynard
2005-06-19 22:41:12 +00:00
parent 4a10567362
commit 92f49b2f89
3 changed files with 37 additions and 0 deletions
+20
View File
@@ -163,6 +163,26 @@ bool Character::Has2DElems()
return false;
}
// lua start
#include "LuaBinding.h"
template<class T>
class LunaCharacter : public Luna<T>
{
public:
LunaCharacter() { LUA->Register( Register ); }
static int GetStageIconPath( T* p, lua_State *L ) { lua_pushstring(L, p->GetStageIconPath() ); return 1; }
static void Register( Lua *L )
{
ADD_METHOD( GetStageIconPath )
Luna<T>::Register( L );
}
};
LUA_REGISTER_CLASS( Character )
// lua end
/*
* (c) 2003 Chris Danford
* All rights reserved.