aboutsummaryrefslogtreecommitdiff
path: root/src/game/Unit.cpp
diff options
context:
space:
mode:
authorclick <none@none>2010-05-22 07:05:40 +0200
committerclick <none@none>2010-05-22 07:05:40 +0200
commit18f3d29caff48ccfa4a5ad81ed080177d87ee4ef (patch)
treef628c08469000a8ebf56bdb1df3967da8cf3d4b0 /src/game/Unit.cpp
parent70a44e8d0ed2a7f8186f3c274d384d703bc89dc3 (diff)
Change some casts in Unit.cpp (old typos) - tip from RaptorTeak, original fix by zergtmn
Fixes issue #2300 --HG-- branch : trunk
Diffstat (limited to 'src/game/Unit.cpp')
-rw-r--r--src/game/Unit.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index 221e4f2b859..13538a74541 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -560,7 +560,7 @@ void Unit::DealDamageMods(Unit *pVictim, uint32 &damage, uint32* absorb)
if (!pVictim->isAlive() || pVictim->hasUnitState(UNIT_STAT_UNATTACKABLE) || pVictim->GetTypeId() == TYPEID_UNIT && pVictim->ToCreature()->IsInEvadeMode())
{
if (absorb)
- absorb += damage;
+ *absorb += damage;
damage = 0;
return;
}
@@ -573,7 +573,7 @@ void Unit::DealDamageMods(Unit *pVictim, uint32 &damage, uint32* absorb)
if (area && area->IsSanctuary()) //sanctuary
{
if (absorb)
- absorb += damage;
+ *absorb += damage;
damage = 0;
}
}
@@ -581,7 +581,7 @@ void Unit::DealDamageMods(Unit *pVictim, uint32 &damage, uint32* absorb)
uint32 originalDamage = damage;
if (absorb && originalDamage > damage)
- absorb += (originalDamage - damage);
+ *absorb += (originalDamage - damage);
}
uint32 Unit::DealDamage(Unit *pVictim, uint32 damage, CleanDamage const* cleanDamage, DamageEffectType damagetype, SpellSchoolMask damageSchoolMask, SpellEntry const *spellProto, bool durabilityLoss)