Core/Misc: Rename UNIT_STAT_* enums to UNIT_STATE_*

This commit is contained in:
Shocker
2012-02-03 19:02:17 +02:00
parent e602619912
commit 08be716ef8
148 changed files with 483 additions and 483 deletions
@@ -2417,7 +2417,7 @@ void AuraEffect::HandleFeignDeath(AuraApplication const* aurApp, uint8 mode, boo
target->VisitNearbyObject(target->GetMap()->GetVisibilityRange(), searcher);
for (UnitList::iterator iter = targets.begin(); iter != targets.end(); ++iter)
{
if (!(*iter)->HasUnitState(UNIT_STAT_CASTING))
if (!(*iter)->HasUnitState(UNIT_STATE_CASTING))
continue;
for (uint32 i = CURRENT_FIRST_NON_MELEE_SPELL; i < CURRENT_MAX_SPELL; i++)
@@ -2448,7 +2448,7 @@ void AuraEffect::HandleFeignDeath(AuraApplication const* aurApp, uint8 mode, boo
// blizz like 2.0.x
target->SetFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_DEAD);
target->AddUnitState(UNIT_STAT_DIED);
target->AddUnitState(UNIT_STATE_DIED);
}
else
{
@@ -2465,7 +2465,7 @@ void AuraEffect::HandleFeignDeath(AuraApplication const* aurApp, uint8 mode, boo
// blizz like 2.0.x
target->RemoveFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_DEAD);
target->ClearUnitState(UNIT_STAT_DIED);
target->ClearUnitState(UNIT_STATE_DIED);
}
}
@@ -3031,7 +3031,7 @@ void AuraEffect::HandleModConfuse(AuraApplication const* aurApp, uint8 mode, boo
Unit* target = aurApp->GetTarget();
target->SetControlled(apply, UNIT_STAT_CONFUSED);
target->SetControlled(apply, UNIT_STATE_CONFUSED);
}
void AuraEffect::HandleModFear(AuraApplication const* aurApp, uint8 mode, bool apply) const
@@ -3041,7 +3041,7 @@ void AuraEffect::HandleModFear(AuraApplication const* aurApp, uint8 mode, bool a
Unit* target = aurApp->GetTarget();
target->SetControlled(apply, UNIT_STAT_FLEEING);
target->SetControlled(apply, UNIT_STATE_FLEEING);
}
void AuraEffect::HandleAuraModStun(AuraApplication const* aurApp, uint8 mode, bool apply) const
@@ -3051,7 +3051,7 @@ void AuraEffect::HandleAuraModStun(AuraApplication const* aurApp, uint8 mode, bo
Unit* target = aurApp->GetTarget();
target->SetControlled(apply, UNIT_STAT_STUNNED);
target->SetControlled(apply, UNIT_STATE_STUNNED);
}
void AuraEffect::HandleAuraModRoot(AuraApplication const* aurApp, uint8 mode, bool apply) const
@@ -3061,7 +3061,7 @@ void AuraEffect::HandleAuraModRoot(AuraApplication const* aurApp, uint8 mode, bo
Unit* target = aurApp->GetTarget();
target->SetControlled(apply, UNIT_STAT_ROOT);
target->SetControlled(apply, UNIT_STATE_ROOT);
}
void AuraEffect::HandlePreventFleeing(AuraApplication const* aurApp, uint8 mode, bool apply) const
@@ -3072,7 +3072,7 @@ void AuraEffect::HandlePreventFleeing(AuraApplication const* aurApp, uint8 mode,
Unit* target = aurApp->GetTarget();
if (target->HasAuraType(SPELL_AURA_MOD_FEAR))
target->SetControlled(!(apply), UNIT_STAT_FLEEING);
target->SetControlled(!(apply), UNIT_STATE_FLEEING);
}
/***************************/
@@ -3465,7 +3465,7 @@ void AuraEffect::HandleAuraModSchoolImmunity(AuraApplication const* aurApp, uint
if (GetSpellInfo()->Mechanic == MECHANIC_BANISH)
{
if (apply)
target->AddUnitState(UNIT_STAT_ISOLATED);
target->AddUnitState(UNIT_STATE_ISOLATED);
else
{
bool banishFound = false;
@@ -3477,7 +3477,7 @@ void AuraEffect::HandleAuraModSchoolImmunity(AuraApplication const* aurApp, uint
break;
}
if (!banishFound)
target->ClearUnitState(UNIT_STAT_ISOLATED);
target->ClearUnitState(UNIT_STATE_ISOLATED);
}
}
@@ -6156,7 +6156,7 @@ void AuraEffect::HandlePeriodicDamageAurasTick(Unit* target, Unit* caster) const
if (!caster || !target->isAlive())
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
if (target->HasUnitState(UNIT_STATE_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
{
SendTickImmune(target, caster);
return;
@@ -6297,7 +6297,7 @@ void AuraEffect::HandlePeriodicHealthLeechAuraTick(Unit* target, Unit* caster) c
if (!caster || !caster->isAlive() || !target->isAlive())
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
if (target->HasUnitState(UNIT_STATE_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
{
SendTickImmune(target, caster);
return;
@@ -6363,7 +6363,7 @@ void AuraEffect::HandlePeriodicHealthFunnelAuraTick(Unit* target, Unit* caster)
if (!caster || !caster->isAlive() || !target->isAlive())
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED))
if (target->HasUnitState(UNIT_STATE_ISOLATED))
{
SendTickImmune(target, caster);
return;
@@ -6391,7 +6391,7 @@ void AuraEffect::HandlePeriodicHealAurasTick(Unit* target, Unit* caster) const
if (!caster || !target->isAlive())
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED))
if (target->HasUnitState(UNIT_STATE_ISOLATED))
{
SendTickImmune(target, caster);
return;
@@ -6507,7 +6507,7 @@ void AuraEffect::HandlePeriodicManaLeechAuraTick(Unit* target, Unit* caster) con
if (!caster || !caster->isAlive() || !target->isAlive() || target->getPowerType() != powerType)
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
if (target->HasUnitState(UNIT_STATE_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
{
SendTickImmune(target, caster);
return;
@@ -6607,7 +6607,7 @@ void AuraEffect::HandleObsModPowerAuraTick(Unit* target, Unit* caster) const
if (!target->isAlive() || !target->GetMaxPower(powerType))
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED))
if (target->HasUnitState(UNIT_STATE_ISOLATED))
{
SendTickImmune(target, caster);
return;
@@ -6638,7 +6638,7 @@ void AuraEffect::HandlePeriodicEnergizeAuraTick(Unit* target, Unit* caster) cons
if (!target->isAlive() || !target->GetMaxPower(powerType))
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED))
if (target->HasUnitState(UNIT_STATE_ISOLATED))
{
SendTickImmune(target, caster);
return;
@@ -6670,7 +6670,7 @@ void AuraEffect::HandlePeriodicPowerBurnAuraTick(Unit* target, Unit* caster) con
if (!caster || !target->isAlive() || target->getPowerType() != powerType)
return;
if (target->HasUnitState(UNIT_STAT_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
if (target->HasUnitState(UNIT_STATE_ISOLATED) || target->IsImmunedToDamage(GetSpellInfo()))
{
SendTickImmune(target, caster);
return;