From 1be83f77b8fcbe4e12bed6dacb547c53b316c024 Mon Sep 17 00:00:00 2001 From: NepDisk Date: Wed, 21 Jan 2026 14:28:44 -0500 Subject: [PATCH] Use 1.6 version number in compat mode Make sure mods that check version number actually think they are in kart --- src/lua_script.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/lua_script.c b/src/lua_script.c index 6fc1a48d4..f134c0d68 100644 --- a/src/lua_script.c +++ b/src/lua_script.c @@ -356,10 +356,16 @@ int LUA_PushGlobals(lua_State *L, const char *word) lua_pushinteger(L, gravity); return 1; } else if (fastcmp(word,"VERSION")) { - lua_pushinteger(L, VERSION); + if (lua_compatmode) + lua_pushinteger(L, 1); + else + lua_pushinteger(L, VERSION); return 1; } else if (fastcmp(word,"SUBVERSION")) { - lua_pushinteger(L, SUBVERSION); + if (lua_compatmode) + lua_pushinteger(L, 6); + else + lua_pushinteger(L, SUBVERSION); return 1; } else if (fastcmp(word,"VERSIONSTRING")) { lua_pushstring(L, VERSIONSTRING);