Make K_FindJawzTarget and K_GetKartDriftSparkValue HUD safe

This commit is contained in:
TehRealSalt 2018-11-08 15:11:22 -05:00
parent 03bf72bf9e
commit df3c6051e8
2 changed files with 3 additions and 3 deletions

View file

@ -2335,7 +2335,7 @@ static int lib_kFindJawzTarget(lua_State *L)
{
mobj_t *actor = *((mobj_t **)luaL_checkudata(L, 1, META_MOBJ));
player_t *source = *((player_t **)luaL_checkudata(L, 2, META_PLAYER));
NOHUD
//HUDSAFE
if (!actor)
return LUA_ErrInvalid(L, "mobj_t");
if (!source)
@ -2347,7 +2347,7 @@ static int lib_kFindJawzTarget(lua_State *L)
static int lib_kGetKartDriftSparkValue(lua_State *L)
{
player_t *player = *((player_t **)luaL_checkudata(L, 1, META_PLAYER));
NOHUD
//HUDSAFE
if (!player)
return LUA_ErrInvalid(L, "player_t");
lua_pushinteger(L, K_GetKartDriftSparkValue(player));

View file

@ -729,7 +729,7 @@ static int side_set(lua_State *L)
side->midtexture = luaL_checkinteger(L, 3);
break;
case side_repeatcnt:
side->repeatcnt = luaL_checkinteger(L, 3);
side->repeatcnt = luaL_checkinteger(L, 3);
break;
}
return 0;