mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 13:41:31 +00:00
[Spells] Support for 'HateAdded' spell field to apply negative values to reduce hate. (#1953)
* HateAdded field can be negative * [Spells] Support for 'HateAdded' spell field to apply negative values to reduce hate.
This commit is contained in:
parent
7b235a6ede
commit
00c41dda8c
@ -1319,10 +1319,10 @@ int32 Mob::CheckAggroAmount(uint16 spell_id, Mob *target, bool isproc)
|
||||
if (dispel && target && target->GetHateAmount(this) < 100)
|
||||
AggroAmount += 50;
|
||||
|
||||
if (spells[spell_id].hate_added > 0) // overrides the hate (ex. tash)
|
||||
if (spells[spell_id].hate_added != 0) // overrides the hate (ex. tash), can be negative.
|
||||
AggroAmount = spells[spell_id].hate_added;
|
||||
|
||||
if (GetOwner() && IsPet())
|
||||
if (GetOwner() && IsPet() && AggroAmount > 0)
|
||||
AggroAmount = AggroAmount * RuleI(Aggro, PetSpellAggroMod) / 100;
|
||||
|
||||
// hate focus ignored on first action for some reason
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user