Core/Script: Code style.
WaypointReached(uint32 i) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 uiPointId) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*point*/) -> WaypointReached(uint32 /*waypointId*/) WaypointReached(uint32 uiI) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*i*/) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 uiWPointId) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*wp*/) -> WaypointReached(uint32 waypointId) WaypointReached(uint32 /*point*/) -> WaypointReached(uint32 waypointId) Signed-off-by: Gyx <[email protected]>
This commit is contained in:
@@ -236,9 +236,9 @@ public:
|
||||
Start(false, false, 0);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 uiPoint)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (uiPoint)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 4:
|
||||
SetEscortPaused(true);
|
||||
|
||||
@@ -115,9 +115,9 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance)
|
||||
if (waypointId == 7 && instance)
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
|
||||
@@ -644,7 +644,11 @@ public:
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
void WaypointReached(uint32 /*i*/){}
|
||||
|
||||
void WaypointReached(uint32 /*waypointId*/)
|
||||
{
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
@@ -111,9 +111,9 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance)
|
||||
if (waypointId == 7 && instance)
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
@@ -241,7 +241,7 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 /*i*/)
|
||||
void WaypointReached(uint32 /*waypointId*/)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -103,9 +103,9 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance)
|
||||
if (waypointId == 7 && instance)
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
|
||||
+2
-2
@@ -105,9 +105,9 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance)
|
||||
if (waypointId == 7 && instance)
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
|
||||
@@ -980,9 +980,9 @@ void hyjalAI::RespawnNearPos(float x, float y)
|
||||
cell.Visit(p, obj_worker, *me->GetMap(), *me, me->GetGridActivationRange());
|
||||
}
|
||||
|
||||
void hyjalAI::WaypointReached(uint32 i)
|
||||
void hyjalAI::WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 1 || (i == 0 && me->GetEntry() == THRALL))
|
||||
if (waypointId == 1 || (waypointId == 0 && me->GetEntry() == THRALL))
|
||||
{
|
||||
me->MonsterYell(YELL_HURRY, 0, 0);
|
||||
WaitForTeleport = true;
|
||||
|
||||
@@ -196,7 +196,7 @@ struct hyjalAI : public npc_escortAI
|
||||
void SummonedCreatureDespawn(Creature* summoned);
|
||||
void HideNearPos(float x, float y);
|
||||
void RespawnNearPos(float x, float y);
|
||||
void WaypointReached(uint32 i);
|
||||
void WaypointReached(uint32 waypointId);
|
||||
void DoOverrun(uint32 faction, const uint32 diff);
|
||||
void MoveInLineOfSight(Unit* who);
|
||||
|
||||
|
||||
@@ -425,9 +425,9 @@ public:
|
||||
|
||||
void EnterCombat(Unit* /*who*/) {}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 0 && instance && !IsOverrun)
|
||||
if (waypointId == 0 && instance && !IsOverrun)
|
||||
{
|
||||
if (instance->GetData(DATA_ALLIANCE_RETREAT))//2.alliance boss down, attack thrall
|
||||
{
|
||||
@@ -550,22 +550,24 @@ public:
|
||||
KnockDownTimer = 10000;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance && !IsOverrun)
|
||||
if (waypointId == 7 && instance && !IsOverrun)
|
||||
{
|
||||
if (instance->GetData(DATA_ALLIANCE_RETREAT))//2.alliance boss down, attack thrall
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}else{
|
||||
}
|
||||
else
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}
|
||||
}
|
||||
if (i == LastOverronPos && IsOverrun)
|
||||
if (waypointId == LastOverronPos && IsOverrun)
|
||||
{
|
||||
if ((faction == 0 && LastOverronPos == 17) || (faction == 1 && LastOverronPos == 21))
|
||||
{
|
||||
@@ -652,22 +654,24 @@ public:
|
||||
RandomMove = false;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance && !IsOverrun)
|
||||
if (waypointId == 7 && instance && !IsOverrun)
|
||||
{
|
||||
if (instance->GetData(DATA_ALLIANCE_RETREAT))//2.alliance boss down, attack thrall
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}else{
|
||||
}
|
||||
else
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}
|
||||
}
|
||||
if (i == LastOverronPos && IsOverrun)
|
||||
if (waypointId == LastOverronPos && IsOverrun)
|
||||
{
|
||||
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_ATTACK_UNARMED);
|
||||
if ((faction == 0 && LastOverronPos == 17) || (faction == 1 && LastOverronPos == 21))
|
||||
@@ -675,7 +679,6 @@ public:
|
||||
me->setDeathState(DEAD);
|
||||
me->RemoveCorpse();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -770,16 +773,18 @@ public:
|
||||
summons.Despawn(summon);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance && !IsOverrun)
|
||||
if (waypointId == 7 && instance && !IsOverrun)
|
||||
{
|
||||
if (instance->GetData(DATA_ALLIANCE_RETREAT))//2.alliance boss down, attack thrall
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}else{
|
||||
}
|
||||
else
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
@@ -888,16 +893,18 @@ public:
|
||||
ShellTimer = 50000+rand()%10000;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance && !IsOverrun)
|
||||
if (waypointId == 7 && instance && !IsOverrun)
|
||||
{
|
||||
if (instance->GetData(DATA_ALLIANCE_RETREAT))//2.alliance boss down, attack thrall
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}else{
|
||||
}
|
||||
else
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
@@ -987,16 +994,18 @@ public:
|
||||
WebTimer = 20000+rand()%5000;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance && !IsOverrun)
|
||||
if (waypointId == 7 && instance && !IsOverrun)
|
||||
{
|
||||
if (instance->GetData(DATA_ALLIANCE_RETREAT))//2.alliance boss down, attack thrall
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}else{
|
||||
}
|
||||
else
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
@@ -1077,16 +1086,18 @@ public:
|
||||
ManaBurnTimer = 9000+rand()%5000;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 7 && instance && !IsOverrun)
|
||||
if (waypointId == 7 && instance && !IsOverrun)
|
||||
{
|
||||
if (instance->GetData(DATA_ALLIANCE_RETREAT))//2.alliance boss down, attack thrall
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
}else{
|
||||
}
|
||||
else
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_JAINAPROUDMOORE));
|
||||
if (target && target->isAlive())
|
||||
me->AddThreat(target, 0.0f);
|
||||
@@ -1170,9 +1181,9 @@ public:
|
||||
me->SetDisableGravity(true);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 2 && instance && !IsOverrun)
|
||||
if (waypointId == 2 && instance && !IsOverrun)
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
@@ -1289,9 +1300,9 @@ public:
|
||||
me->SetDisableGravity(true);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (i == 2 && instance && !IsOverrun)
|
||||
if (waypointId == 2 && instance && !IsOverrun)
|
||||
{
|
||||
Unit* target = Unit::GetUnit((*me), instance->GetData64(DATA_THRALL));
|
||||
if (target && target->isAlive())
|
||||
|
||||
+2
-2
@@ -446,9 +446,9 @@ public:
|
||||
++uiStep;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 uiPointId)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (uiPointId)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0:
|
||||
case 1:
|
||||
|
||||
@@ -296,12 +296,12 @@ public:
|
||||
bool LowHp;
|
||||
bool HadMount;
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (!instance)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 8:
|
||||
SetRun(false);
|
||||
@@ -433,7 +433,6 @@ public:
|
||||
//trigger epoch Yell("Thrall! Come outside and face your fate! ....")
|
||||
//from here, thrall should not never be allowed to move to point 106 which he currently does.
|
||||
break;
|
||||
|
||||
case 106:
|
||||
{
|
||||
//trigger taretha to run down outside
|
||||
@@ -631,9 +630,9 @@ public:
|
||||
|
||||
InstanceScript* instance;
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 6:
|
||||
DoScriptText(SAY_TA_FREE, me);
|
||||
@@ -643,6 +642,7 @@ public:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void Reset() {}
|
||||
void EnterCombat(Unit* /*who*/) {}
|
||||
|
||||
|
||||
@@ -72,55 +72,54 @@ public:
|
||||
{
|
||||
npc_willixAI(Creature* creature) : npc_escortAI(creature) {}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 3:
|
||||
me->HandleEmoteCommand(EMOTE_STATE_POINT);
|
||||
DoScriptText(SAY_POINT, me, player);
|
||||
break;
|
||||
case 4:
|
||||
me->SummonCreature(ENTRY_BOAR, 2137.66f, 1843.98f, 48.08f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 8:
|
||||
DoScriptText(SAY_BLUELEAF, me, player);
|
||||
break;
|
||||
case 9:
|
||||
DoScriptText(SAY_DANGER, me, player);
|
||||
break;
|
||||
case 13:
|
||||
DoScriptText(SAY_BAD, me, player);
|
||||
break;
|
||||
case 14:
|
||||
me->SummonCreature(ENTRY_BOAR, 2078.91f, 1704.54f, 56.77f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 25:
|
||||
DoScriptText(SAY_THINK, me, player);
|
||||
break;
|
||||
case 31:
|
||||
DoScriptText(SAY_SOON, me, player);
|
||||
break;
|
||||
case 42:
|
||||
DoScriptText(SAY_FINALY, me, player);
|
||||
break;
|
||||
case 43:
|
||||
me->SummonCreature(ENTRY_BOAR, 1956.43f, 1596.97f, 81.75f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 45:
|
||||
DoScriptText(SAY_WIN, me, player);
|
||||
me->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
|
||||
if (player->GetTypeId() == TYPEID_PLAYER)
|
||||
CAST_PLR(player)->GroupEventHappens(QUEST_WILLIX_THE_IMPORTER, me);
|
||||
break;
|
||||
case 46:
|
||||
DoScriptText(SAY_END, me, player);
|
||||
break;
|
||||
case 3:
|
||||
me->HandleEmoteCommand(EMOTE_STATE_POINT);
|
||||
DoScriptText(SAY_POINT, me, player);
|
||||
break;
|
||||
case 4:
|
||||
me->SummonCreature(ENTRY_BOAR, 2137.66f, 1843.98f, 48.08f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 8:
|
||||
DoScriptText(SAY_BLUELEAF, me, player);
|
||||
break;
|
||||
case 9:
|
||||
DoScriptText(SAY_DANGER, me, player);
|
||||
break;
|
||||
case 13:
|
||||
DoScriptText(SAY_BAD, me, player);
|
||||
break;
|
||||
case 14:
|
||||
me->SummonCreature(ENTRY_BOAR, 2078.91f, 1704.54f, 56.77f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 25:
|
||||
DoScriptText(SAY_THINK, me, player);
|
||||
break;
|
||||
case 31:
|
||||
DoScriptText(SAY_SOON, me, player);
|
||||
break;
|
||||
case 42:
|
||||
DoScriptText(SAY_FINALY, me, player);
|
||||
break;
|
||||
case 43:
|
||||
me->SummonCreature(ENTRY_BOAR, 1956.43f, 1596.97f, 81.75f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 45:
|
||||
DoScriptText(SAY_WIN, me, player);
|
||||
me->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
|
||||
if (player->GetTypeId() == TYPEID_PLAYER)
|
||||
CAST_PLR(player)->GroupEventHappens(QUEST_WILLIX_THE_IMPORTER, me);
|
||||
break;
|
||||
case 46:
|
||||
DoScriptText(SAY_END, me, player);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -151,35 +151,35 @@ public:
|
||||
uint32 eventProgress;
|
||||
InstanceScript* instance;
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
if (!instance)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 4:
|
||||
eventProgress = 1;
|
||||
currentEvent = TYPE_NARALEX_PART1;
|
||||
instance->SetData(TYPE_NARALEX_PART1, IN_PROGRESS);
|
||||
break;
|
||||
break;
|
||||
case 5:
|
||||
DoScriptText(SAY_MUST_CONTINUE, me);
|
||||
instance->SetData(TYPE_NARALEX_PART1, DONE);
|
||||
break;
|
||||
break;
|
||||
case 11:
|
||||
eventProgress = 1;
|
||||
currentEvent = TYPE_NARALEX_PART2;
|
||||
instance->SetData(TYPE_NARALEX_PART2, IN_PROGRESS);
|
||||
break;
|
||||
break;
|
||||
case 19:
|
||||
DoScriptText(SAY_BEYOND_THIS_CORRIDOR, me);
|
||||
break;
|
||||
break;
|
||||
case 24:
|
||||
eventProgress = 1;
|
||||
currentEvent = TYPE_NARALEX_PART3;
|
||||
instance->SetData(TYPE_NARALEX_PART3, IN_PROGRESS);
|
||||
break;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -76,35 +76,34 @@ class npc_torek : public CreatureScript
|
||||
uint32 Thunderclap_Timer;
|
||||
bool Completed;
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 1:
|
||||
Talk(SAY_MOVE, player->GetGUID());
|
||||
break;
|
||||
case 8:
|
||||
Talk(SAY_PREPARE, player->GetGUID());
|
||||
break;
|
||||
case 19:
|
||||
//TODO: verify location and creatures amount.
|
||||
me->SummonCreature(ENTRY_DURIEL, 1776.73f, -2049.06f, 109.83f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
me->SummonCreature(ENTRY_SILVERWING_SENTINEL, 1774.64f, -2049.41f, 109.83f, 1.40f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
me->SummonCreature(ENTRY_SILVERWING_WARRIOR, 1778.73f, -2049.50f, 109.83f, 1.67f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 20:
|
||||
DoScriptText(SAY_WIN, me, player);
|
||||
Completed = true;
|
||||
player->GroupEventHappens(QUEST_TOREK_ASSULT, me);
|
||||
break;
|
||||
case 21:
|
||||
Talk(SAY_END, player->GetGUID());
|
||||
break;
|
||||
case 1:
|
||||
Talk(SAY_MOVE, player->GetGUID());
|
||||
break;
|
||||
case 8:
|
||||
Talk(SAY_PREPARE, player->GetGUID());
|
||||
break;
|
||||
case 19:
|
||||
//TODO: verify location and creatures amount.
|
||||
me->SummonCreature(ENTRY_DURIEL, 1776.73f, -2049.06f, 109.83f, 1.54f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
me->SummonCreature(ENTRY_SILVERWING_SENTINEL, 1774.64f, -2049.41f, 109.83f, 1.40f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
me->SummonCreature(ENTRY_SILVERWING_WARRIOR, 1778.73f, -2049.50f, 109.83f, 1.67f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
break;
|
||||
case 20:
|
||||
DoScriptText(SAY_WIN, me, player);
|
||||
Completed = true;
|
||||
player->GroupEventHappens(QUEST_TOREK_ASSULT, me);
|
||||
break;
|
||||
case 21:
|
||||
Talk(SAY_END, player->GetGUID());
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -182,32 +181,29 @@ class npc_ruul_snowhoof : public CreatureScript
|
||||
{
|
||||
npc_ruul_snowhoofAI(Creature* creature) : npc_escortAI(creature) { }
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0:
|
||||
me->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
|
||||
if (GameObject* Cage = me->FindNearestGameObject(GO_CAGE, 20))
|
||||
Cage->SetGoState(GO_STATE_ACTIVE);
|
||||
break;
|
||||
|
||||
case 13:
|
||||
me->SummonCreature(3922, 3449.218018f, -587.825073f, 174.978867f, 4.714445f, TEMPSUMMON_DEAD_DESPAWN, 60000);
|
||||
me->SummonCreature(3921, 3446.384521f, -587.830872f, 175.186279f, 4.714445f, TEMPSUMMON_DEAD_DESPAWN, 60000);
|
||||
me->SummonCreature(3926, 3444.218994f, -587.835327f, 175.380600f, 4.714445f, TEMPSUMMON_DEAD_DESPAWN, 60000);
|
||||
break;
|
||||
|
||||
case 19:
|
||||
me->SummonCreature(3922, 3508.344482f, -492.024261f, 186.929031f, 4.145029f, TEMPSUMMON_DEAD_DESPAWN, 60000);
|
||||
me->SummonCreature(3921, 3506.265625f, -490.531006f, 186.740128f, 4.239277f, TEMPSUMMON_DEAD_DESPAWN, 60000);
|
||||
me->SummonCreature(3926, 3503.682373f, -489.393799f, 186.629684f, 4.349232f, TEMPSUMMON_DEAD_DESPAWN, 60000);
|
||||
break;
|
||||
|
||||
case 21:
|
||||
player->GroupEventHappens(QUEST_FREEDOM_TO_RUUL, me);
|
||||
break;
|
||||
@@ -316,17 +312,19 @@ class npc_muglash : public CreatureScript
|
||||
summoned->AI()->AttackStart(me);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0:
|
||||
DoScriptText(SAY_MUG_START2, me, player);
|
||||
if (player)
|
||||
DoScriptText(SAY_MUG_START2, me, player);
|
||||
break;
|
||||
case 24:
|
||||
DoScriptText(SAY_MUG_BRAZIER, me, player);
|
||||
if (player)
|
||||
DoScriptText(SAY_MUG_BRAZIER, me, player);
|
||||
|
||||
if (GameObject* go = GetClosestGameObjectWithEntry(me, GO_NAGA_BRAZIER, INTERACTION_DISTANCE*2))
|
||||
{
|
||||
|
||||
@@ -374,29 +374,28 @@ public:
|
||||
{
|
||||
npc_magwinAI(Creature* creature) : npc_escortAI(creature) {}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0:
|
||||
DoScriptText(SAY_START, me, player);
|
||||
break;
|
||||
case 17:
|
||||
DoScriptText(SAY_PROGRESS, me, player);
|
||||
break;
|
||||
case 28:
|
||||
DoScriptText(SAY_END1, me, player);
|
||||
break;
|
||||
case 29:
|
||||
DoScriptText(EMOTE_HUG, me, player);
|
||||
DoScriptText(SAY_END2, me, player);
|
||||
player->GroupEventHappens(QUEST_A_CRY_FOR_SAY_HELP, me);
|
||||
break;
|
||||
case 0:
|
||||
DoScriptText(SAY_START, me, player);
|
||||
break;
|
||||
case 17:
|
||||
DoScriptText(SAY_PROGRESS, me, player);
|
||||
break;
|
||||
case 28:
|
||||
DoScriptText(SAY_END1, me, player);
|
||||
break;
|
||||
case 29:
|
||||
DoScriptText(EMOTE_HUG, me, player);
|
||||
DoScriptText(SAY_END2, me, player);
|
||||
player->GroupEventHappens(QUEST_A_CRY_FOR_SAY_HELP, me);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -231,13 +231,13 @@ public:
|
||||
{
|
||||
npc_prospector_remtravelAI(Creature* creature) : npc_escortAI(creature) {}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0:
|
||||
DoScriptText(SAY_REM_START, me, player);
|
||||
|
||||
@@ -228,10 +228,11 @@ public:
|
||||
{
|
||||
npc_dalindaAI(Creature* creature) : npc_escortAI(creature) { }
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
switch (i)
|
||||
|
||||
switch (waypointId)
|
||||
{
|
||||
case 1:
|
||||
me->IsStandState();
|
||||
|
||||
@@ -607,49 +607,48 @@ public:
|
||||
{
|
||||
npc_stinkyAI(Creature* creature) : npc_escortAI(creature) { }
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 7:
|
||||
DoScriptText(SAY_STAY_1, me, player);
|
||||
break;
|
||||
case 11:
|
||||
DoScriptText(SAY_STAY_2, me, player);
|
||||
break;
|
||||
case 25:
|
||||
DoScriptText(SAY_STAY_3, me, player);
|
||||
break;
|
||||
case 26:
|
||||
DoScriptText(SAY_STAY_4, me, player);
|
||||
break;
|
||||
case 27:
|
||||
DoScriptText(SAY_STAY_5, me, player);
|
||||
break;
|
||||
case 28:
|
||||
DoScriptText(SAY_STAY_6, me, player);
|
||||
me->SetStandState(UNIT_STAND_STATE_KNEEL);
|
||||
break;
|
||||
case 29:
|
||||
me->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
break;
|
||||
case 37:
|
||||
DoScriptText(SAY_QUEST_COMPLETE, me, player);
|
||||
me->SetSpeed(MOVE_RUN, 1.2f, true);
|
||||
me->SetWalk(false);
|
||||
if (player->GetQuestStatus(QUEST_STINKYS_ESCAPE_H))
|
||||
player->GroupEventHappens(QUEST_STINKYS_ESCAPE_H, me);
|
||||
if (player->GetQuestStatus(QUEST_STINKYS_ESCAPE_A))
|
||||
player->GroupEventHappens(QUEST_STINKYS_ESCAPE_A, me);
|
||||
break;
|
||||
case 39:
|
||||
DoScriptText(EMOTE_DISAPPEAR, me);
|
||||
break;
|
||||
|
||||
case 7:
|
||||
DoScriptText(SAY_STAY_1, me, player);
|
||||
break;
|
||||
case 11:
|
||||
DoScriptText(SAY_STAY_2, me, player);
|
||||
break;
|
||||
case 25:
|
||||
DoScriptText(SAY_STAY_3, me, player);
|
||||
break;
|
||||
case 26:
|
||||
DoScriptText(SAY_STAY_4, me, player);
|
||||
break;
|
||||
case 27:
|
||||
DoScriptText(SAY_STAY_5, me, player);
|
||||
break;
|
||||
case 28:
|
||||
DoScriptText(SAY_STAY_6, me, player);
|
||||
me->SetStandState(UNIT_STAND_STATE_KNEEL);
|
||||
break;
|
||||
case 29:
|
||||
me->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
break;
|
||||
case 37:
|
||||
DoScriptText(SAY_QUEST_COMPLETE, me, player);
|
||||
me->SetSpeed(MOVE_RUN, 1.2f, true);
|
||||
me->SetWalk(false);
|
||||
if (player->GetQuestStatus(QUEST_STINKYS_ESCAPE_H))
|
||||
player->GroupEventHappens(QUEST_STINKYS_ESCAPE_H, me);
|
||||
if (player->GetQuestStatus(QUEST_STINKYS_ESCAPE_A))
|
||||
player->GroupEventHappens(QUEST_STINKYS_ESCAPE_A, me);
|
||||
break;
|
||||
case 39:
|
||||
DoScriptText(EMOTE_DISAPPEAR, me);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -124,9 +124,9 @@ public:
|
||||
{
|
||||
npc_oox22feAI(Creature* creature) : npc_escortAI(creature) { }
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
// First Ambush(3 Yetis)
|
||||
case 11:
|
||||
|
||||
@@ -537,9 +537,9 @@ public:
|
||||
} else if (Event_onWait) Event_Timer -= diff;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 id)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
CurrWP = id;
|
||||
CurrWP = waypointId;
|
||||
Event_Timer = 0;
|
||||
Step = 0;
|
||||
Event_onWait = true;
|
||||
|
||||
@@ -114,14 +114,13 @@ public:
|
||||
{
|
||||
npc_kaya_flathoofAI(Creature* creature) : npc_escortAI(creature) {}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 16:
|
||||
DoScriptText(SAY_AMBUSH, me);
|
||||
@@ -129,7 +128,6 @@ public:
|
||||
me->SummonCreature(NPC_GRIMTOTEM_RUFFIAN, -38.85f, -503.77f, -45.90f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
|
||||
me->SummonCreature(NPC_GRIMTOTEM_SORCERER, -36.37f, -496.23f, -45.71f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
|
||||
break;
|
||||
|
||||
case 18:
|
||||
me->SetInFront(player);
|
||||
DoScriptText(SAY_END, me, player);
|
||||
|
||||
@@ -172,31 +172,65 @@ public:
|
||||
{
|
||||
npc_custodian_of_timeAI(Creature* creature) : npc_escortAI(creature) {}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0: DoScriptText(WHISPER_CUSTODIAN_1, me, player); break;
|
||||
case 1: DoScriptText(WHISPER_CUSTODIAN_2, me, player); break;
|
||||
case 2: DoScriptText(WHISPER_CUSTODIAN_3, me, player); break;
|
||||
case 3: DoScriptText(WHISPER_CUSTODIAN_4, me, player); break;
|
||||
case 5: DoScriptText(WHISPER_CUSTODIAN_5, me, player); break;
|
||||
case 6: DoScriptText(WHISPER_CUSTODIAN_6, me, player); break;
|
||||
case 7: DoScriptText(WHISPER_CUSTODIAN_7, me, player); break;
|
||||
case 8: DoScriptText(WHISPER_CUSTODIAN_8, me, player); break;
|
||||
case 9: DoScriptText(WHISPER_CUSTODIAN_9, me, player); break;
|
||||
case 10: DoScriptText(WHISPER_CUSTODIAN_4, me, player); break;
|
||||
case 13: DoScriptText(WHISPER_CUSTODIAN_10, me, player); break;
|
||||
case 14: DoScriptText(WHISPER_CUSTODIAN_4, me, player); break;
|
||||
case 16: DoScriptText(WHISPER_CUSTODIAN_11, me, player); break;
|
||||
case 17: DoScriptText(WHISPER_CUSTODIAN_12, me, player); break;
|
||||
case 18: DoScriptText(WHISPER_CUSTODIAN_4, me, player); break;
|
||||
case 22: DoScriptText(WHISPER_CUSTODIAN_13, me, player); break;
|
||||
case 23: DoScriptText(WHISPER_CUSTODIAN_4, me, player); break;
|
||||
case 0:
|
||||
DoScriptText(WHISPER_CUSTODIAN_1, me, player);
|
||||
break;
|
||||
case 1:
|
||||
DoScriptText(WHISPER_CUSTODIAN_2, me, player);
|
||||
break;
|
||||
case 2:
|
||||
DoScriptText(WHISPER_CUSTODIAN_3, me, player);
|
||||
break;
|
||||
case 3:
|
||||
DoScriptText(WHISPER_CUSTODIAN_4, me, player);
|
||||
break;
|
||||
case 5:
|
||||
DoScriptText(WHISPER_CUSTODIAN_5, me, player);
|
||||
break;
|
||||
case 6:
|
||||
DoScriptText(WHISPER_CUSTODIAN_6, me, player);
|
||||
break;
|
||||
case 7:
|
||||
DoScriptText(WHISPER_CUSTODIAN_7, me, player);
|
||||
break;
|
||||
case 8:
|
||||
DoScriptText(WHISPER_CUSTODIAN_8, me, player);
|
||||
break;
|
||||
case 9:
|
||||
DoScriptText(WHISPER_CUSTODIAN_9, me, player);
|
||||
break;
|
||||
case 10:
|
||||
DoScriptText(WHISPER_CUSTODIAN_4, me, player);
|
||||
break;
|
||||
case 13:
|
||||
DoScriptText(WHISPER_CUSTODIAN_10, me, player);
|
||||
break;
|
||||
case 14:
|
||||
DoScriptText(WHISPER_CUSTODIAN_4, me, player);
|
||||
break;
|
||||
case 16:
|
||||
DoScriptText(WHISPER_CUSTODIAN_11, me, player);
|
||||
break;
|
||||
case 17:
|
||||
DoScriptText(WHISPER_CUSTODIAN_12, me, player);
|
||||
break;
|
||||
case 18:
|
||||
DoScriptText(WHISPER_CUSTODIAN_4, me, player);
|
||||
break;
|
||||
case 22:
|
||||
DoScriptText(WHISPER_CUSTODIAN_13, me, player);
|
||||
break;
|
||||
case 23:
|
||||
DoScriptText(WHISPER_CUSTODIAN_4, me, player);
|
||||
break;
|
||||
case 24:
|
||||
DoScriptText(WHISPER_CUSTODIAN_14, me, player);
|
||||
DoCast(player, 34883);
|
||||
@@ -428,14 +462,13 @@ public:
|
||||
{
|
||||
npc_OOX17AI(Creature* creature) : npc_escortAI(creature) {}
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 23:
|
||||
me->SummonCreature(SPAWN_FIRST, -8350.96f, -4445.79f, 10.10f, 6.20f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
@@ -443,7 +476,6 @@ public:
|
||||
me->SummonCreature(SPAWN_FIRST, -8353.96f, -4442.79f, 10.10f, 6.08f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
DoScriptText(SAY_OOX_AMBUSH, me);
|
||||
break;
|
||||
|
||||
case 56:
|
||||
me->SummonCreature(SPAWN_SECOND_1, -7510.07f, -4795.50f, 9.35f, 6.06f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
me->SummonCreature(SPAWN_SECOND_2, -7515.07f, -4797.50f, 9.35f, 6.22f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
@@ -452,7 +484,6 @@ public:
|
||||
if (Unit* scoff = me->FindNearestCreature(SPAWN_SECOND_2, 30))
|
||||
DoScriptText(SAY_OOX17_AMBUSH_REPLY, scoff);
|
||||
break;
|
||||
|
||||
case 86:
|
||||
DoScriptText(SAY_OOX_END, me);
|
||||
player->GroupEventHappens(Q_OOX17, me);
|
||||
|
||||
@@ -127,14 +127,13 @@ public:
|
||||
|
||||
void Reset() { }
|
||||
|
||||
void WaypointReached(uint32 uiPointId)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (uiPointId)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 16:
|
||||
DoScriptText(SAY_GIL_AT_LAST, me, player);
|
||||
@@ -593,26 +592,26 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 uiPointId)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (uiPointId)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0:
|
||||
DoScriptText(SAY_STARTUP1, me);
|
||||
break;
|
||||
case 9:
|
||||
SetRun(false);
|
||||
break;
|
||||
case 17:
|
||||
if (Creature* temp = me->SummonCreature(NPC_MERCENARY, 1128.489f, -3037.611f, 92.701f, 1.472f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 120000))
|
||||
{
|
||||
DoScriptText(SAY_MERCENARY, temp);
|
||||
me->SummonCreature(NPC_MERCENARY, 1160.172f, -2980.168f, 97.313f, 3.690f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 120000);
|
||||
}
|
||||
break;
|
||||
case 24:
|
||||
m_bIsPostEvent = true;
|
||||
break;
|
||||
case 0:
|
||||
DoScriptText(SAY_STARTUP1, me);
|
||||
break;
|
||||
case 9:
|
||||
SetRun(false);
|
||||
break;
|
||||
case 17:
|
||||
if (Creature* temp = me->SummonCreature(NPC_MERCENARY, 1128.489f, -3037.611f, 92.701f, 1.472f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 120000))
|
||||
{
|
||||
DoScriptText(SAY_MERCENARY, temp);
|
||||
me->SummonCreature(NPC_MERCENARY, 1160.172f, -2980.168f, 97.313f, 3.690f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 120000);
|
||||
}
|
||||
break;
|
||||
case 24:
|
||||
m_bIsPostEvent = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -75,9 +75,9 @@ public:
|
||||
|
||||
void Reset() { }
|
||||
|
||||
void WaypointReached(uint32 uiPointId)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (uiPointId)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 0:
|
||||
DoScriptText(SAY_KAN_START, me);
|
||||
@@ -166,9 +166,9 @@ public:
|
||||
|
||||
void Reset() { }
|
||||
|
||||
void WaypointReached(uint32 uiPointId)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (uiPointId)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 8:
|
||||
DoScriptText(SAY_LAKO_LOOK_OUT, me);
|
||||
@@ -251,9 +251,9 @@ public:
|
||||
|
||||
void Reset() { }
|
||||
|
||||
void WaypointReached(uint32 uiPointId)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
switch (uiPointId)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 15:
|
||||
DoScriptText(SAY_WYVERN, me);
|
||||
|
||||
@@ -78,14 +78,13 @@ public:
|
||||
|
||||
uint32 DEMORALIZINGSHOUT_Timer;
|
||||
|
||||
void WaypointReached(uint32 i)
|
||||
void WaypointReached(uint32 waypointId)
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
if (!player)
|
||||
return;
|
||||
|
||||
switch (i)
|
||||
switch (waypointId)
|
||||
{
|
||||
case 19:
|
||||
me->SummonCreature(ENTRY_STOMPER, -6391.69f, -1730.49f, -272.83f, 4.96f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
|
||||
|
||||
Reference in New Issue
Block a user