Fix bugs and small changes to other thing

This commit is contained in:
Squishy (C6H12O6+NaCl+H2O)
2024-01-07 18:45:21 +07:00
parent 65c050f6df
commit 2816a76f5a
6 changed files with 9 additions and 6 deletions

View File

@@ -787,7 +787,7 @@ function draw.norm(P,repMode)
gc_scale(P.size)
-- Draw username
if usingMod() and P.frameRun>480 then
if GAME.modUsed and P.frameRun>480 or true then
setFont(30)
gc_setColor(GROUP_COLORS[P.group])
GC.mStr(P.username or USERS.getUsername(P.uid),300,-60)

View File

@@ -181,7 +181,7 @@ local function _executeMod(P)
if not GAME.modCodeList then GAME.modCodeList={} end
if not GAME.modCodeList[P.id] then GAME.modCodeList[P.id]={} end
if not GAME.applyModTask then
if not GAME.applyModsTask then
function GAME.applyModsTask()
while GAME.playing do
for _,p in pairs(GAME.modCodeList) do
@@ -190,8 +190,8 @@ local function _executeMod(P)
coroutine.yield()
end
-- Kill mod patching function when game stopped
TABLE.clear(GAME.modCodeList)
TASK.removeTask_code(GAME.applyModsTask)
TABLE.clear(GAME.modCodeList)
GAME.modCodeList=nil
GAME.applyModsTask=nil
end