happened while tossing some death knight parts around.. but it mentions torch. I had a torch held in left hand of lead character.
INIT: Parsing configuration file
INIT: Using gamedir test_dungeon (base:0)
INIT: Using color depth of 32
INIT: Starting FMOD
INIT: Setting up triple buffer
LUA: Lua initialized
Parsing base/global.lua
Parsing base/graphics.lua
Parsing base/util.lua
Parsing base/triggers.lua
Parsing base/conditions.lua
Parsing base/monster.lua
Parsing base/methods.lua
Parsing base/damage.lua
Parsing base/xp.lua
Parsing base/magic.lua
Parsing base/msg_handlers.lua
Parsing base/system.lua
Parsing base/startup.lua
Parsing test_dungeon/startup.lua
Parsing base/objects.lua
OBJ: 395 system archs
Parsing test_dungeon/objects.lua
OBJ: 398 total archs
Parsing test_dungeon/dungeon.lua
LUA ERROR: Lua Function torch_3.msg_handler[256]: base/util.lua:492: attempt to perform arithmetic on field 'def_charge' (a nil value)
(fixed) lua crash
Moderator: Sophia
Forum rules
Please read the Forum rules and policies before posting. You may
to help finance the hosting costs of this forum.
Please read the Forum rules and policies before posting. You may

- Sophia
- Concise and Honest
- Posts: 4307
- Joined: Thu Sep 12, 2002 9:50 pm
- Location: Nowhere in particular
- Contact:
Fixed!
It's actually a one-line fix, in case anyone wants to fix their own copy before 0.15 is released.
Find the function torch_value in base/util.lua and look for the line:
Immediately after that line, add:
It's actually a one-line fix, in case anyone wants to fix their own copy before 0.15 is released.
Find the function torch_value in base/util.lua and look for the line:
Code: Select all
if (arch.class ~= "TORCH") then return 0 end
Code: Select all
if (not arch.def_charge) then return 0 end