mirror of
https://github.com/EQEmu/Server.git
synced 2026-03-24 03:22:26 +00:00
[Spells] Update to SPA305 (#1545)
minor fix to allow for effects with negative values.
This commit is contained in:
parent
fa8d8eccc2
commit
442850aebb
@ -1256,8 +1256,11 @@ void Mob::ApplyAABonuses(const AA::Rank &rank, StatBonuses *newbon)
|
|||||||
}
|
}
|
||||||
|
|
||||||
case SE_MitigateDamageShield: {
|
case SE_MitigateDamageShield: {
|
||||||
if (base1 < 0)
|
|
||||||
|
//AA that increase mitigation are set to negative.
|
||||||
|
if (base1 < 0) {
|
||||||
base1 = base1 * (-1);
|
base1 = base1 * (-1);
|
||||||
|
}
|
||||||
|
|
||||||
newbon->DSMitigationOffHand += base1;
|
newbon->DSMitigationOffHand += base1;
|
||||||
break;
|
break;
|
||||||
@ -2663,8 +2666,15 @@ void Mob::ApplySpellsBonuses(uint16 spell_id, uint8 casterlevel, StatBonuses *ne
|
|||||||
|
|
||||||
case SE_MitigateDamageShield:
|
case SE_MitigateDamageShield:
|
||||||
{
|
{
|
||||||
if (effect_value < 0)
|
/*
|
||||||
effect_value = effect_value*-1;
|
Bard songs have identical negative base value and positive max
|
||||||
|
The effect for the songs should increase mitigation. There are
|
||||||
|
spells that do decrease the mitigation with just negative base values.
|
||||||
|
To be consistent all values that increase mitigation will be set to positives
|
||||||
|
*/
|
||||||
|
if (max > 0 && effect_value < 0) {
|
||||||
|
effect_value = max;
|
||||||
|
}
|
||||||
|
|
||||||
new_bonus->DSMitigationOffHand += effect_value;
|
new_bonus->DSMitigationOffHand += effect_value;
|
||||||
break;
|
break;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user