#GitHub - eprosync/plugin_ljpatch: Patche...
1 messages · Page 1 of 1 (latest)
iirc table.insert was also changed to return the index to which the element was added, which seems to be missing in your LuaJIT version, which could break some things that depend on it.
The change:
Is this part of rolling release or 2.1.0 beta 3 tag?
thx i'll add it in
Got it working on all archs and platforms
weirdly enough found an issue with sdk-minimal, with the "serverside" attribute for premake...
doesn't realize that on x86_64 beta branch the libtier0_srv.so doesn't seem to exist on x86
@night berry https://github.com/RaphaelIT7/gmod-lua-shared/blob/main/LuaJIT-2.1/src/lj_lex.c#L370
On my build this failed on comments such as "/* **/" as it was skipping an extra token
I fixed it here with your initial:
https://github.com/eprosync/LuaJIT/blob/gmsupport/src/lj_lex.c#L318C14-L318C54
❤️
@night berry Another thing I found is that lua_newthread needs to have it's luabase allocated from the main thread.
This is so that coroutines support gmod's interface, otherwise its a crash from luabase being null.
Just add a L1->luabase = L->luabase here to fix crashes with coroutines:
https://github.com/RaphaelIT7/gmod-lua-shared/blob/main/LuaJIT-2.1/src/lj_api.c#L796
- just found out about this btw on my version of LJ lmao
I'll check it out when I'm home ❤️
I think I had assumed that lj_state_new already covered it since I remember adding a call in there that does it already
github isn't show me a reference to the definition of it
ah
ok its fine
I tested LJPatch on a 135 addon and 6 module server
just putting the L1->luabase = L->luabase in lua_newthread seems to be fine but for builds not associated with patching might break for my versions
lol lj_state_new is only used once 😂
You should probably check all the places where I had added lua_init_gmod_stack and see if your missing it in your calls anywhere.
I think in the luajit profiler callback for example it was required too