diff --git a/source/luaControls.cpp b/source/luaControls.cpp index 560e2d9..7f9e508 100644 --- a/source/luaControls.cpp +++ b/source/luaControls.cpp @@ -72,35 +72,35 @@ static int lua_readright(lua_State *L) static int lua_check(lua_State *L) { - if (lua_gettop(L) != 2) return luaL_error(L, "wrong number of arguments."); - int pad = luaL_checknumber(L, 1); - int button = luaL_checknumber(L, 2); - lua_pushboolean(L, (pad & button)); - return 1; + if (lua_gettop(L) != 2) return luaL_error(L, "wrong number of arguments."); + int pad = luaL_checknumber(L, 1); + int button = luaL_checknumber(L, 2); + lua_pushboolean(L, (pad & button)); + return 1; } static int lua_touchpad(lua_State *L) { - if (lua_gettop(L) != 0) return luaL_error(L, "wrong number of arguments."); - SceTouchData touch; - sceTouchPeek(SCE_TOUCH_PORT_FRONT, &touch, 1); - for (SceUInt32 i=0;imagic != 0x4C464E54) return luaL_error(L, "attempt to access wrong memory block type"); #endif