item stat 624 (hate gain % mod) now supported
This commit is contained in:
parent
a7260e9f72
commit
097ee61ea4
@ -1329,7 +1329,7 @@ float Entity::CalculateMitigation(int8 type, int8 damage_type, int16 effective_l
|
|||||||
void Entity::AddHate(Entity* attacker, sint32 hate, bool ignore_pet_behavior) {
|
void Entity::AddHate(Entity* attacker, sint32 hate, bool ignore_pet_behavior) {
|
||||||
if(!attacker || GetHP() <= 0 || attacker->GetHP() <= 0)
|
if(!attacker || GetHP() <= 0 || attacker->GetHP() <= 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if(IsInSpawnGroup(attacker))
|
if(IsInSpawnGroup(attacker))
|
||||||
return; // can't aggro your own members
|
return; // can't aggro your own members
|
||||||
|
|
||||||
@ -1933,8 +1933,11 @@ sint32 Entity::CalculateHateAmount(Spawn* target, sint32 amt) {
|
|||||||
amt = CalculateFormulaByStat(amt, ITEM_STAT_TAUNT_AND_COMBAT_ART_DAMAGE);
|
amt = CalculateFormulaByStat(amt, ITEM_STAT_TAUNT_AND_COMBAT_ART_DAMAGE);
|
||||||
|
|
||||||
amt = CalculateFormulaByStat(amt, ITEM_STAT_ABILITY_MODIFIER);
|
amt = CalculateFormulaByStat(amt, ITEM_STAT_ABILITY_MODIFIER);
|
||||||
|
|
||||||
return amt;
|
float multiplier = 1.0f + (GetInfoStruct()->get_hate_mod() / 100.0f);
|
||||||
|
amt = static_cast<sint32>(amt * multiplier);
|
||||||
|
|
||||||
|
return std::max(1, amt);
|
||||||
}
|
}
|
||||||
|
|
||||||
sint32 Entity::CalculateHealAmount(Spawn* target, sint32 amt, int8 crit_mod, bool* crit, bool skip_crit_mod) {
|
sint32 Entity::CalculateHealAmount(Spawn* target, sint32 amt, int8 crit_mod, bool* crit, bool skip_crit_mod) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user