Allow passing a lua_State to PushStack; make them static.

Add SetGlobal(bool), UnsetGlobal, PushStackNil.
Pass lua_State* to LUA_RETURN.
This commit is contained in:
Glenn Maynard
2005-01-30 02:01:27 +00:00
parent 02b6b82b53
commit 088b7bb356
5 changed files with 48 additions and 19 deletions
+2 -2
View File
@@ -1245,7 +1245,7 @@ int LuaFunc_##func( lua_State *L ) { \
REQ_ARG( #func, 1, lightuserdata ); \
const Song *p = (const Song *) (lua_touserdata( L, -1 )); \
LUA_ASSERT( CheckPointer(p), ssprintf("%p is not a valid song", p) ); \
LUA_RETURN( call ); \
LUA_RETURN( call, L ); \
} \
LuaFunction( func ); /* register it */
@@ -1272,7 +1272,7 @@ int LuaFunc_##func( lua_State *L ) { \
REQ_ARG( #func, 1, lightuserdata ); \
const Steps *p = (const Steps *) (lua_touserdata( L, -1 )); \
LUA_ASSERT( CheckPointer(p), ssprintf("%p is not a valid steps", p) ); \
LUA_RETURN( call ); \
LUA_RETURN( call, L ); \
} \
LuaFunction( func ); /* register it */
LuaFunction_Steps( StepsMeter, p->GetMeter() );