Page 1 of 1

[SVN 2801+] Alchemist on AI freezes game with ammo

Posted: Tue Feb 22, 2011 7:51 pm
by complexityQuantifier
If you put your alchemist on AI control (by controlling your golem, for example), you get an infinite number of these errors:

Eridan 5269 tactical ai talents testing Shockwave Bomb T_SHOCKWAVE_BOMB
Lua Error: /data/talents/spells/explosives.lua:194: attempt to index global 'ammo' (a nil value)
At [C]:-1
At /data/talents/spells/explosives.lua:194
At (tail call):-1
At /mod/ai//tactical.lua:17
At (tail call):-1
At /mod/ai//tactical.lua:272
At (tail call):-1
At /mod/ai//party.lua:34
At (tail call):-1
At (tail call):-1
At /mod/class/NPC.lua:47 act
At /engine/GameEnergyBased.lua:73 tick
At /engine/GameTurnBased.lua:44 tick
At /mod/class/Game.lua:655

Re: [SVN 2801+] Alchemist on AI freezes game with ammo

Posted: Tue Feb 22, 2011 8:13 pm
by complexityQuantifier
Oops, no, turns out to be any attempt to use Shockwave Bomb (including from the AI) that runs into problems.

Re: [SVN 2801+] Alchemist on AI freezes game with ammo

Posted: Tue Feb 22, 2011 9:47 pm
by yufra
Thanks for finding that, (untested) fix attached. Can you apply it and check?

Re: [SVN 2801+] Alchemist on AI freezes game with ammo

Posted: Wed Feb 23, 2011 12:19 am
by complexityQuantifier
That fixes all of the crashes I could find, and everything seems to work.