simpler Lua boilerplate

This commit is contained in:
Glenn Maynard
2006-09-27 20:03:31 +00:00
parent ea7c05cee5
commit 153bcedd40
19 changed files with 64 additions and 96 deletions
+3 -5
View File
@@ -275,8 +275,6 @@ void GraphDisplay::UpdateVerts()
class LunaGraphDisplay: public Luna<GraphDisplay>
{
public:
LunaGraphDisplay() { LUA->Register( Register ); }
static int LoadFromStats( T* p, lua_State *L )
{
StageStats *pStageStats = Luna<StageStats>::check( L, 1 );
@@ -285,11 +283,11 @@ public:
return 0;
}
static void Register(lua_State *L)
LunaGraphDisplay()
{
ADD_METHOD( LoadFromStats );
LUA->Register( Register );
Luna<T>::Register( L );
ADD_METHOD( LoadFromStats );
}
};