From 8f379e7e3149c53b622d489066e8c86ccd7d3fc0 Mon Sep 17 00:00:00 2001 From: Stoabrogga Date: Mon, 9 Dec 2024 23:09:12 +0100 Subject: [PATCH] Fix Rate.Creature.SpellDamage (#2846) --- src/game/Objects/SpellCaster.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/game/Objects/SpellCaster.cpp b/src/game/Objects/SpellCaster.cpp index fe5b880f019..191d8770a26 100644 --- a/src/game/Objects/SpellCaster.cpp +++ b/src/game/Objects/SpellCaster.cpp @@ -1091,6 +1091,9 @@ float SpellCaster::MeleeDamageBonusDone(Unit const* pVictim, float pdamage, Weap // ==================== float DonePercent = 1.0f; + if (!isWeaponDamageBasedSpell && GetTypeId() == TYPEID_UNIT && !(IsPet() && ((Creature*)this)->GetOwnerGuid().IsPlayer())) + DonePercent *= Creature::_GetSpellDamageMod(((Creature*)this)->GetCreatureInfo()->rank); + // ..done pct, already included in weapon damage based spells if (pUnit && !isWeaponDamageBasedSpell) { @@ -1319,7 +1322,7 @@ float SpellCaster::SpellDamageBonusDone(Unit const* pVictim, SpellEntry const* s Item* pWeapon = GetTypeId() == TYPEID_PLAYER ? ((Player*)this)->GetWeaponForAttack(BASE_ATTACK, true, false) : nullptr; // Creature damage - if (GetTypeId() == TYPEID_UNIT && !((Creature*)this)->IsPet()) + if (GetTypeId() == TYPEID_UNIT && !(IsPet() && ((Creature*)this)->GetOwnerGuid().IsPlayer())) DoneTotalMod *= Creature::_GetSpellDamageMod(((Creature*)this)->GetCreatureInfo()->rank); if (pUnit)