Add -nolua command line parameter

Disables loading Lua scripts entirely.
This commit is contained in:
James R 2023-03-29 09:03:35 -07:00
parent 4588a20a95
commit 542e5b1cdf

View file

@ -36,6 +36,7 @@
#include "doomstat.h"
#include "g_state.h"
#include "m_argv.h"
lua_State *gL = NULL;
@ -579,6 +580,12 @@ void LUA_LoadLump(UINT16 wad, UINT16 lump, boolean noresults)
MYFILE f;
char *name;
size_t len;
if (M_CheckParm("-nolua"))
{
return;
}
f.wad = wad;
f.size = W_LumpLengthPwad(wad, lump);
f.data = Z_Malloc(f.size, PU_LUA, NULL);