Here is an excerpt from the crash log:
[00:06:13]: [string "scripts/stategraphs/SGcanarypoisoned.lua"]:33: variable 'data' is not declared LUA ERROR stack traceback: =[C]:-1 in (global) error (C) <-1--1> scripts/strict.lua:23 in () ? (Lua) <21-26> scripts/stategraphs/SGcanarypoisoned.lua:33 in (field) fn (Lua) <31-39> scripts/stategraph.lua:468 in (method) HandleEvent (Lua) <463-471> scripts/stategraph.lua:479 in (method) HandleEvents (Lua) <473-488> scripts/stategraph.lua:154 in (method) UpdateEvents (Lua) <148-157> scripts/stategraph.lua:145 in (method) Update (Lua) <109-146> scripts/update.lua:288 in () ? (Lua) <224-298>
It seems to be caused by an undeclared variable data on line 33 of the file stategraphs\SGcanarypoisoned.lua.
EventHandler("attacked", function(inst) --??? <--- Perhaps 'data' should be a parameter for this function if not inst.components.health:IsDead() then if CommonHandlers.TryElectrocuteOnAttacked(inst, data) then --!!! this is LINE 33 <--- 'data' is not declared return elseif not inst.sg:HasAnyStateTag("noattack", "nohit", "electrocute") then inst.sg:GoToState("hit") end end end),
Steps to Reproduce
- Start a new world without any mods enabled.
- Execute c_spawn("canary_poisoned") to spawn a Volatile Canary on the ground.
- Attack the canary with your bare hands.
Note that the game will crash as long as your attack doesn't kill it in one hit.
A developer has marked this issue as fixed. This means that the issue has been addressed in the current development build and will likely be in the next update.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now