Fix addonloaded hook

This commit is contained in:
NepDisk 2025-12-13 12:52:02 -05:00
parent 1fbdf0f0ec
commit 46ab8191f7

View file

@ -62,6 +62,7 @@
#include "lua_script.h"
#include "g_game.h" // G_MapNumber
#include "r_patchrotation.h"
#include "lua_hook.h"
#include "k_terrain.h"
@ -1117,6 +1118,10 @@ UINT16 W_InitFile(const char *filename, boolean mainfile, boolean startup, boole
G_LoadGameData();
DEH_UpdateMaxFreeslots();
lua_lumploading++;
LUA_HookVoid(HOOK(AddonLoaded));
lua_lumploading--;
W_InvalidateLumpnumCache();
return wadfile->numlumps;
}