diff --git a/src/lua_mathlib.c b/src/lua_mathlib.c index dd91a0d56..9f30738b2 100644 --- a/src/lua_mathlib.c +++ b/src/lua_mathlib.c @@ -122,7 +122,7 @@ static int lib_fixedsqrt(lua_State *L) static int lib_fixedhypot(lua_State *L) { - lua_pushfixed(L, R_PointToDist2(0, 0, luaL_checkfixed(L, 1), luaL_checkfixed(L, 2))); + lua_pushfixed(L, FixedHypot(luaL_checkfixed(L, 1), luaL_checkfixed(L, 2))); return 1; } @@ -195,8 +195,6 @@ static luaL_Reg lib[] = { {"fixint" , lib_fixedint}, {"FixedDiv", lib_fixeddiv}, {"fixdiv" , lib_fixeddiv}, - {"FixedRem", lib_fixedrem}, - {"fixrem" , lib_fixedrem}, {"FixedSqrt", lib_fixedsqrt}, {"fixsqrt" , lib_fixedsqrt}, {"FixedHypot", lib_fixedhypot}, diff --git a/src/lua_script.c b/src/lua_script.c index aaae6eb53..4d02ee413 100644 --- a/src/lua_script.c +++ b/src/lua_script.c @@ -430,6 +430,8 @@ int LUA_WriteGlobals(lua_State *L, const char *word) gravity = (fixed_t)luaL_checkinteger(L, 2); else if (fastcmp(word, "stoppedclock")) stoppedclock = luaL_checkboolean(L, 2); + /* + // KART TODO: displayplayers is a table... else if (fastcmp(word, "displayplayer")) { player_t *player = *((player_t **)luaL_checkudata(L, 2, META_PLAYER)); @@ -437,6 +439,7 @@ int LUA_WriteGlobals(lua_State *L, const char *word) if (player) displayplayer = player - players; } + */ else if (fastcmp(word, "mapmusname")) { size_t strlength; diff --git a/src/lua_skinlib.c b/src/lua_skinlib.c index 3a6fa9ead..4213e7e09 100644 --- a/src/lua_skinlib.c +++ b/src/lua_skinlib.c @@ -36,7 +36,6 @@ enum skin { skin_highresscale, skin_rivals, skin_soundsid, - skin_availability, skin_sprites }; static const char *const skin_opt[] = { @@ -55,7 +54,6 @@ static const char *const skin_opt[] = { "highresscale", "rivals", "soundsid", - "availability", "sprites", NULL }; @@ -119,9 +117,6 @@ static int skin_get(lua_State *L) case skin_soundsid: LUA_PushUserdata(L, skin->soundsid, META_SOUNDSID); break; - case skin_availability: - lua_pushinteger(L, skin->availability); - break; case skin_sprites: LUA_PushLightUserdata(L, skin->sprites, META_SKINSPRITES); break; diff --git a/src/r_skins.c b/src/r_skins.c index 135221ea6..57995b0f5 100644 --- a/src/r_skins.c +++ b/src/r_skins.c @@ -34,6 +34,8 @@ INT32 numskins = 0; skin_t skins[MAXSKINS]; +INT32 numfollowers = 0; + // FIXTHIS: don't work because it must be inistilised before the config load //#define SKINVALUES #ifdef SKINVALUES