Core/Unit: Renamed addUnitState/hasUnitState/clearUnitState to AddUnitState/HasUnitState/ClearUnitState

Core/Vehicles: Allow the vehicle to always damage the passenger (removed unneded dbc hacks from scripts)

--HG--
branch : trunk
This commit is contained in:
Shauren
2010-12-17 13:43:24 +01:00
parent ee3fd3ebeb
commit 82f45966fc
99 changed files with 353 additions and 361 deletions
@@ -337,7 +337,7 @@ class boss_vazruden_the_herald : public CreatureScript
VazrudenGUID = 0;
}
summoned = false;
me->clearUnitState(UNIT_STAT_ROOT);
me->ClearUnitState(UNIT_STAT_ROOT);
me->SetVisible(true);
}
}
@@ -352,7 +352,7 @@ class boss_vazruden_the_herald : public CreatureScript
NazanGUID = Nazan->GetGUID();
summoned = true;
me->SetVisible(false);
me->addUnitState(UNIT_STAT_ROOT);
me->AddUnitState(UNIT_STAT_ROOT);
}
}
@@ -267,7 +267,7 @@ class boss_magtheridon : public CreatureScript
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_OOC_NOT_ATTACKABLE);
me->addUnitState(UNIT_STAT_STUNNED);
me->AddUnitState(UNIT_STAT_STUNNED);
DoCast(me, SPELL_SHADOW_CAGE_C, true);
}
@@ -348,7 +348,7 @@ class boss_magtheridon : public CreatureScript
void AttackStart(Unit *who)
{
if (!me->hasUnitState(UNIT_STAT_STUNNED))
if (!me->HasUnitState(UNIT_STAT_STUNNED))
ScriptedAI::AttackStart(who);
}
@@ -402,7 +402,7 @@ class boss_magtheridon : public CreatureScript
if (BlastNova_Timer <= diff)
{
// to avoid earthquake interruption
if (!me->hasUnitState(UNIT_STAT_STUNNED))
if (!me->HasUnitState(UNIT_STAT_STUNNED))
{
DoScriptText(EMOTE_BLASTNOVA, me);
DoCast(me, SPELL_BLASTNOVA);
@@ -445,7 +445,7 @@ class boss_magtheridon : public CreatureScript
if (!Phase3 && HealthBelowPct(30)
&& !me->IsNonMeleeSpellCasted(false) // blast nova
&& !me->hasUnitState(UNIT_STAT_STUNNED)) // shadow cage and earthquake
&& !me->HasUnitState(UNIT_STAT_STUNNED)) // shadow cage and earthquake
{
Phase3 = true;
DoScriptText(SAY_CHAMBER_DESTROY, me);
@@ -224,7 +224,7 @@ class instance_magtheridons_lair : public InstanceMapScript
Creature* Magtheridon = instance->GetCreature(MagtheridonGUID);
if (Magtheridon && Magtheridon->isAlive())
{
Magtheridon->clearUnitState(UNIT_STAT_STUNNED);
Magtheridon->ClearUnitState(UNIT_STAT_STUNNED);
Magtheridon->AI()->AttackStart(Magtheridon->SelectNearestTarget(999));
}
CageTimer = 0;