Closed X3N0-Life-Form closed 7 years ago
Additionnal info, the jan 2nd nightly complains, but the feb 2nd does not.
WARNING: "step 1" at base.cpp:34
testWARNING: "step 2" at base.cpp:34
(null)WARNING: "step 3" at base.cpp:34
Lua Error: LUA ERROR: [string "test-sct.tbm - On Game Init"]:14: attempt to index field 'does not exist' (a nil value)
------------------------------------------------------------------
ADE Debug:
------------------------------------------------------------------
------------------------------------------------------------------
------------------------------------------------------------------
stack traceback:
[C]: ?
[string "test-sct.tbm - On Game Init"]:14: in main chunk
------------------------------------------------------------------
------------------------------------------------------------------
Can you narrow down which nightly build works and which doesn't?
Did some further testing, something broke between the january 2nd & 3rd builds.
There was a change to how the lua functions were handled in that nightly so that is likely the cause.
Found the issue, I'm an idiot.
While doing some scripting, I noticed some functions would just stop way before hitting "return".
After a bit of digging, it turns out that the lua interpreter does not always throw a warning when attempting to index a nil value, but seemingly crashes nonetheless.
For instance, the sample code below throws out warning steps 1 through 3, but not the final warning, and the debug log shows nothing out of the ordinary (see below).
Tested on master pulled & compiled 24 hours ago.
Note : I tried attaching a sample mod, but the upload kept failing for some reason.
Debug log when trying to run the script above