Core/Pets: corrected formulars for minion and pet damage values for good this time
* data is based on dr. damage and simulationcraft
This commit is contained in:
1 parent
6a5b23862d
commit
d38dfce011
5 files changed
+30
-9
No files matched your search
@@ -0,0 +1,10 @@
|
||||
DELETE FROM `spell_bonus_data` WHERE `entry` IN (89753, 30213, 3110, 3716, 54049, 7814, 6360, 31707);
|
||||
INSERT INTO `spell_bonus_data` (`entry`, `direct_bonus`, `dot_bonus`, `ap_bonus`, `ap_dot_bonus`, `comments`) VALUES
|
||||
(89753, 0.231, 0, 0, 0, 'Warlock - Fel Storm'),
|
||||
(30213, 0.264, 0, 0, 0, 'Warlock - Legion Strike'),
|
||||
(3110, 0.657, 0, 0, 0, 'Warlock - Firebolt'),
|
||||
(3716, 0.512, 0, 0, 0, 'Warlock - Torment'),
|
||||
(54049, 1.228, 0, 0, 0, 'Warlock - Shadow Bite'),
|
||||
(7814, 0.612, 0, 0, 0, 'Warlock - Lash of Pain'),
|
||||
(6360, 0.85, 0, 0, 0, 'Warlock - Whiplash'),
|
||||
(31707, 0.833, 0, 0, 0, 'Mage - Waterbolt');
|
||||
@@ -1148,7 +1148,7 @@ void Guardian::UpdateDamagePhysical(WeaponAttackType attType)
|
||||
|
||||
void Guardian::SetBonusDamage(int32 damage)
|
||||
{
|
||||
m_bonusSpellDamage = damage;
|
||||
//m_bonusSpellDamage = damage;
|
||||
if (GetOwner()->GetTypeId() == TYPEID_PLAYER)
|
||||
GetOwner()->SetUInt32Value(PLAYER_PET_SPELL_POWER, damage);
|
||||
}
|
||||
@@ -6615,8 +6615,8 @@ uint32 Unit::SpellDamageBonusDone(Unit* victim, SpellInfo const* spellProto, uin
|
||||
if (spellProto->HasAttribute(SPELL_ATTR3_NO_DONE_BONUS))
|
||||
return pdamage;
|
||||
|
||||
// For totems and pets use owner's bonus data
|
||||
if (IsCreature())
|
||||
// Totems get their bonus damage from their owner
|
||||
if (IsCreature() && IsTotem())
|
||||
if (Unit* owner = GetOwner())
|
||||
return owner->SpellDamageBonusDone(victim, spellProto, pdamage, damagetype, effIndex, stack);
|
||||
|
||||
@@ -6653,6 +6653,9 @@ uint32 Unit::SpellDamageBonusDone(Unit* victim, SpellInfo const* spellProto, uin
|
||||
if (!spellProto->HasAttribute(SPELL_ATTR6_LIMIT_PCT_DAMAGE_MODS))
|
||||
DoneTotal += GetTotalAuraModifierByMiscMask(SPELL_AURA_MOD_FLAT_SPELL_DAMAGE_VERSUS, victim->GetCreatureTypeMask());
|
||||
|
||||
// Done fixed damage bonus auras
|
||||
int32 DoneAdvertisedBenefit = SpellBaseDamageBonusDone(spellProto->GetSchoolMask());
|
||||
|
||||
// Custom scripted damage
|
||||
switch (spellProto->SpellFamilyName)
|
||||
{
|
||||
@@ -6661,13 +6664,20 @@ uint32 Unit::SpellDamageBonusDone(Unit* victim, SpellInfo const* spellProto, uin
|
||||
if (spellProto->SpellFamilyFlags[0] & 0x00080000)
|
||||
DoneTotal += (owner->GetTotalAttackPowerValue(RANGED_ATTACK) * 0.4f) * 0.2f;
|
||||
break;
|
||||
case SPELLFAMILY_WARLOCK:
|
||||
// Warlock Minions inherit 50% of their owner's spell power
|
||||
if (IsMinion() && GetOwner())
|
||||
DoneAdvertisedBenefit = owner->SpellBaseDamageBonusDone(spellProto->GetSchoolMask()) * 0.5f;
|
||||
break;
|
||||
case SPELLFAMILY_MAGE:
|
||||
// Mage Water Elementals inherit 40% of their owner's spell power
|
||||
if (IsMinion() && GetOwner())
|
||||
DoneAdvertisedBenefit = owner->SpellBaseDamageBonusDone(spellProto->GetSchoolMask()) * 0.4f;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
// Done fixed damage bonus auras
|
||||
int32 DoneAdvertisedBenefit = SpellBaseDamageBonusDone(spellProto->GetSchoolMask());
|
||||
|
||||
// Check for table values
|
||||
float coeff = spellProto->Effects[effIndex].BonusMultiplier;
|
||||
if (SpellBonusEntry const* bonus = sSpellMgr->GetSpellBonusData(spellProto->Id))
|
||||
|
||||
@@ -1048,6 +1048,7 @@ class TC_GAME_API Unit : public WorldObject
|
||||
uint32 HasUnitTypeMask(uint32 mask) const { return mask & m_unitTypeMask; }
|
||||
void AddUnitTypeMask(uint32 mask) { m_unitTypeMask |= mask; }
|
||||
bool IsSummon() const { return (m_unitTypeMask & UNIT_MASK_SUMMON) != 0; }
|
||||
bool IsMinion() const { return (m_unitTypeMask & UNIT_MASK_MINION) != 0; }
|
||||
bool IsGuardian() const { return (m_unitTypeMask & UNIT_MASK_GUARDIAN) != 0; }
|
||||
bool IsPet() const { return (m_unitTypeMask & UNIT_MASK_PET) != 0; }
|
||||
bool IsHunterPet() const{ return (m_unitTypeMask & UNIT_MASK_HUNTER_PET) != 0; }
|
||||
|
||||
@@ -143,7 +143,7 @@ class spell_warl_pet_scaling_01 : public AuraScript
|
||||
int32 fire = owner->SpellBaseDamageBonusDone(SPELL_SCHOOL_MASK_FIRE);
|
||||
int32 shadow = owner->SpellBaseDamageBonusDone(SPELL_SCHOOL_MASK_SHADOW);
|
||||
|
||||
amount = std::max(fire, shadow) * 0.57f;
|
||||
amount = std::max(fire, shadow);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -158,7 +158,7 @@ class spell_warl_pet_scaling_01 : public AuraScript
|
||||
int32 fire = owner->SpellBaseDamageBonusDone(SPELL_SCHOOL_MASK_FIRE);
|
||||
int32 shadow = owner->SpellBaseDamageBonusDone(SPELL_SCHOOL_MASK_SHADOW);
|
||||
|
||||
amount = std::max(fire, shadow) * 0.15f;
|
||||
amount = std::max(fire, shadow) * 0.5f;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1057,7 +1057,7 @@ class spell_mage_water_elemental_scaling_01 : public AuraScript
|
||||
{
|
||||
if (Player* owner = pet->GetOwner())
|
||||
{
|
||||
float bonusDamage = owner->SpellBaseDamageBonusDone(SPELL_SCHOOL_MASK_FROST) * 0.57f;
|
||||
float bonusDamage = owner->SpellBaseDamageBonusDone(SPELL_SCHOOL_MASK_FROST);
|
||||
amount = int32(bonusDamage);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user