change BArg to look for a Lua boolean type

This commit is contained in:
Chris Danford
2005-02-17 21:34:46 +00:00
parent 0457317a6f
commit 09f19b9d0c
4 changed files with 17 additions and 12 deletions
+1 -1
View File
@@ -25,7 +25,7 @@ public:
* We'd need to break the command helpers into a separate function; RageTexture
* shouldn't depend on Actor. */
static int position( T* p, lua_State *L ) { p->SetPosition(FArg(1)); return 0; }
static int loop( T* p, lua_State *L ) { p->SetLooping(BArg(1)); return 0; }
static int loop( T* p, lua_State *L ) { p->SetLooping(!!IArg(1)); return 0; }
static int rate( T* p, lua_State *L ) { p->SetPlaybackRate(FArg(1)); return 0; }
static void Register(lua_State *L) {