revert last

This commit is contained in:
Chris Danford
2005-02-16 21:41:07 +00:00
parent 7e4a302ba4
commit da51076d91
+1 -11
View File
@@ -361,17 +361,7 @@ float LuaManager::RunExpressionF( const CString &str )
int LuaManager::RunExpressionI( const CString &str )
{
if( !RunExpression( str ) )
return 0;
/* Don't accept a function as a return value. */
if( lua_isfunction( L, -1 ) )
RageException::Throw( "result is a function; did you forget \"()\"?" );
int result = (int) lua_tonumber( L, -1 );
lua_pop( L, -1 );
return result;
return (int)RunExpressionF(str);
}
bool LuaManager::RunExpressionS( const CString &str, CString &sOut )