[b39-svn-5045] Epidemic - resist field not being passed

Where bugs go to lie down and rest

Moderator: Moderator

Post Reply
Message
Author
johnnyzero
Thalore
Posts: 148
Joined: Tue Feb 28, 2012 6:36 am

[b39-svn-5045] Epidemic - resist field not being passed

#1 Post by johnnyzero »

I encountered this bug when fighting with a plaugebringer branded weapon. When epidemic is triggered and not resisted by an enemy, a nil value lua error pops up (and pops up each time the epidemic spreads). Apparently, this stems from a resist value never being passed to the epidemic disease effect.

Code: Select all

in game\modules\tome\data\talents\corruptions\plague.lua:
line 249:     target:setEffect(disease.id, 6, {src=self, dam=disease.params.dam, str=disease.params.str, dex=disease.params.dex, con=disease.params.con, heal_factor=disease.params.heal_factor, burst=disease.params.burst, rot_timer=disease.params.rot_timer, apply_power=self:combatSpellpower()}) 
This is where the effect is generated. The epidemic effect references eff.resist on activation/deactivation but resist is not passed as an argument.

Code: Select all

in game\modules\tome\data\timed_effects\magical.lua:
line 1492:     eff.immid = self:addTemporaryValue("disease_immune", -eff.resist / 100)
By passing resist=disease.params.resist as an extra parameter in the above target:setEffect() call, the errors are fixed and the talent appears to be working as intended.

edge2054
Retired Ninja
Posts: 3756
Joined: Fri May 28, 2010 4:38 pm

Re: [b39-svn-5045] Epidemic - resist field not being passed

#2 Post by edge2054 »

Thanks, patch sent to Darkgod.

Post Reply