mirror of
https://github.com/EQEmu/Server.git
synced 2026-02-22 10:32:25 +00:00
Fix for perl CastSpell function so it will use a spells innate resist diff
settings if no override value is put in the function. Due to recent changes in how we defined that variable it would set it to 0 resist diff by default when called from perl.
This commit is contained in:
parent
fc48a109fd
commit
650aa566b0
@ -3971,7 +3971,10 @@ XS(XS_Mob_CastSpell)
|
||||
resist_adjust = (int16)SvIV(ST(6));
|
||||
}
|
||||
|
||||
THIS->CastSpell(spell_id, target_id, slot, casttime, mana_cost, 0, 0xFFFFFFFF, 0xFFFFFFFF, 0, 0, &resist_adjust);
|
||||
if (resist_adjust == 0)//If you do not pass resist adjust as nullptr it will ignore the spells default resist adjust
|
||||
THIS->CastSpell(spell_id, target_id, slot, casttime, mana_cost, 0, 0xFFFFFFFF, 0xFFFFFFFF, 0, 0);
|
||||
else
|
||||
THIS->CastSpell(spell_id, target_id, slot, casttime, mana_cost, 0, 0xFFFFFFFF, 0xFFFFFFFF, 0, 0, &resist_adjust);
|
||||
}
|
||||
XSRETURN_EMPTY;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user