change arg order
This commit is contained in:
@@ -140,7 +140,7 @@ void LuaHelpers::ReadArrayFromTableB( Lua *L, vector<bool> &aOut )
|
||||
static int LuaPanic( lua_State *L )
|
||||
{
|
||||
RString sErr;
|
||||
LuaHelpers::Pop( sErr, L );
|
||||
LuaHelpers::Pop( L, sErr );
|
||||
|
||||
lua_Debug ar;
|
||||
int level = 0;
|
||||
@@ -507,7 +507,7 @@ bool LuaHelpers::RunScript( Lua *L, const RString &sScript, const RString &sName
|
||||
|
||||
if( ret )
|
||||
{
|
||||
LuaHelpers::Pop( sError, L );
|
||||
LuaHelpers::Pop( L, sError );
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -517,7 +517,7 @@ bool LuaHelpers::RunScript( Lua *L, const RString &sScript, const RString &sName
|
||||
int ret = lua_pcall( L, 0, iReturnValues, 0 );
|
||||
if( ret )
|
||||
{
|
||||
LuaHelpers::Pop( sError, L );
|
||||
LuaHelpers::Pop( L, sError );
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -608,7 +608,7 @@ bool LuaHelpers::RunExpressionS( const RString &str, RString &sOut )
|
||||
if( lua_isfunction( L, -1 ) )
|
||||
RageException::Throw( "Result is a function; did you forget \"()\"?" );
|
||||
|
||||
LuaHelpers::Pop( sOut, L );
|
||||
LuaHelpers::Pop( L, sOut );
|
||||
|
||||
LUA->Release( L );
|
||||
return true;
|
||||
|
||||
@@ -91,7 +91,7 @@ namespace LuaHelpers
|
||||
bool FromStack( Lua *L, RString &Object, int iOffset );
|
||||
|
||||
template<class T>
|
||||
bool Pop( T &val, lua_State *L )
|
||||
bool Pop( lua_State *L, T &val )
|
||||
{
|
||||
bool bRet = LuaHelpers::FromStack( L, val, -1 );
|
||||
lua_pop( L, 1 );
|
||||
@@ -109,7 +109,7 @@ namespace LuaHelpers
|
||||
{
|
||||
lua_rawgeti( L, -1, i+1 );
|
||||
T value = T();
|
||||
LuaHelpers::Pop( value, L );
|
||||
LuaHelpers::Pop( L, value );
|
||||
aOut.push_back( value );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -170,7 +170,7 @@ void MenuTimer::SetText( float fSeconds )
|
||||
lua_call(L, 1, 1);
|
||||
|
||||
RString sText;
|
||||
LuaHelpers::Pop( sText, L );
|
||||
LuaHelpers::Pop( L, sText );
|
||||
|
||||
m_text[i].SetText( sText );
|
||||
}
|
||||
|
||||
@@ -169,7 +169,7 @@ void PercentageDisplay::Refresh()
|
||||
ASSERT( !lua_isnil(L, -1) );
|
||||
LuaHelpers::Push( fPercentDancePoints, L );
|
||||
lua_call( L, 1, 1 ); // 1 args, 1 result
|
||||
LuaHelpers::Pop( sNumToDisplay, L );
|
||||
LuaHelpers::Pop( L, sNumToDisplay );
|
||||
LUA->Release(L);
|
||||
|
||||
// HACK: Use the last frame in the numbers texture as '-'
|
||||
|
||||
@@ -85,7 +85,7 @@ void IPreference::SetFromStack( lua_State *L )
|
||||
} \
|
||||
template<> void PrefSetFromStack( lua_State *L, type &v ) \
|
||||
{ \
|
||||
LuaHelpers::Pop( v, L ); \
|
||||
LuaHelpers::Pop( L, v ); \
|
||||
} \
|
||||
template<> void PrefPushValue( lua_State *L, const type &v ) \
|
||||
{ \
|
||||
|
||||
@@ -321,7 +321,7 @@ public:
|
||||
else
|
||||
{
|
||||
m_Value.Unset();
|
||||
LuaHelpers::Pop( m_currentValue, L );
|
||||
LuaHelpers::Pop( L, m_currentValue );
|
||||
}
|
||||
|
||||
LUA->Release(L);
|
||||
@@ -349,7 +349,7 @@ public:
|
||||
m_Value.PushSelf( L );
|
||||
lua_call(L, 0, 1);
|
||||
ASSERT( !lua_isnil(L, -1) );
|
||||
LuaHelpers::Pop( m_currentValue, L );
|
||||
LuaHelpers::Pop( L, m_currentValue );
|
||||
LUA->Release(L);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user