[8163] Fixed typo and wrong check affecting threat calculation. Author: SeT
--HG-- branch : trunk
This commit is contained in:
@@ -34,11 +34,9 @@
|
||||
// The pHatingUnit is not used yet
|
||||
float ThreatCalcHelper::calcThreat(Unit* pHatedUnit, Unit* pHatingUnit, float pThreat, SpellSchoolMask schoolMask, SpellEntry const *pThreatSpell)
|
||||
{
|
||||
if(pThreatSpell)
|
||||
{
|
||||
if( Player* modOwner = pHatedUnit->GetSpellModOwner() )
|
||||
if (pThreatSpell)
|
||||
if (Player* modOwner = pHatedUnit->GetSpellModOwner())
|
||||
modOwner->ApplySpellMod(pThreatSpell->Id, SPELLMOD_THREAT, pThreat);
|
||||
}
|
||||
|
||||
float threat = pHatedUnit->ApplyTotalThreatModifier(pThreat, schoolMask);
|
||||
return threat;
|
||||
|
||||
Reference in New Issue
Block a user