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:
Gyx
2012-03-29 15:44:24 +08:00
parent 5b7493fc66
commit 391d68be20
67 changed files with 660 additions and 603 deletions
@@ -177,9 +177,9 @@ public:
MobDeath_Timer = 2500;
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
switch (i)
switch (waypointId)
{
case 0:
DoScriptText(SCRIPT_TEXT1, me);//2
@@ -611,7 +611,7 @@ public:
{
npc_dughal_stormwingAI(Creature* creature) : npc_escortAI(creature) {}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
switch (i)
{
@@ -730,7 +730,7 @@ public:
instance = creature->GetInstanceScript();
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
switch (i)
{
@@ -900,7 +900,7 @@ public:
{
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
wp=i;
switch (i)
@@ -1105,7 +1105,7 @@ public:
}
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
switch (i)
{
@@ -1226,12 +1226,12 @@ public:
go->SetGoState((GOState)state);
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
if (!instance)
return;
switch (i)
switch (waypointId)
{
case 1:
me->HandleEmoteCommand(EMOTE_ONESHOT_KICK);
@@ -266,14 +266,14 @@ public:
}
}
void WaypointReached(uint32 uiPoint)
void WaypointReached(uint32 waypointId)
{
//just in case
if (GetPlayerForEscort())
if (me->getFaction() != GetPlayerForEscort()->getFaction())
me->setFaction(GetPlayerForEscort()->getFaction());
switch (uiPoint)
switch (waypointId)
{
case 3:
SetEscortPaused(true);
@@ -158,12 +158,12 @@ public:
void EnterCombat(Unit* /*who*/) {}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
if (!instance)
return;
switch (i)
switch (waypointId)
{
case 0:
DoCast(me, SPELL_TUXEDO, false);
@@ -994,9 +994,9 @@ public:
SetDespawnAtFar(false);
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
switch (i)
switch (waypointId)
{
case 1:
if (Unit* car = Unit::GetCreature(*me, carGUID))
@@ -239,9 +239,9 @@ public:
}
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 0:
DoScriptText(SAY_BREAKOUT1, me);
@@ -497,9 +497,9 @@ public:
SetEscortPaused(bOnHold);
}
void WaypointReached(uint32 wpId)
void WaypointReached(uint32 waypointId)
{
switch (wpId)
switch (waypointId)
{
case 0:
me->SetWalk(false);
@@ -507,7 +507,6 @@ public:
break;
case 1:
SetHoldState(true);
SpawnNPC();
if (Creature* temp = Unit::GetCreature(*me, uiKorfaxGUID))
DoScriptText(SAY_LIGHT_OF_DAWN07, temp);
@@ -152,7 +152,12 @@ public:
uint32 Start_Timer;
void Reset() {}
void WaypointReached(uint32 /*point*/) {}
void WaypointReached(uint32 /*waypointId*/)
{
}
void EnterCombat(Unit* /*who*/) {}
void UpdateAI(const uint32 diff)
@@ -99,9 +99,9 @@ public:
InstanceScript* instance;
uint32 uiNpcEntry;
void WaypointReached(uint32 uiPoint)
void WaypointReached(uint32 waypointId)
{
switch (uiPoint)
switch (waypointId)
{
case 0:
if (uiNpcEntry == NPC_ASH)
@@ -64,14 +64,13 @@ class npc_professor_phizzlethorpe : public CreatureScript
{
npc_professor_phizzlethorpeAI(Creature* creature) : npc_escortAI(creature) {}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (uiPointId)
switch (waypointId)
{
case 4:
Talk(SAY_PROGRESS_2, player->GetGUID());
@@ -130,14 +130,13 @@ public:
{
npc_ranger_lilathaAI(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);
@@ -145,16 +144,13 @@ public:
Cage->SetGoState(GO_STATE_ACTIVE);
DoScriptText(SAY_START, me, player);
break;
case 5:
DoScriptText(SAY_PROGRESS1, me, player);
break;
case 11:
DoScriptText(SAY_PROGRESS2, me, player);
me->SetOrientation(4.762841f);
break;
case 18:
{
DoScriptText(SAY_PROGRESS3, me, player);
@@ -168,25 +164,20 @@ public:
me->AI()->AttackStart(Summ1);
}
break;
case 19:
me->SetWalk(false);
break;
case 25:
me->SetWalk(true);
break;
case 30:
if (player->GetTypeId() == TYPEID_PLAYER)
CAST_PLR(player)->GroupEventHappens(QUEST_ESCAPE_FROM_THE_CATACOMBS, me);
break;
case 32:
me->SetOrientation(2.978281f);
DoScriptText(SAY_END1, me, player);
break;
case 33:
me->SetOrientation(5.858011f);
DoScriptText(SAY_END2, me, player);
@@ -87,9 +87,9 @@ public:
void Reset() { }
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 26:
DoScriptText(SAY_OOX_AMBUSH, me);
@@ -276,14 +276,13 @@ public:
summoned->GetMotionMaster()->MovePoint(0, m_afAmbushMoveTo[m_iSpawnId].m_fX, m_afAmbushMoveTo[m_iSpawnId].m_fY, m_afAmbushMoveTo[m_iSpawnId].m_fZ);
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (uiPointId)
switch (waypointId)
{
case 1:
DoScriptText(SAY_RIN_FREE, me, player);
@@ -76,17 +76,16 @@ public:
uiShieldBashTimer = 8000;
}
void WaypointReached(uint32 uiI)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
if (uiI >= 65 && me->GetUnitMovementFlags() == MOVEMENTFLAG_WALKING)
if (waypointId >= 65 && me->GetUnitMovementFlags() == MOVEMENTFLAG_WALKING)
me->SetWalk(false);
switch (uiI)
switch (waypointId)
{
case 39:
SetEscortPaused(true);
@@ -66,50 +66,41 @@ public:
{
npc_deathstalker_erlandAI(Creature* creature) : npc_escortAI(creature) {}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 1:
DoScriptText(SAY_START, me, player);
break;
case 13:
DoScriptText(SAY_LAST, me, player);
player->GroupEventHappens(QUEST_ESCORTING, me);
break;
case 14:
DoScriptText(SAY_THANKS, me, player);
break;
case 15:
if (Unit* Rane = me->FindNearestCreature(NPC_RANE, 20))
DoScriptText(SAY_RANE, Rane);
break;
case 16:
DoScriptText(SAY_ANSWER, me);
break;
case 17:
DoScriptText(SAY_MOVE_QUINN, me);
break;
case 24:
DoScriptText(SAY_GREETINGS, me);
break;
case 25:
if (Unit* Quinn = me->FindNearestCreature(NPC_QUINN, 20))
DoScriptText(SAY_QUINN, Quinn);
break;
case 26:
DoScriptText(SAY_ON_BYE, me, NULL);
break;
@@ -268,9 +268,9 @@ public:
}
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 14:
SetEscortPaused(true);
@@ -497,9 +497,9 @@ public:
uiPhase = 0;
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 1:
SetEscortPaused(true);
@@ -106,9 +106,9 @@ public:
}
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 0:
if (GameObject* pCage = me->GetMap()->GetGameObject(m_uiGalensCageGUID))
@@ -328,10 +328,11 @@ public:
summoned->AI()->AttackStart(me);
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
switch (i)
switch (waypointId)
{
case 8:
DoScriptText(SAY_WP_0, me);
+14 -10
View File
@@ -85,9 +85,15 @@ public:
{
switch (uiWPHolder)
{
case 7: DoScriptText(SAY_DS_DOWN_1, me); break;
case 8: DoScriptText(SAY_DS_DOWN_2, me); break;
case 9: DoScriptText(SAY_DS_DOWN_3, me); break;
case 7:
DoScriptText(SAY_DS_DOWN_1, me);
break;
case 8:
DoScriptText(SAY_DS_DOWN_2, me);
break;
case 9:
DoScriptText(SAY_DS_DOWN_3, me);
break;
}
}
else
@@ -96,16 +102,15 @@ public:
uiShootTimer = 0;
}
void WaypointReached(uint32 uiPoint)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
uiWPHolder = uiPoint;
uiWPHolder = waypointId;
switch (uiPoint)
switch (waypointId)
{
case 4:
SetEquipmentSlots(false, EQUIP_NO_CHANGE, EQUIP_NO_CHANGE, EQUIP_ID_RIFLE);
@@ -226,14 +231,13 @@ public:
{
npc_defias_traitorAI(Creature* creature) : npc_escortAI(creature) { Reset(); }
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 35:
SetRun(false);
@@ -67,14 +67,13 @@ public:
m_bFriendSummoned = false;
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 2:
if (me->HasStealthAura())
me->RemoveAurasByType(SPELL_AURA_MOD_STEALTH);
SetRun();
me->setFaction(FACTION_ENEMY);
break;
@@ -75,9 +75,9 @@ class example_escort : public CreatureScript
}
// Pure Virtual Functions (Have to be implemented)
void WaypointReached(uint32 uiWP)
void WaypointReached(uint32 waypointId)
{
switch (uiWP)
switch (waypointId)
{
case 1:
DoScriptText(SAY_WP_1, me);
@@ -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())
@@ -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())
@@ -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,14 +72,13 @@ 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);
@@ -151,12 +151,12 @@ public:
uint32 eventProgress;
InstanceScript* instance;
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
if (!instance)
return;
switch (i)
switch (waypointId)
{
case 4:
eventProgress = 1;
+8 -10
View File
@@ -76,14 +76,13 @@ 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());
@@ -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,16 +312,18 @@ 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:
if (player)
DoScriptText(SAY_MUG_START2, me, player);
break;
case 24:
if (player)
DoScriptText(SAY_MUG_BRAZIER, me, player);
if (GameObject* go = GetClosestGameObjectWithEntry(me, GO_NAGA_BRAZIER, INTERACTION_DISTANCE*2))
@@ -374,14 +374,13 @@ 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);
+2 -2
View File
@@ -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);
+3 -2
View File
@@ -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,13 +607,13 @@ 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);
@@ -649,7 +649,6 @@ public:
case 39:
DoScriptText(EMOTE_DISAPPEAR, me);
break;
}
}
+2 -2
View File
@@ -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:
+2 -2
View File
@@ -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);
+55 -24
View File
@@ -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);
+4 -5
View File
@@ -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,9 +592,9 @@ public:
}
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 0:
DoScriptText(SAY_STARTUP1, me);
@@ -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);
@@ -227,9 +227,9 @@ class npc_onyx_flamecaller : public CreatureScript
zarithrian->AI()->JustSummoned(me);
}
void WaypointReached(uint32 pointId)
void WaypointReached(uint32 waypointId)
{
if (pointId == MAX_PATH_FLAMECALLER_WAYPOINTS || pointId == MAX_PATH_FLAMECALLER_WAYPOINTS*2)
if (waypointId == MAX_PATH_FLAMECALLER_WAYPOINTS || waypointId == MAX_PATH_FLAMECALLER_WAYPOINTS*2)
{
DoZoneInCombat();
SetEscortPaused(true);
@@ -447,9 +447,9 @@ public:
uint8 uiWaypoint;
void WaypointReached(uint32 uiPoint)
void WaypointReached(uint32 waypointId)
{
if (uiPoint == 0)
if (waypointId == 0)
{
switch (uiWaypoint)
{
@@ -356,7 +356,7 @@ public:
Start(false, true, 0, NULL);
}
void WaypointReached(uint32 /*i*/)
void WaypointReached(uint32 /*waypointId*/)
{
}
@@ -203,16 +203,18 @@ public:
Start(false, true, 0, NULL);
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
switch (i)
if (!instance)
return;
switch (waypointId)
{
case 2:
if (instance && (uiWaypointPath == 3 || uiWaypointPath == 2))
if (uiWaypointPath == 3 || uiWaypointPath == 2)
instance->SetData(DATA_MOVEMENT_DONE, instance->GetData(DATA_MOVEMENT_DONE)+1);
break;
case 3:
if (instance)
instance->SetData(DATA_MOVEMENT_DONE, instance->GetData(DATA_MOVEMENT_DONE)+1);
break;
}
@@ -963,8 +963,9 @@ public:
// we dont do melee damage!
}
void WaypointReached(uint32 /*i*/)
void WaypointReached(uint32 /*waypointId*/)
{
}
private:
@@ -346,9 +346,9 @@ public:
lDwarfGUIDList.clear();
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 7:
if (Creature* creature = GetClosestCreatureWithEntry(me, CREATURE_TRIBUNAL_OF_THE_AGES, 100.0f))
@@ -964,8 +964,9 @@ public:
me->SetReactState(REACT_PASSIVE);
}
void WaypointReached(uint32 /*i*/)
void WaypointReached(uint32 /*waypointId*/)
{
}
void Reset()
@@ -447,32 +447,32 @@ public:
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
}
void WaypointReached(uint32 uiWPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiBoss)
{
case 1:
if (uiWPointId == 2)
if (waypointId == 2)
FinishPointReached();
break;
case 2:
if (uiWPointId == 2)
if (waypointId == 2)
FinishPointReached();
break;
case 3:
if (uiWPointId == 1)
if (waypointId == 1)
FinishPointReached();
break;
case 4:
if (uiWPointId == 0)
if (waypointId == 0)
FinishPointReached();
break;
case 5:
if (uiWPointId == 0)
if (waypointId == 0)
FinishPointReached();
break;
case 6:
if (uiWPointId == 4)
if (waypointId == 4)
FinishPointReached();
break;
}
@@ -690,32 +690,32 @@ struct violet_hold_trashAI : public npc_escortAI
uint32 portalLocationID;
uint32 secondPortalRouteID;
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (portalLocationID)
{
case 0:
if (uiPointId == 5)
if (waypointId == 5)
CreatureStartAttackDoor();
break;
case 1:
if ((uiPointId == 8 && secondPortalRouteID == 0) || (uiPointId == 7 && secondPortalRouteID == 1))
if ((waypointId == 8 && secondPortalRouteID == 0) || (waypointId == 7 && secondPortalRouteID == 1))
CreatureStartAttackDoor();
break;
case 2:
if (uiPointId == 7)
if (waypointId == 7)
CreatureStartAttackDoor();
break;
case 3:
if (uiPointId == 8)
if (waypointId == 8)
CreatureStartAttackDoor();
break;
case 4:
if (uiPointId == 5)
if (waypointId == 5)
CreatureStartAttackDoor();
break;
case 5:
if (uiPointId == 3)
if (waypointId == 3)
CreatureStartAttackDoor();
break;
}
+8 -11
View File
@@ -716,9 +716,9 @@ public:
}
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
switch (i)
switch (waypointId)
{
case 0:
IntroPhase = 1;
@@ -1012,13 +1012,13 @@ public:
uiPhaseTimer = 0;
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (uiPointId)
switch (waypointId)
{
case 3:
SetEscortPaused(true);
@@ -1038,7 +1038,6 @@ public:
}
me->SetWalk(false);
break;
case 4:
SetEscortPaused(true);
uiPhase = 7;
@@ -1851,14 +1850,13 @@ public:
player->FailQuest(QUEST_ESCAPING_THE_MIST);
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 10:
me->HandleEmoteCommand(EMOTE_ONESHOT_EXCLAMATION);
@@ -1951,14 +1949,13 @@ public:
else Bonker_agro=0;
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 29:
player->GroupEventHappens(QUEST_GET_ME_OUTA_HERE, me);
@@ -74,13 +74,13 @@ public:
summoned->AI()->AttackStart(me->getVictim());
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 9:
if (Creature* Mrfloppy = GetClosestCreatureWithEntry(me, NPC_MRFLOPPY, 100.0f))
@@ -97,13 +97,13 @@ public:
DoMeleeAttackIfReady();
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 1:
me->SetReactState(REACT_AGGRESSIVE);
@@ -70,16 +70,17 @@ public:
}
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 1: SetRun(); break;
case 1:
SetRun();
break;
case 10:
case 11:
case 12:
@@ -359,10 +360,11 @@ public:
uint32 m_uiChatTimer;
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
switch (i)
switch (waypointId)
{
case 0:
DoScriptText(SAY_WP_2, me);
+3 -4
View File
@@ -374,18 +374,17 @@ public:
{
npc_injured_goblinAI(Creature* creature) : npc_escortAI(creature) { }
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 26:
DoScriptText(SAY_END_WP_REACHED, me, player);
break;
case 27:
player->GroupEventHappens(QUEST_BITTER_DEPARTURE, me);
break;
@@ -672,7 +671,7 @@ public:
}
}
void WaypointReached(uint32 /*wp*/)
void WaypointReached(uint32 /*waypointId*/)
{
}
+4 -4
View File
@@ -740,9 +740,9 @@ public:
bEnrage = false;
}
void WaypointReached(uint32 uiI)
void WaypointReached(uint32 waypointId)
{
switch (uiI)
switch (waypointId)
{
case 6:
me->SetHomePosition(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), 0);
@@ -934,9 +934,9 @@ public:
bThunderClap = false;
}
void WaypointReached(uint32 uiI)
void WaypointReached(uint32 waypointId)
{
switch (uiI)
switch (waypointId)
{
case 7:
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IMMUNE_TO_PC);
@@ -102,7 +102,7 @@ public:
npc_escortAI::MoveInLineOfSight(who);
}
void WaypointReached(uint32 /*i*/)
void WaypointReached(uint32 /*waypointId*/)
{
}
@@ -180,9 +180,9 @@ public:
npc_escortAI::MoveInLineOfSight(who);
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 0:
DoScriptText(EMOTE_WOLF_LIFT_HEAD, me);
@@ -402,14 +402,13 @@ public:
{
npc_wounded_blood_elfAI(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_ELF_START, me, player);
+4 -4
View File
@@ -221,9 +221,9 @@ public:
DoCast(me, SPELL_EARTHBIND_TOTEM, false);
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
switch (uiPointId)
switch (waypointId)
{
case 7:
DoScriptText(SAY_MAG_MORE, me);
@@ -565,9 +565,9 @@ public:
}
}
void WaypointReached(uint32 PointId)
void WaypointReached(uint32 waypointId)
{
switch(PointId)
switch (waypointId)
{
case 3:
{
+8 -9
View File
@@ -889,33 +889,32 @@ public:
player->FailQuest(Q_ALMABTRIEB);
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 3: //first spawn
me->SummonCreature(SPAWN_FIRST, 2449.67f, 2183.11f, 96.85f, 6.20f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
me->SummonCreature(SPAWN_FIRST, 2449.53f, 2184.43f, 96.36f, 6.27f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
me->SummonCreature(SPAWN_FIRST, 2449.85f, 2186.34f, 97.57f, 6.08f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
break;
case 7:
me->SummonCreature(SPAWN_SECOND, 2309.64f, 2186.24f, 92.25f, 6.06f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
me->SummonCreature(SPAWN_SECOND, 2309.25f, 2183.46f, 91.75f, 6.22f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
break;
case 12:
player->GroupEventHappens(Q_ALMABTRIEB, me);
if (me->FindNearestCreature(N_THADELL, 30))
DoScriptText(SAY_THADELL_1, me); break;
DoScriptText(SAY_THADELL_1, me);
break;
case 13:
if (me->FindNearestCreature(N_THADELL, 30))
DoScriptText(SAY_THADELL_2, me, player); break;
DoScriptText(SAY_THADELL_2, me, player);
break;
}
}
@@ -964,13 +963,13 @@ public:
uiTakeTimer=3000;
}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 7:
case 17:
@@ -1054,14 +1054,13 @@ public:
m_uiHealingTimer = 0;
}
void WaypointReached(uint32 uiPointId)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (uiPointId)
switch (waypointId)
{
case 13:
DoScriptText(SAY_WIL_PROGRESS1, me, player);
+65 -24
View File
@@ -319,36 +319,77 @@ public:
public:
npc_kservantAI(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(SAY1, me, player); break;
case 4: DoScriptText(WHISP1, me, player); break;
case 6: DoScriptText(WHISP2, me, player); break;
case 7: DoScriptText(WHISP3, me, player); break;
case 8: DoScriptText(WHISP4, me, player); break;
case 17: DoScriptText(WHISP5, me, player); break;
case 18: DoScriptText(WHISP6, me, player); break;
case 19: DoScriptText(WHISP7, me, player); break;
case 33: DoScriptText(WHISP8, me, player); break;
case 34: DoScriptText(WHISP9, me, player); break;
case 35: DoScriptText(WHISP10, me, player); break;
case 36: DoScriptText(WHISP11, me, player); break;
case 43: DoScriptText(WHISP12, me, player); break;
case 44: DoScriptText(WHISP13, me, player); break;
case 49: DoScriptText(WHISP14, me, player); break;
case 50: DoScriptText(WHISP15, me, player); break;
case 51: DoScriptText(WHISP16, me, player); break;
case 52: DoScriptText(WHISP17, me, player); break;
case 53: DoScriptText(WHISP18, me, player); break;
case 54: DoScriptText(WHISP19, me, player); break;
case 55: DoScriptText(WHISP20, me, player); break;
case 0:
DoScriptText(SAY1, me, player);
break;
case 4:
DoScriptText(WHISP1, me, player);
break;
case 6:
DoScriptText(WHISP2, me, player);
break;
case 7:
DoScriptText(WHISP3, me, player);
break;
case 8:
DoScriptText(WHISP4, me, player);
break;
case 17:
DoScriptText(WHISP5, me, player);
break;
case 18:
DoScriptText(WHISP6, me, player);
break;
case 19:
DoScriptText(WHISP7, me, player);
break;
case 33:
DoScriptText(WHISP8, me, player);
break;
case 34:
DoScriptText(WHISP9, me, player);
break;
case 35:
DoScriptText(WHISP10, me, player);
break;
case 36:
DoScriptText(WHISP11, me, player);
break;
case 43:
DoScriptText(WHISP12, me, player);
break;
case 44:
DoScriptText(WHISP13, me, player);
break;
case 49:
DoScriptText(WHISP14, me, player);
break;
case 50:
DoScriptText(WHISP15, me, player);
break;
case 51:
DoScriptText(WHISP16, me, player);
break;
case 52:
DoScriptText(WHISP17, me, player);
break;
case 53:
DoScriptText(WHISP18, me, player);
break;
case 54:
DoScriptText(WHISP19, me, player);
break;
case 55:
DoScriptText(WHISP20, me, player);
break;
case 56:
DoScriptText(WHISP21, me, player);
player->GroupEventHappens(10211, me);
+6 -14
View File
@@ -202,13 +202,13 @@ public:
public:
npc_skywingAI(Creature* creature) : npc_escortAI(creature) {}
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 8:
player->AreaExploredOrEventHappens(10898);
@@ -461,32 +461,27 @@ public:
{
npc_isla_starmaneAI(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:
if (GameObject* Cage = me->FindNearestGameObject(GO_CAGE, 10))
Cage->SetGoState(GO_STATE_ACTIVE);
break;
case 2:
DoScriptText(SAY_PROGRESS_1, me, player);
break;
case 5:
DoScriptText(SAY_PROGRESS_2, me, player);
break;
case 6:
DoScriptText(SAY_PROGRESS_3, me, player);
break;
case 29:
DoScriptText(SAY_PROGRESS_4, me, player);
if (player->GetTeam() == ALLIANCE)
@@ -495,11 +490,9 @@ public:
player->GroupEventHappens(QUEST_EFTW_H, me);
me->SetInFront(player);
break;
case 30:
me->HandleEmoteCommand(EMOTE_ONESHOT_WAVE);
break;
case 31:
DoCast(me, SPELL_CAT);
me->SetWalk(false);
@@ -673,14 +666,13 @@ public:
{
npc_akunoAI(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->SummonCreature(NPC_CABAL_SKRIMISHER, -2795.99f, 5420.33f, -34.53f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
+2 -3
View File
@@ -322,14 +322,13 @@ public:
void Reset() { }
void WaypointReached(uint32 i)
void WaypointReached(uint32 waypointId)
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (i)
switch (waypointId)
{
case 4:
DoScriptText(SAY_AMBUSH1, me, player);
+2 -1
View File
@@ -1040,8 +1040,9 @@ public:
}
}
void WaypointReached(uint32 /*point*/)
void WaypointReached(uint32 /*waypointId*/)
{
}
void UpdateAI(uint32 const diff)