Cosmetic: Multiple cosmetic changes

- Added missing space to 'if', 'for', 'while' and 'switch' when it's followed by '('
- Added missing space after a comma and remove space before comma (with some exceptions)
- Remove trailing spaces
- Convert tab to spaces

Note: Only affects files with extension "cpp" and "h" under /src/server
This commit is contained in:
Spp
2011-09-29 12:43:05 +02:00
parent 8b820baa73
commit b16d2245bb
390 changed files with 1545 additions and 1545 deletions
+3 -3
View File
@@ -104,7 +104,7 @@ public:
std::string password = szPassword;
AccountOpResult result = AccountMgr::CreateAccount(account_name, password);
switch(result)
switch (result)
{
case AOR_OK:
handler->PSendSysMessage(LANG_ACCOUNT_CREATED, account_name.c_str());
@@ -165,7 +165,7 @@ public:
return false;
AccountOpResult result = AccountMgr::DeleteAccount(account_id);
switch(result)
switch (result)
{
case AOR_OK:
handler->PSendSysMessage(LANG_ACCOUNT_DELETED, account_name.c_str());
@@ -299,7 +299,7 @@ public:
}
AccountOpResult result = AccountMgr::ChangePassword(handler->GetSession()->GetAccountId(), std::string(new_pass));
switch(result)
switch (result)
{
case AOR_OK:
handler->SendSysMessage(LANG_COMMAND_PASSWORD);
+6 -6
View File
@@ -291,7 +291,7 @@ public:
else if (commentToken[1] == '/')
{
std::string str;
getline(ifs,str);
getline(ifs, str);
continue;
}
// regular data
@@ -558,7 +558,7 @@ public:
uint8 bag_slot = container ? container->GetSlot() : uint8(INVENTORY_SLOT_BAG_0);
std::string st;
switch(item->GetState())
switch (item->GetState())
{
case ITEM_UNCHANGED: st = "unchanged"; break;
case ITEM_CHANGED: st = "changed"; break;
@@ -1061,13 +1061,13 @@ public:
if (isint32)
{
uint32 iValue = (uint32)atoi(py);
target->SetUInt32Value(Opcode , iValue);
target->SetUInt32Value(Opcode, iValue);
handler->PSendSysMessage(LANG_SET_UINT_FIELD, GUID_LOPART(guid), Opcode, iValue);
}
else
{
float fValue = (float)atof(py);
target->SetFloatValue(Opcode , fValue);
target->SetFloatValue(Opcode, fValue);
handler->PSendSysMessage(LANG_SET_FLOAT_FIELD, GUID_LOPART(guid), Opcode, fValue);
}
@@ -1143,7 +1143,7 @@ public:
int CurrentValue = (int)handler->GetSession()->GetPlayer()->GetUInt32Value(Opcode);
CurrentValue += Value;
handler->GetSession()->GetPlayer()->SetUInt32Value(Opcode , (uint32)CurrentValue);
handler->GetSession()->GetPlayer()->SetUInt32Value(Opcode, (uint32)CurrentValue);
handler->PSendSysMessage(LANG_CHANGE_32BIT_FIELD, Opcode, CurrentValue);
@@ -1225,7 +1225,7 @@ public:
return false;
uint32 iValue = Value ? 1 << (Value - 1) : 0;
target->SetUInt32Value(Opcode , iValue);
target->SetUInt32Value(Opcode, iValue);
handler->PSendSysMessage(LANG_SET_32BIT_FIELD, Opcode, iValue);
return true;
+6 -6
View File
@@ -498,18 +498,18 @@ public:
float z;
float ort;
uint32 mapid;
if (pmapid)
mapid = (uint32)atoi(pmapid);
else
mapid = _player->GetMapId();
if( port )
if ( port )
ort = (float)atof(port);
else
ort = _player->GetOrientation();
if( pz )
if ( pz )
{
z = (float)atof(pz);
if (!MapManager::IsValidMapCoord(mapid, x, y, z))
@@ -530,7 +530,7 @@ public:
Map const* map = sMapMgr->CreateBaseMap(mapid);
z = std::max(map->GetHeight(x, y, MAX_HEIGHT), map->GetWaterLevel(x, y));
}
// stop flight if need
if (_player->isInFlight())
{
+1 -1
View File
@@ -129,7 +129,7 @@ public:
{
Player* player = handler->GetSession()->GetPlayer();
sLog->outSQLDev("(@PATH,XX,%.3f,%.3f,%.5f,0,0,0,100,0),", player->GetPositionX(), player->GetPositionY(), player->GetPositionZ());
sLog->outSQLDev("(@PATH, XX, %.3f, %.3f, %.5f, 0,0, 0,100, 0),", player->GetPositionX(), player->GetPositionY(), player->GetPositionZ());
handler->PSendSysMessage("Waypoint SQL written to SQL Developer log");
return true;
+1 -1
View File
@@ -27,7 +27,7 @@ public:
{
static ChatCommand commandTable[] =
{
{ "dev", SEC_ADMINISTRATOR, false, &HandleDevCommand, "", NULL },
{ "dev", SEC_ADMINISTRATOR, false, &HandleDevCommand, "", NULL },
{ NULL, 0, false, NULL, "", NULL }
};
return commandTable;
+2 -2
View File
@@ -725,7 +725,7 @@ public:
uint32 num = 0;
num = atoi((char*)args);
switch(num)
switch (num)
{
case 1:
mId=14340;
@@ -1282,7 +1282,7 @@ public:
return false;
uint32 anim_id = atoi((char*)args);
handler->GetSession()->GetPlayer()->SetUInt32Value(UNIT_NPC_EMOTESTATE , anim_id);
handler->GetSession()->GetPlayer()->SetUInt32Value(UNIT_NPC_EMOTESTATE, anim_id);
return true;
}
+2 -2
View File
@@ -952,7 +952,7 @@ public:
// make some emotes
char lastchar = args[strlen(args) - 1];
switch(lastchar)
switch (lastchar)
{
case '?': creature->HandleEmoteCommand(EMOTE_ONESHOT_QUESTION); break;
case '!': creature->HandleEmoteCommand(EMOTE_ONESHOT_EXCLAMATION); break;
@@ -1272,7 +1272,7 @@ public:
bool added = false;
if (tmpItem)
{
switch(SlotID)
switch (SlotID)
{
case 1:
creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, ItemID);
+1 -1
View File
@@ -77,7 +77,7 @@ public:
// check item starting quest (it can work incorrectly if added without item in inventory)
ItemTemplateContainer const* itc = sObjectMgr->GetItemTemplateStore();
ItemTemplateContainer::const_iterator result = find_if(itc->begin(), itc->end(), Finder<uint32, ItemTemplate>(entry, &ItemTemplate::StartQuest));
ItemTemplateContainer::const_iterator result = find_if (itc->begin(), itc->end(), Finder<uint32, ItemTemplate>(entry, &ItemTemplate::StartQuest));
if (result != itc->end())
{
+2 -2
View File
@@ -226,7 +226,7 @@ public:
static bool HandleReloadAllNpcCommand(ChatHandler* handler, const char* args)
{
if(*args != 'a') // will be reloaded from all_gossips
if (*args != 'a') // will be reloaded from all_gossips
HandleReloadNpcTrainerCommand(handler, "a");
HandleReloadNpcVendorCommand(handler, "a");
HandleReloadPointsOfInterestCommand(handler, "a");
@@ -298,7 +298,7 @@ public:
{
HandleReloadGossipMenuCommand(handler, "a");
HandleReloadGossipMenuOptionCommand(handler, "a");
if(*args != 'a') // already reload from all_scripts
if (*args != 'a') // already reload from all_scripts
HandleReloadPointsOfInterestCommand(handler, "a");
return true;
}
@@ -92,7 +92,7 @@ class mob_av_marshal_or_warmaster : public CreatureScript
{
if (!bHasAura)
{
switch(me->GetEntry())
switch (me->GetEntry())
{
case NPC_NORTH_MARSHAL:
DoCast(me, SPELL_NORTH_MARSHAL);
@@ -211,7 +211,7 @@ public:
void WaypointReached(uint32 i)
{
switch(i)
switch (i)
{
case 0:
DoScriptText(SCRIPT_TEXT1, me);//2
@@ -297,7 +297,7 @@ public:
{
if (Event_Timer <= diff)
{
switch(EventPhase)
switch (EventPhase)
{
case 0:
DoScriptText(SCRIPT_TEXT5, me);//1
@@ -662,7 +662,7 @@ public:
void WaypointReached(uint32 i)
{
switch(i)
switch (i)
{
case 0:me->Say(SAY_DUGHAL_FREE, LANG_UNIVERSAL, PlayerGUID); break;
case 1:pInstance->SetData(DATA_DUGHAL, ENCOUNTER_STATE_OBJECTIVE_COMPLETED);break;
@@ -785,7 +785,7 @@ public:
void WaypointReached(uint32 i)
{
switch(i)
switch (i)
{
case 1:
me->Say(SAY_WINDSOR_1, LANG_UNIVERSAL, PlayerGUID);
@@ -822,7 +822,7 @@ public:
me->SetVisibility(VISIBILITY_OFF);
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
me->SummonCreature(MOB_ENTRY_REGINALD_WINDSOR, 403.61f, -51.71f, -63.92f, 3.600434f, TEMPSUMMON_DEAD_DESPAWN , 0);
me->SummonCreature(MOB_ENTRY_REGINALD_WINDSOR, 403.61f, -51.71f, -63.92f, 3.600434f, TEMPSUMMON_DEAD_DESPAWN, 0);
pInstance->SetData(DATA_SUPPLY_ROOM, ENCOUNTER_STATE_ENDED);
break;
}
@@ -959,7 +959,7 @@ public:
void WaypointReached(uint32 i)
{
wp=i;
switch(i)
switch (i)
{
case 0:
me->setFaction(11);
@@ -1166,7 +1166,7 @@ public:
void WaypointReached(uint32 i)
{
switch(i)
switch (i)
{
case 0:me->Say(SAY_TOBIAS_FREE, LANG_UNIVERSAL, PlayerGUID); break;
case 2:
@@ -1293,7 +1293,7 @@ public:
if (!pInstance)
return;
switch(i)
switch (i)
{
case 1:
me->HandleEmoteCommand(EMOTE_ONESHOT_KICK);
@@ -162,7 +162,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case NPC_EMPEROR: EmperorGUID = creature->GetGUID(); break;
case NPC_PHALANX: PhalanxGUID = creature->GetGUID(); break;
@@ -184,7 +184,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_ARENA1: GoArena1GUID = go->GetGUID(); break;
case GO_ARENA2: GoArena2GUID = go->GetGUID(); break;
@@ -220,7 +220,7 @@ public:
{
sLog->outDebug(LOG_FILTER_TSCR, "TSCR: Instance Blackrock Depths: SetData64 update (Type: %u Data " UI64FMTD ")", type, data);
switch(type)
switch (type)
{
case DATA_EVENSTARTER:
TombEventStarterGUID = data;
@@ -236,7 +236,7 @@ public:
{
sLog->outDebug(LOG_FILTER_TSCR, "TSCR: Instance Blackrock Depths: SetData update (Type: %u Data %u)", type, data);
switch(type)
switch (type)
{
case TYPE_RING_OF_LAW:
m_auiEncounter[0] = data;
@@ -281,7 +281,7 @@ public:
uint32 GetData(uint32 type)
{
switch(type)
switch (type)
{
case TYPE_RING_OF_LAW:
return m_auiEncounter[0];
@@ -306,7 +306,7 @@ public:
uint64 GetData64(uint32 data)
{
switch(data)
switch (data)
{
case DATA_EMPEROR:
return EmperorGUID;
@@ -27,7 +27,7 @@ enum Data
DATA_UROK_DOOMHOWL, // not scripted
DATA_QUARTERMASTER_ZIGRIS,
DATA_GIZRUL_THE_SLAVENER, // not scripted
DATA_HALYCON ,
DATA_HALYCON,
DATA_OVERLORD_WYRMTHALAK,
DATA_PYROGAURD_EMBERSEER,
DATA_WARCHIEF_REND_BLACKHAND,
@@ -81,7 +81,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case NPC_OMOKK:
HighlordOmokk = creature->GetGUID();
@@ -130,7 +130,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_WHELP_SPAWNER:
go->CastSpell(NULL, SPELL_SUMMON_ROOKERY_WHELP);
@@ -169,7 +169,7 @@ public:
uint64 GetData64(uint32 type)
{
switch(type)
switch (type)
{
case DATA_OMOKK:
return HighlordOmokk;
@@ -98,7 +98,7 @@ public:
bool OnGossipHello(Player* player, Creature* creature)
{
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_1 , GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
player->SEND_GOSSIP_MENU(7134, creature->GetGUID());
return true;
}
@@ -138,7 +138,7 @@ public:
{
if (uiTimer <= uiDiff)
{
switch(uiPhase)
switch (uiPhase)
{
case 1:
me->HandleEmoteCommand(EMOTE_STATE_KNEEL); //dosen't work?
@@ -186,7 +186,7 @@ class instance_deadmines : public InstanceMapScript
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_FACTORY_DOOR: FactoryDoorGUID = go->GetGUID(); break;
case GO_IRONCLAD_DOOR: IronCladDoorGUID = go->GetGUID(); break;
@@ -273,7 +273,7 @@ public:
if (me->getFaction() != GetPlayerForEscort()->getFaction())
me->setFaction(GetPlayerForEscort()->getFaction());
switch(uiPoint)
switch (uiPoint)
{
case 3:
SetEscortPaused(true);
@@ -312,7 +312,7 @@ public:
void SetData(uint32 uiI, uint32 uiValue)
{
switch(uiI)
switch (uiI)
{
case 1:
SetEscortPaused(true);
@@ -323,7 +323,7 @@ public:
if (!pInstance)
return;
switch(uiValue)
switch (uiValue)
{
case 1:
pInstance->SetData(TYPE_EVENT, IN_PROGRESS);
@@ -339,7 +339,7 @@ public:
void Summon(uint8 uiCase)
{
switch(uiCase)
switch (uiCase)
{
case 1:
me->SummonCreature(NPC_CAVERNDEEP_AMBUSHER, SpawnPosition[0], TEMPSUMMON_CORPSE_TIMED_DESPAWN, 1800000);
@@ -417,7 +417,7 @@ public:
{
if (uiTimer <= uiDiff)
{
switch(uiPhase)
switch (uiPhase)
{
case 1:
DoScriptText(SAY_BLASTMASTER_1, me);
@@ -77,7 +77,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case NPC_BLASTMASTER_EMI_SHORTFUSE: uiBastmasterEmiShortfuseGUID = creature->GetGUID(); break;
}
@@ -85,7 +85,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_CAVE_IN_LEFT:
uiCaveInLeftGUID = go->GetGUID();
@@ -102,7 +102,7 @@ public:
void SetData(uint32 uiType, uint32 uiData)
{
switch(uiType)
switch (uiType)
{
case TYPE_EVENT:
m_auiEncounter[0] = uiData;
@@ -114,7 +114,7 @@ public:
uint32 GetData(uint32 uiType)
{
switch(uiType)
switch (uiType)
{
case TYPE_EVENT: return m_auiEncounter[0];
}
@@ -123,7 +123,7 @@ public:
uint64 GetData64(uint32 uiType)
{
switch(uiType)
switch (uiType)
{
case DATA_GO_CAVE_IN_LEFT: return uiCaveInLeftGUID;
case DATA_GO_CAVE_IN_RIGHT: return uiCaveInRightGUID;
@@ -43,7 +43,7 @@ EndScriptData */
#define MOUNTED_DISPLAYID 16040
//Attumen (TODO: Use the summoning spell instead of Creature id. It works , but is not convenient for us)
//Attumen (TODO: Use the summoning spell instead of Creature id. It works, but is not convenient for us)
#define SUMMON_ATTUMEN 15550
class boss_attumen : public CreatureScript
@@ -108,7 +108,7 @@ public:
struct netherspite_infernalAI : public ScriptedAI
{
netherspite_infernalAI(Creature* c) : ScriptedAI(c) ,
netherspite_infernalAI(Creature* c) : ScriptedAI(c),
HellfireTimer(0), CleanupTimer(0), malchezaar(0), point(NULL) {}
uint32 HellfireTimer;
@@ -183,7 +183,7 @@ public:
void SetData64(uint32 identifier, uint64 data)
{
switch(identifier)
switch (identifier)
{
case DATA_IMAGE_OF_MEDIVH: ImageGUID = data;
}
@@ -191,7 +191,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case 183932: m_uiCurtainGUID = go->GetGUID(); break;
case 184278:
@@ -221,7 +221,7 @@ public:
case 185119: DustCoveredChest = go->GetGUID(); break;
}
switch(m_uiOperaEvent)
switch (m_uiOperaEvent)
{
//TODO: Set Object visibilities for Opera based on performance
case EVENT_OZ:
@@ -163,7 +163,7 @@ public:
if (!pInstance)
return;
switch(i)
switch (i)
{
case 0:
DoCast(me, SPELL_TUXEDO, false);
@@ -197,7 +197,7 @@ public:
{
int32 text = 0;
switch(m_uiEventId)
switch (m_uiEventId)
{
case EVENT_OZ:
if (OzDialogue[count].textid)
@@ -231,7 +231,7 @@ public:
uint8 index = 0;
uint8 count = 0;
switch(m_uiEventId)
switch (m_uiEventId)
{
case EVENT_OZ:
index = 0;
@@ -329,7 +329,7 @@ public:
player->PlayerTalkClass->ClearMenus();
npc_barnesAI* pBarnesAI = CAST_AI(npc_barnes::npc_barnesAI, creature->AI());
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF+1:
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, OZ_GOSSIP2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
@@ -538,7 +538,7 @@ public:
{
Unit* arca = Unit::GetUnit((*me), ArcanagosGUID);
Map* pMap = me->GetMap();
switch(Step)
switch (Step)
{
case 0: return 9999999;
case 1:
@@ -276,7 +276,7 @@ public:
if (!UpdateVictim())
return;
switch(Phase)
switch (Phase)
{
case 0:
{
@@ -353,7 +353,7 @@ public:
{
if (GravityLapseTimer <= diff)
{
switch(GravityLapsePhase)
switch (GravityLapsePhase)
{
case 0:
if (FirstGravityLapse) // Different yells at 50%, and at every following Gravity Lapse
@@ -97,7 +97,7 @@ public:
uint32 GetData(uint32 identifier)
{
switch(identifier)
switch (identifier)
{
case DATA_SELIN_EVENT: return m_auiEncounter[0];
case DATA_VEXALLUS_EVENT: return m_auiEncounter[1];
@@ -111,7 +111,7 @@ public:
void SetData(uint32 identifier, uint32 data)
{
switch(identifier)
switch (identifier)
{
case DATA_SELIN_EVENT: m_auiEncounter[0] = data; break;
case DATA_VEXALLUS_EVENT:
@@ -139,7 +139,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case 24723: SelinGUID = creature->GetGUID(); break;
case 24560: DelrissaGUID = creature->GetGUID(); break;
@@ -149,7 +149,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case 187896: VexallusDoorGUID = go->GetGUID(); break;
//SunwellRaid Gate 02
@@ -165,7 +165,7 @@ public:
uint64 GetData64(uint32 identifier)
{
switch(identifier)
switch (identifier)
{
case DATA_SELIN: return SelinGUID;
case DATA_DELRISSA: return DelrissaGUID;
@@ -59,7 +59,7 @@ public:
bool OnGossipSelect(Player* player, Creature* creature, uint32 /*uiSender*/, uint32 uiAction)
{
player->PlayerTalkClass->ClearMenus();
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF:
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_KAEL_2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
@@ -173,7 +173,7 @@ public:
void UpdateAI(const uint32 diff)
{
switch(phase)
switch (phase)
{
case PHASE_CHAINED:
if (!anchorGUID)
@@ -247,7 +247,7 @@ public:
while (uint32 eventId = events.ExecuteEvent())
{
switch(eventId)
switch (eventId)
{
case EVENT_ICY_TOUCH:
DoCast(me->getVictim(), SPELL_ICY_TOUCH);
@@ -553,7 +553,7 @@ public:
if (PhaseTimer <= diff)
{
switch(Phase)
switch (Phase)
{
case 0:
me->MonsterSay(SAY_DARK_RIDER, LANG_UNIVERSAL, 0);
@@ -109,7 +109,7 @@ public:
return;
}
switch(uiSpeech_counter)
switch (uiSpeech_counter)
{
case 1: DoScriptText(SAY_PERSUADED1, me); uiSpeech_timer = 8000; break;
case 2: DoScriptText(SAY_PERSUADED2, me); uiSpeech_timer = 8000; break;
@@ -220,7 +220,7 @@ public:
void WaypointReached(uint32 uiPointId)
{
switch(uiPointId)
switch (uiPointId)
{
case 0:
DoScriptText(SAY_BREAKOUT1, me);
@@ -281,7 +281,7 @@ public:
{
if (m_uiWave_Timer <= uiDiff)
{
switch(m_uiWave)
switch (m_uiWave)
{
case 0:
DoScriptText(SAY_BREAKOUT3, me);
@@ -397,7 +397,7 @@ public:
{
if (uiStage_timer <= diff)
{
switch(uiStage)
switch (uiStage)
{
case 1:
me->AddUnitMovementFlag(MOVEMENTFLAG_WALKING);
@@ -610,7 +610,7 @@ public:
bool MeetQuestCondition(Unit* player)
{
switch(me->GetEntry())
switch (me->GetEntry())
{
case 29061: // Ellen Stanbridge
if (CAST_PLR(player)->GetQuestStatus(12742) == QUEST_STATUS_INCOMPLETE)
@@ -682,10 +682,10 @@ public:
//TODO: simplify text's selection
switch(player->getRace())
switch (player->getRace())
{
case RACE_HUMAN:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -713,7 +713,7 @@ public:
}
break;
case RACE_ORC:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -741,7 +741,7 @@ public:
}
break;
case RACE_DWARF:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_2, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -769,7 +769,7 @@ public:
}
break;
case RACE_NIGHTELF:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -797,7 +797,7 @@ public:
}
break;
case RACE_UNDEAD_PLAYER:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -825,7 +825,7 @@ public:
}
break;
case RACE_TAUREN:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -853,7 +853,7 @@ public:
}
break;
case RACE_GNOME:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -881,7 +881,7 @@ public:
}
break;
case RACE_TROLL:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_3, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -909,7 +909,7 @@ public:
}
break;
case RACE_BLOODELF:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -937,7 +937,7 @@ public:
}
break;
case RACE_DRAENEI:
switch(ExecuteSpeech_Counter)
switch (ExecuteSpeech_Counter)
{
case 0: DoScriptText(SAY_EXEC_START_1, me, player); break;
case 1: me->SetStandState(UNIT_STAND_STATE_STAND); break;
@@ -23,7 +23,7 @@
enum mograine
{
#ifdef LESS_MOB
ENCOUNTER_DK_NUMBER = 5, // how many player queue to start the quest , or -
ENCOUNTER_DK_NUMBER = 5, // how many player queue to start the quest, or -
ENCOUNTER_DK_TIMER = 10, // *every 5 minutes. These have to be done in instance data
ENCOUNTER_DEFENDER_NUMBER = 10, // how many of defender
ENCOUNTER_EARTHSHATTER_NUMBER = 1, // how many of earthshatter
@@ -32,7 +32,7 @@ enum mograine
ENCOUNTER_GHOUL_NUMBER = 5, // how many of ghoul
ENCOUNTER_WARRIOR_NUMBER = 1, // how many of warrior
#else
ENCOUNTER_DK_NUMBER = 5, // how many player queue to start the quest , or -
ENCOUNTER_DK_NUMBER = 5, // how many player queue to start the quest, or -
ENCOUNTER_DK_TIMER = 10, // *every 5 minutes. These have to be done in instance data
ENCOUNTER_DEFENDER_NUMBER = 20, // how many of defender
ENCOUNTER_EARTHSHATTER_NUMBER = 20, // how many of earthshatter
@@ -69,7 +69,7 @@ public:
if (!player)
phase = 3;
switch(phase)
switch (phase)
{
case 0:
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
@@ -153,7 +153,7 @@ public:
void EnterCombat(Unit* /*who*/){}
void SetType(uint32 _type)
{
switch(Creaturetype = _type)
switch (Creaturetype = _type)
{
case 1:
spell = SPELL_PUMPKIN_AURA_GREEN;
@@ -257,7 +257,7 @@ public:
if (withbody)
return;
switch(Phase)
switch (Phase)
{
case 1:
if (me->HealthBelowPctDamaged(67, damage))
@@ -608,7 +608,7 @@ public:
{
if (withhead)
{
switch(Phase)
switch (Phase)
{
case 0:
{
@@ -76,7 +76,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case ENTRY_PUMPKIN_SHRINE: PumpkinShrineGUID = go->GetGUID();break;
case 104600: DoorHighInquisitorGUID = go->GetGUID(); break;
@@ -85,7 +85,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case ENTRY_HORSEMAN: HorsemanGUID = creature->GetGUID(); break;
case ENTRY_HEAD: HeadGUID = creature->GetGUID(); break;
@@ -98,7 +98,7 @@ public:
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case TYPE_MOGRAINE_AND_WHITE_EVENT:
if (data == IN_PROGRESS)
@@ -130,7 +130,7 @@ public:
uint64 GetData64(uint32 type)
{
switch(type)
switch (type)
{
//case GAMEOBJECT_PUMPKIN_SHRINE: return PumpkinShrineGUID;
//case DATA_HORSEMAN: return HorsemanGUID;
@@ -132,7 +132,7 @@ public:
DoModifyThreatPercent(target, -100);
Creature* Summoned = NULL;
switch(rand()%6)
switch (rand()%6)
{
case 0:
DoTeleportPlayer(target, 250.0696f, 0.3921f, 84.8408f, 3.149f);
@@ -83,7 +83,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_GATE_KIRTONOS: GateKirtonosGUID = go->GetGUID(); break;
case GO_GATE_GANDLING: GateGandlingGUID = go->GetGUID(); break;
@@ -98,7 +98,7 @@ public:
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case DATA_LORDALEXEIBAROV_DEATH:
IsBossDied[0] = true;
@@ -100,7 +100,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case NPC_ASH: uiAshGUID = creature->GetGUID(); break;
case NPC_ADA: uiAdaGUID = creature->GetGUID(); break;
@@ -110,7 +110,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_COURTYARD_DOOR:
DoorCourtyardGUID = go->GetGUID();
@@ -144,7 +144,7 @@ public:
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case TYPE_FREE_NPC:
if (data == DONE)
@@ -157,7 +157,7 @@ public:
m_auiEncounter[1] = data;
break;
case TYPE_FENRUS:
switch(data)
switch (data)
{
case DONE:
uiTimer = 1000;
@@ -192,7 +192,7 @@ public:
uint32 GetData(uint32 type)
{
switch(type)
switch (type)
{
case TYPE_FREE_NPC:
return m_auiEncounter[0];
@@ -248,7 +248,7 @@ public:
{
if (uiTimer <= uiDiff)
{
switch(uiPhase)
switch (uiPhase)
{
case 1:
summon = pArchmage->SummonCreature(pArchmage->GetEntry(), SpawnLocation[4], TEMPSUMMON_TIMED_DESPAWN, 10000);
@@ -101,7 +101,7 @@ public:
void WaypointReached(uint32 uiPoint)
{
switch(uiPoint)
switch (uiPoint)
{
case 0:
if (uiNpcEntry == NPC_ASH)
@@ -71,7 +71,7 @@ public:
if (pInstance)
{
switch(me->GetEntry())
switch (me->GetEntry())
{
case SH_AELMAR:
pInstance->SetData(TYPE_SH_AELMAR, 0);
@@ -100,7 +100,7 @@ public:
{
if (pInstance)
{
switch(me->GetEntry())
switch (me->GetEntry())
{
case SH_AELMAR:
pInstance->SetData(TYPE_SH_AELMAR, 2);
@@ -260,7 +260,7 @@ public:
void ReceiveEmote(Player* player, uint32 emote)
{
switch(emote)
switch (emote)
{
case TEXT_EMOTE_DANCE:
EnterEvadeMode();
@@ -94,7 +94,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_ATALAI_STATUE1: GOAtalaiStatue1 = go->GetGUID(); break;
case GO_ATALAI_STATUE2: GOAtalaiStatue2 = go->GetGUID(); break;
@@ -108,7 +108,7 @@ public:
virtual void Update(uint32 /*diff*/) // correct order goes form 1-6
{
switch(State)
switch (State)
{
case GO_ATALAI_STATUE1:
if (!s1 && !s2 && !s3 && !s4 && !s5 && !s6)
@@ -183,7 +183,7 @@ public:
void SpellHitTarget(Unit* target, const SpellInfo* spell)
{
switch(spell->Id)
switch (spell->Id)
{
case SPELL_SHADOW_BLADES:
case SPELL_SHADOW_NOVA:
@@ -199,7 +199,7 @@ public:
void HandleTouchedSpells(Unit* target, uint32 TouchedType)
{
switch(TouchedType)
switch (TouchedType)
{
case SPELL_FLAME_TOUCHED:
if (!target->HasAura(SPELL_DARK_FLAME))
@@ -477,7 +477,7 @@ public:
void SpellHitTarget(Unit* target, const SpellInfo* spell)
{
switch(spell->Id)
switch (spell->Id)
{
case SPELL_BLAZE:
@@ -494,7 +494,7 @@ public:
void HandleTouchedSpells(Unit* target, uint32 TouchedType)
{
switch(TouchedType)
switch (TouchedType)
{
case SPELL_FLAME_TOUCHED:
if (!target->HasAura(SPELL_DARK_FLAME))
@@ -702,7 +702,7 @@ public:
void SpellHitTarget(Unit* target, const SpellInfo* spell)
{
switch(spell->Id)
switch (spell->Id)
{
case SPELL_SHADOW_FURY:
@@ -239,7 +239,7 @@ public:
void EnterPhase(PhaseFelmyst NextPhase)
{
switch(NextPhase)
switch (NextPhase)
{
case PHASE_GROUND:
me->CastStop(SPELL_FOG_BREATH);
@@ -267,7 +267,7 @@ public:
void HandleFlightSequence()
{
switch(uiFlightCount)
switch (uiFlightCount)
{
case 0:
//me->AttackStop();
@@ -416,7 +416,7 @@ public:
if (phase == PHASE_GROUND)
{
switch(events.ExecuteEvent())
switch (events.ExecuteEvent())
{
case EVENT_BERSERK:
DoScriptText(YELL_BERSERK, me);
@@ -451,7 +451,7 @@ public:
if (phase == PHASE_FLIGHT)
{
switch(events.ExecuteEvent())
switch (events.ExecuteEvent())
{
case EVENT_BERSERK:
DoScriptText(YELL_BERSERK, me);
@@ -389,7 +389,7 @@ public:
void GoodEnding()
{
switch(TalkSequence)
switch (TalkSequence)
{
case 1:
me->setFaction(35);
@@ -411,7 +411,7 @@ public:
void BadEnding()
{
switch(TalkSequence)
switch (TalkSequence)
{
case 1:
DoScriptText(SAY_EVIL_ENRAGE, me);
@@ -491,7 +491,7 @@ public:
if (YellTimer <= diff)
{
switch(YellSequence)
switch (YellSequence)
{
case 0:
DoScriptText(SAY_GOOD_AGGRO, me);
@@ -278,7 +278,7 @@ public:
if (!pInstance)
return NULL;
switch(index)
switch (index)
{
case 0:
return pInstance->instance->GetGameObject(pInstance->GetData64(DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1));
@@ -334,7 +334,7 @@ public:
OrbsEmpowered = (OrbsEmpowered+1)%4;
++EmpowerCount;
switch(EmpowerCount)
switch (EmpowerCount)
{
case 1: DoScriptText(SAY_KALEC_ORB_READY1, me); break;
case 2: DoScriptText(SAY_KALEC_ORB_READY2, me); break;
@@ -445,7 +445,7 @@ public:
void JustSummoned(Creature* summoned)
{
switch(summoned->GetEntry())
switch (summoned->GetEntry())
{
case CREATURE_HAND_OF_THE_DECEIVER:
summoned->CastSpell(summoned, SPELL_SHADOW_CHANNELING, false);
@@ -697,13 +697,13 @@ public:
{
if (Timer[t] < diff && !TimerIsDeactivated[t])
{
switch(t)
switch (t)
{
case TIMER_SPEECH:
if (SpeechBegins)
{
SpeechBegins=false;
switch(Phase)
switch (Phase)
{
case PHASE_NORMAL:
speechPhaseEnd=1;
@@ -1139,7 +1139,7 @@ public:
{
if (uiTimer <= diff)
{
switch(spell)
switch (spell)
{
case 0:
DoCast(me, SPELL_ARMAGEDDON_VISUAL, true);
@@ -1314,7 +1314,7 @@ public:
}
}
switch(victimClass) {
switch (victimClass) {
case CLASS_DRUID:
if (uiTimer[1] <= diff)
{
@@ -85,8 +85,8 @@ float DarkFiends[8][4] =
{1801.98f, 633.62f, 69.74f, 5.71f},
{1830.88f, 629.99f, 69.73f, 3.52f},
{1800.38f, 621.41f, 69.74f, 0.22f},
{1808.3f , 612.45f, 69.73f, 1.02f},
{1823.9f , 639.69f, 69.74f, 4.12f},
{1808.3f, 612.45f, 69.73f, 1.02f},
{1823.9f, 639.69f, 69.74f, 4.12f},
{1811.85f, 640.46f, 69.73f, 4.97f}
};
@@ -95,7 +95,7 @@ float Humanoides[6][5] =
{CREATURE_FURY_MAGE, 1780.16f, 666.83f, 71.19f, 5.21f},
{CREATURE_FURY_MAGE, 1847.93f, 600.30f, 71.30f, 2.57f},
{CREATURE_BERSERKER, 1779.97f, 660.64f, 71.19f, 5.28f},
{CREATURE_BERSERKER, 1786.2f , 661.01f, 71.19f, 4.51f},
{CREATURE_BERSERKER, 1786.2f, 661.01f, 71.19f, 4.51f},
{CREATURE_BERSERKER, 1845.17f, 602.63f, 71.28f, 2.43f},
{CREATURE_BERSERKER, 1842.91f, 599.93f, 71.23f, 2.44f}
};
@@ -145,7 +145,7 @@ public:
void JustSummoned(Creature* summoned)
{
switch(summoned->GetEntry())
switch (summoned->GetEntry())
{
case CREATURE_DARK_FIENDS:
summoned->CastSpell(summoned, SPELL_DARKFIEND_VISUAL, false);
@@ -270,7 +270,7 @@ public:
void JustSummoned(Creature* summoned)
{
switch(summoned->GetEntry())
switch (summoned->GetEntry())
{
case BOSS_ENTROPIUS:
me->SetVisible(false);
@@ -294,7 +294,7 @@ public:
{
if (!pInstance)
return;
switch(pInstance->GetData(DATA_MURU_EVENT))
switch (pInstance->GetData(DATA_MURU_EVENT))
{
case NOT_STARTED:
Reset();
@@ -318,7 +318,7 @@ public:
{
if (Timer[i] <= diff)
{
switch(i)
switch (i)
{
case TIMER_DARKNESS:
if (!DarkFiend)
@@ -419,7 +419,7 @@ public:
me->GetHomePosition(x, y, z, o);
DoTeleportTo(x, y, z);
InAction = true;
switch(Spell->Id)
switch (Spell->Id)
{
case SPELL_OPEN_ALL_PORTALS:
DoCastAOE(SPELL_OPEN_PORTAL, false);
@@ -140,7 +140,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case 24850: Kalecgos_Dragon = creature->GetGUID(); break;
case 24891: Kalecgos_Human = creature->GetGUID(); break;
@@ -160,7 +160,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case 188421: ForceField = go->GetGUID(); break;
case 188523: KalecgosWall[0] = go->GetGUID(); break;
@@ -181,7 +181,7 @@ public:
uint32 GetData(uint32 id)
{
switch(id)
switch (id)
{
case DATA_KALECGOS_EVENT: return m_auiEncounter[0];
case DATA_BRUTALLUS_EVENT: return m_auiEncounter[1];
@@ -195,7 +195,7 @@ public:
uint64 GetData64(uint32 id)
{
switch(id)
switch (id)
{
case DATA_KALECGOS_DRAGON: return Kalecgos_Dragon;
case DATA_KALECGOS_HUMAN: return Kalecgos_Human;
@@ -220,7 +220,7 @@ public:
void SetData(uint32 id, uint32 data)
{
switch(id)
switch (id)
{
case DATA_KALECGOS_EVENT:
{
@@ -246,7 +246,7 @@ public:
m_auiEncounter[2] = data; break;
case DATA_EREDAR_TWINS_EVENT: m_auiEncounter[3] = data; break;
case DATA_MURU_EVENT:
switch(data)
switch (data)
{
case DONE:
HandleGameObject(MurusGate[0], true);
@@ -105,14 +105,14 @@ class instance_uldaman : public InstanceMapScript
case GO_ALTAR_OF_THE_KEEPER_TEMPLE_DOOR: // lock the door
uiAltarOfTheKeeperTempleDoor = go->GetGUID();
if(m_auiEncounter[0] == DONE)
if (m_auiEncounter[0] == DONE)
HandleGameObject(0, true, go);
break;
case GO_ARCHAEDAS_TEMPLE_DOOR:
uiArchaedasTempleDoor = go->GetGUID();
if(m_auiEncounter[0] == DONE)
if (m_auiEncounter[0] == DONE)
HandleGameObject(0, true, go);
break;
@@ -121,7 +121,7 @@ class instance_uldaman : public InstanceMapScript
go->SetUInt32Value(GAMEOBJECT_FLAGS, 33);
uiAncientVaultDoor = go->GetGUID();
if(m_auiEncounter[1] == DONE)
if (m_auiEncounter[1] == DONE)
HandleGameObject(0, true, go);
break;
@@ -165,7 +165,7 @@ class instance_uldaman : public InstanceMapScript
void BlockGO(uint64 guid)
{
GameObject* go = instance->GetGameObject(guid);
if(!go)
if (!go)
return;
go->SetUInt32Value(GAMEOBJECT_FLAGS, GO_FLAG_INTERACT_COND);
@@ -255,7 +255,7 @@ class instance_uldaman : public InstanceMapScript
void ActivateIronaya()
{
Creature* ironaya = instance->GetCreature(uiIronayaGUID);
if(!ironaya)
if (!ironaya)
return;
ironaya->setFaction(415);
@@ -306,7 +306,7 @@ class instance_uldaman : public InstanceMapScript
if (!bKeystoneCheck)
return;
if(uiIronayaSealDoorTimer <= diff)
if (uiIronayaSealDoorTimer <= diff)
{
ActivateIronaya();
@@ -322,17 +322,17 @@ class instance_uldaman : public InstanceMapScript
void SetData (uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case DATA_ALTAR_DOORS:
m_auiEncounter[0] = data;
if(data == DONE)
if (data == DONE)
SetDoor(uiAltarOfTheKeeperTempleDoor, true);
break;
case DATA_ANCIENT_DOOR:
m_auiEncounter[1] = data;
if(data == DONE) //archeadas defeat
if (data == DONE) //archeadas defeat
{
SetDoor(uiArchaedasTempleDoor, true); //re open enter door
SetDoor(uiAncientVaultDoor, true);
@@ -348,7 +348,7 @@ class instance_uldaman : public InstanceMapScript
break;
case DATA_MINIONS:
switch(data)
switch (data)
{
case NOT_STARTED:
if (m_auiEncounter[0] == DONE) //if players opened the doors
@@ -446,7 +446,7 @@ class instance_uldaman : public InstanceMapScript
case 7228: // Ironaya
uiIronayaGUID = creature->GetGUID();
if(m_auiEncounter[2] != DONE)
if (m_auiEncounter[2] != DONE)
SetFrozenState (creature);
break;
@@ -155,7 +155,7 @@ class boss_halazzi : public CreatureScript
void EnterPhase(PhaseHalazzi NextPhase)
{
switch(NextPhase)
switch (NextPhase)
{
case PHASE_LYNX:
case PHASE_ENRAGE:
@@ -439,7 +439,7 @@ class boss_hexlord_malacrass : public CreatureScript
{
uint8 random = urand(0, 2);
Unit* target = NULL;
switch(PlayerAbility[PlayerClass][random].target)
switch (PlayerAbility[PlayerClass][random].target)
{
case ABILITY_TARGET_SELF:
target = me;
@@ -206,7 +206,7 @@ class boss_nalorakk : public CreatureScript
{
if (!inMove)
{
switch(MovePhase)
switch (MovePhase)
{
case 0:
if (me->IsWithinDistInMap(who, 50))
@@ -314,7 +314,7 @@ class boss_nalorakk : public CreatureScript
if (MovePhase != id)
return;
switch(MovePhase)
switch (MovePhase)
{
case 2:
me->SetOrientation(3.1415f*2);
@@ -340,7 +340,7 @@ class boss_zuljin : public CreatureScript
void EnterPhase(uint32 NextPhase)
{
switch(NextPhase)
switch (NextPhase)
{
case 0:
break;
@@ -116,7 +116,7 @@ class instance_zulaman : public InstanceMapScript
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case 23578://janalai
case 23863://zuljin
@@ -129,7 +129,7 @@ class instance_zulaman : public InstanceMapScript
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case 186303: HalazziDoorGUID = go->GetGUID(); break;
case 186304: ZulJinGateGUID = go->GetGUID(); break;
@@ -205,7 +205,7 @@ class instance_zulaman : public InstanceMapScript
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case DATA_NALORAKKEVENT:
m_auiEncounter[0] = data;
@@ -279,7 +279,7 @@ class instance_zulaman : public InstanceMapScript
uint32 GetData(uint32 type)
{
switch(type)
switch (type)
{
case DATA_NALORAKKEVENT: return m_auiEncounter[0];
case DATA_AKILZONEVENT: return m_auiEncounter[1];
@@ -65,7 +65,7 @@ class npc_forest_frog : public CreatureScript
if (pInstance)
{
uint32 cEntry = 0;
switch(rand()%10)
switch (rand()%10)
{
case 0: cEntry = 24397; break; //Mannuth
case 1: cEntry = 24403; break; //Deez
@@ -178,22 +178,22 @@ class boss_venoxis : public CreatureScript
while (uint32 eventId = events.ExecuteEvent())
{
switch(eventId)
switch (eventId)
{
// thrash is available in all phases
case EVENT_THRASH:
DoCast(me, SPELL_THRASH, true);
events.ScheduleEvent(EVENT_THRASH, urand(10000,20000));
events.ScheduleEvent(EVENT_THRASH, urand(10000, 20000));
break;
// troll form spells and actions (first part)
case EVENT_DISPEL_MAGIC:
DoCast(me, SPELL_DISPEL_MAGIC);
events.ScheduleEvent(EVENT_DISPEL_MAGIC, urand(15000,20000), 0, PHASE_ONE);
events.ScheduleEvent(EVENT_DISPEL_MAGIC, urand(15000, 20000), 0, PHASE_ONE);
break;
case EVENT_RENEW:
DoCast(me, SPELL_RENEW);
events.ScheduleEvent(EVENT_RENEW, urand(25000,30000), 0, PHASE_ONE);
events.ScheduleEvent(EVENT_RENEW, urand(25000, 30000), 0, PHASE_ONE);
break;
case EVENT_HOLY_NOVA:
_inMeleeRange = 0;
@@ -210,17 +210,17 @@ class boss_venoxis : public CreatureScript
if (_inMeleeRange >= 3)
DoCast(me->getVictim(), SPELL_HOLY_NOVA);
events.ScheduleEvent(EVENT_HOLY_NOVA, urand(45000,75000), 0, PHASE_ONE);
events.ScheduleEvent(EVENT_HOLY_NOVA, urand(45000, 75000), 0, PHASE_ONE);
break;
case EVENT_HOLY_FIRE:
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM))
DoCast(target, SPELL_HOLY_FIRE);
events.ScheduleEvent(EVENT_HOLY_FIRE, urand(45000,60000), 0, PHASE_ONE);
events.ScheduleEvent(EVENT_HOLY_FIRE, urand(45000, 60000), 0, PHASE_ONE);
break;
case EVENT_HOLY_WRATH:
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM))
DoCast(target, SPELL_HOLY_WRATH);
events.ScheduleEvent(EVENT_HOLY_WRATH, urand(45000,60000), 0, PHASE_ONE);
events.ScheduleEvent(EVENT_HOLY_WRATH, urand(45000, 60000), 0, PHASE_ONE);
break;
//
@@ -230,12 +230,12 @@ class boss_venoxis : public CreatureScript
case EVENT_VENOM_SPIT:
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM))
DoCast(target, SPELL_VENOM_SPIT);
events.ScheduleEvent(EVENT_VENOM_SPIT, urand(5000,15000), 0, PHASE_TWO);
events.ScheduleEvent(EVENT_VENOM_SPIT, urand(5000, 15000), 0, PHASE_TWO);
break;
case EVENT_POISON_CLOUD:
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM))
DoCast(target, SPELL_POISON_CLOUD);
events.ScheduleEvent(EVENT_POISON_CLOUD, urand(15000,20000), 0, PHASE_TWO);
events.ScheduleEvent(EVENT_POISON_CLOUD, urand(15000, 20000), 0, PHASE_TWO);
break;
case EVENT_PARASITIC_SERPENT:
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM))
@@ -65,7 +65,7 @@ class instance_zulgurub : public InstanceMapScript
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case 11347: m_uiLorKhanGUID = creature->GetGUID(); break;
case 11348: m_uiZathGUID = creature->GetGUID(); break;
@@ -76,7 +76,7 @@ class instance_zulgurub : public InstanceMapScript
void SetData(uint32 uiType, uint32 uiData)
{
switch(uiType)
switch (uiType)
{
case DATA_ARLOKK:
m_auiEncounter[0] = uiData;
@@ -114,7 +114,7 @@ class instance_zulgurub : public InstanceMapScript
uint32 GetData(uint32 uiType)
{
switch(uiType)
switch (uiType)
{
case DATA_ARLOKK:
return m_auiEncounter[0];
@@ -138,7 +138,7 @@ class instance_zulgurub : public InstanceMapScript
uint64 GetData64(uint32 uiData)
{
switch(uiData)
switch (uiData)
{
case DATA_LORKHAN:
return m_uiLorKhanGUID;
@@ -71,7 +71,7 @@ class npc_professor_phizzlethorpe : public CreatureScript
if (!player)
return;
switch(uiPointId)
switch (uiPointId)
{
case 4:DoScriptText(SAY_PROGRESS_2, me, player);break;
case 5:DoScriptText(SAY_PROGRESS_3, me, player);break;
@@ -56,7 +56,7 @@ public:
bool OnGossipSelect(Player* player, Creature* creature, uint32 /*uiSender*/, uint32 uiAction)
{
player->PlayerTalkClass->ClearMenus();
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF+1:
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SELECT, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
@@ -222,7 +222,7 @@ public:
spellJudLight = false;
spellCommand = false;
switch(me->GetEntry())
switch (me->GetEntry())
{
case CHAMPION_BLOODWRATH:
spellFlashLight = true;
@@ -417,7 +417,7 @@ public:
{
CAST_AI(npc_second_trial_paladin::npc_secondTrialAI, paladinSpawn->AI())->Activate(me->GetGUID());
switch(paladinPhase)
switch (paladinPhase)
{
case 0:
DoScriptText(TEXT_SECOND_TRIAL_1, me);
@@ -178,7 +178,7 @@ public:
if (!player)
return;
switch(i)
switch (i)
{
case 0:
{
@@ -89,7 +89,7 @@ public:
void WaypointReached(uint32 uiPointId)
{
switch(uiPointId)
switch (uiPointId)
{
case 26:
DoScriptText(SAY_OOX_AMBUSH, me);
@@ -107,7 +107,7 @@ public:
void WaypointStart(uint32 uiPointId)
{
switch(uiPointId)
switch (uiPointId)
{
case 27:
for (uint8 i = 0; i < 3; ++i)
@@ -284,7 +284,7 @@ public:
if (!player)
return;
switch(uiPointId)
switch (uiPointId)
{
case 1:
DoScriptText(SAY_RIN_FREE, me, player);
@@ -317,7 +317,7 @@ public:
if (Unit* player = GetPlayerForEscort())
{
switch(m_uiPostEventCount)
switch (m_uiPostEventCount)
{
case 1:
DoScriptText(SAY_RIN_PROGRESS_1, me, player);
@@ -86,7 +86,7 @@ public:
if (uiI >= 65 && me->GetUnitMovementFlags() == MOVEMENTFLAG_WALKING)
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
switch(uiI)
switch (uiI)
{
case 39:
SetEscortPaused(true);
@@ -115,7 +115,7 @@ public:
{
if (uiTimer <= uiDiff)
{
switch(uiPhase)
switch (uiPhase)
{
case 1:
me->SetStandState(UNIT_STAND_STATE_SIT);
@@ -141,7 +141,7 @@ public:
if (!player)
return;
switch(i)
switch (i)
{
case 1: DoScriptText(SAY_START, me, player);break;
case 13:
@@ -346,7 +346,7 @@ public:
void WaypointReached(uint32 uiPointId)
{
switch(uiPointId)
switch (uiPointId)
{
case 14:
SetEscortPaused(true);
@@ -387,7 +387,7 @@ public:
{
if (uiTimer <= uiDiff)
{
switch(uiPhase)
switch (uiPhase)
{
case 1:
if (Creature* pGuard = me->FindNearestCreature(NPC_STORMWIND_ROYAL, 8.0f, true))
@@ -577,7 +577,7 @@ public:
void WaypointReached(uint32 uiPointId)
{
switch(uiPointId)
switch (uiPointId)
{
case 1:
SetEscortPaused(true);
@@ -605,7 +605,7 @@ public:
{
if (uiTimer <= uiDiff)
{
switch(uiPhase)
switch (uiPhase)
{
case 1:
DoScriptText(SAY_QUEST_ACCEPT_ATTACK, me);
@@ -123,7 +123,7 @@ public:
return;
}
switch(m_uiPhase)
switch (m_uiPhase)
{
case 1:
DoScriptText(SAY_COMPLETE, me);
@@ -52,7 +52,7 @@ public:
bool OnGossipSelect(Player* player, Creature* creature, uint32 /*uiSender*/, uint32 uiAction)
{
player->PlayerTalkClass->ClearMenus();
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_TRADE:
player->GetSession()->SendListInventory(creature->GetGUID());
@@ -191,7 +191,7 @@ public:
if (who->GetTypeId() == TYPEID_PLAYER)
{
switch(me->GetAreaId())
switch (me->GetAreaId())
{
case 199: //felstone
if (CAST_PLR(who)->GetQuestStatus(5216) == QUEST_STATUS_INCOMPLETE ||
@@ -358,7 +358,7 @@ public:
case 22:
break;
case 23:
Ughost = me->SummonCreature(NPC_GHOST_UTHER, 971.86f, -1825.42f , 81.99f , 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
Ughost = me->SummonCreature(NPC_GHOST_UTHER, 971.86f, -1825.42f, 81.99f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
Ughost->AddUnitMovementFlag(MOVEMENTFLAG_LEVITATING);
DoScriptText(SAY_WP_4, Ughost, me);
m_uiChatTimer = 4000;
@@ -83,7 +83,7 @@ public:
{
if (HasEscortState(STATE_ESCORT_ESCORTING))
{
switch(uiWPHolder)
switch (uiWPHolder)
{
case 7: DoScriptText(SAY_DS_DOWN_1, me); break;
case 8: DoScriptText(SAY_DS_DOWN_2, me); break;
@@ -105,7 +105,7 @@ public:
uiWPHolder = uiPoint;
switch(uiPoint)
switch (uiPoint)
{
case 4:
SetEquipmentSlots(false, EQUIP_NO_CHANGE, EQUIP_NO_CHANGE, EQUIP_ID_RIFLE);
@@ -69,7 +69,7 @@ public:
void WaypointReached(uint32 uiPointId)
{
switch(uiPointId)
switch (uiPointId)
{
case 2:
if (me->HasStealthAura())
@@ -148,7 +148,7 @@ class example_creature : public CreatureScript
{
me->HandleEmoteCommand(uiTextEmote);
switch(uiTextEmote)
switch (uiTextEmote)
{
case TEXT_EMOTE_DANCE:
DoScriptText(SAY_DANCE, me);
@@ -202,7 +202,7 @@ class example_escort : public CreatureScript
player->PlayerTalkClass->ClearMenus();
npc_escortAI* pEscortAI = CAST_AI(example_escort::example_escortAI, creature->AI());
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF+1:
player->CLOSE_GOSSIP_MENU();
@@ -204,7 +204,7 @@ public:
bool OnGossipSelect(Player* player, Creature* /*creature*/, uint32 /*uiSender*/, uint32 uiAction)
{
player->PlayerTalkClass->ClearMenus();
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF+1:
player->TeleportTo(1, 9952.239f, 2284.277f, 1341.394f, 1.595f);
@@ -238,7 +238,7 @@ public:
void WaypointReached(uint32 uiPoint)
{
switch(uiPoint)
switch (uiPoint)
{
case 4:
SetEscortPaused(true);
@@ -109,7 +109,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_FIRE_OF_AKU_MAI_1:
m_uiShrine1GUID = go->GetGUID();
@@ -143,7 +143,7 @@ public:
void SetData(uint32 uiType, uint32 uiData)
{
switch(uiType)
switch (uiType)
{
case TYPE_GELIHAST:
m_auiEncounter[0] = uiData;
@@ -213,7 +213,7 @@ public:
uint32 GetData(uint32 uiType)
{
switch(uiType)
switch (uiType)
{
case TYPE_GELIHAST:
return m_auiEncounter[0];
@@ -234,7 +234,7 @@ public:
uint64 GetData64(uint32 uiData)
{
switch(uiData)
switch (uiData)
{
case DATA_TWILIGHT_LORD_KELRIS:
return m_uiTwilightLordKelrisGUID;
@@ -311,7 +311,7 @@ public:
void GainSoulCharge(Player* victim)
{
switch(victim->getClass())
switch (victim->getClass())
{
case CLASS_PRIEST:
case CLASS_PALADIN:
@@ -54,7 +54,7 @@ public:
{
player->PlayerTalkClass->ClearMenus();
hyjalAI* ai = CAST_AI(hyjalAI, creature->AI());
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF + 1:
ai->StartEvent(player);
@@ -131,7 +131,7 @@ public:
player->PlayerTalkClass->ClearMenus();
hyjalAI* ai = CAST_AI(hyjalAI, creature->AI());
ai->DeSpawnVeins();//despawn the alliance veins
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF + 1:
ai->StartEvent(player);
@@ -361,7 +361,7 @@ void hyjalAI::Reset()
EnemyCount = 0;
// Set faction properly based on Creature entry
switch(me->GetEntry())
switch (me->GetEntry())
{
case JAINA:
Faction = 0;
@@ -450,7 +450,7 @@ void hyjalAI::SummonCreature(uint32 entry, float Base[4][3])
SpawnLoc[i] = Base[random][i];
}
Creature* creature = NULL;
switch(entry)
switch (entry)
{
case 17906: //GARGOYLE
@@ -463,7 +463,7 @@ void hyjalAI::SummonCreature(uint32 entry, float Base[4][3])
creature = me->SummonCreature(entry, SpawnPointSpecial[SPAWN_GARG_GATE][0]+irand(-10, 10), SpawnPointSpecial[SPAWN_GARG_GATE][1]+irand(-10, 10), SpawnPointSpecial[SPAWN_GARG_GATE][2]+irand(-10, 10), 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 120000);
}
break;
case 17907: //FROST_WYRM ,
case 17907: //FROST_WYRM,
if (FirstBossDead && WaveCount == 1) //summon at gate
creature = me->SummonCreature(entry, SpawnPointSpecial[SPAWN_WYRM_GATE][0], SpawnPointSpecial[SPAWN_WYRM_GATE][1], SpawnPointSpecial[SPAWN_WYRM_GATE][2], 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 120000);
else
@@ -492,7 +492,7 @@ void hyjalAI::SummonCreature(uint32 entry, float Base[4][3])
creature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
creature->setActive(true);
switch(entry)
switch (entry)
{
case NECROMANCER:
case ABOMINATION:
@@ -751,7 +751,7 @@ void hyjalAI::UpdateAI(const uint32 diff)
if (DoHide)
{
DoHide = false;
switch(me->GetEntry())
switch (me->GetEntry())
{
case JAINA:
if (pInstance && pInstance->GetData(DATA_ALLIANCE_RETREAT))
@@ -810,7 +810,7 @@ void hyjalAI::UpdateAI(const uint32 diff)
IsDummy = true;
bRetreat = false;
HideNearPos(me->GetPositionX(), me->GetPositionY());
switch(me->GetEntry())
switch (me->GetEntry())
{
case JAINA://jaina
HideNearPos(5037.76f, -1889.71f);
@@ -892,7 +892,7 @@ void hyjalAI::UpdateAI(const uint32 diff)
Unit* target = NULL;
switch(Spells[i].TargetType)
switch (Spells[i].TargetType)
{
case TARGETTYPE_SELF: target = me; break;
case TARGETTYPE_RANDOM: target = SelectTarget(SELECT_TARGET_RANDOM, 0); break;
@@ -1071,7 +1071,7 @@ void hyjalAI::DoOverrun(uint32 faction, const uint32 diff)
if (!Teleported)
return;
Overrun = false;//execute once
switch(faction)
switch (faction)
{
case 0://alliance
for (uint8 i = 0; i < 92; ++i)//summon fires
@@ -197,7 +197,7 @@ void hyjal_trashAI::UpdateAI(const uint32 /*diff*/)
{
for (uint8 i = 0; i < 4; ++i)
AddWaypoint(i, AllianceWPs[i][0]+irand(-3, 3), AllianceWPs[i][1]+irand(-3, 3), AllianceWPs[i][2]);
switch(OverrunType)
switch (OverrunType)
{
case 0:
AddWaypoint(4, AllianceOverrunWP[22][0]+irand(-3, 3), AllianceOverrunWP[22][1]+irand(-3, 3), AllianceOverrunWP[22][2]);
@@ -257,7 +257,7 @@ void hyjal_trashAI::UpdateAI(const uint32 /*diff*/)
{
for (uint8 i = 0; i < 4; ++i)
AddWaypoint(i, AllianceWPs[i][0]+irand(-3, 3), AllianceWPs[i][1]+irand(-3, 3), AllianceWPs[i][2]);
switch(OverrunType)
switch (OverrunType)
{
case 0:
AddWaypoint(4, AllianceOverrunWP[1][0]+irand(-3, 3), AllianceOverrunWP[1][1]+irand(-3, 3), AllianceOverrunWP[1][2]);
@@ -332,7 +332,7 @@ void hyjal_trashAI::UpdateAI(const uint32 /*diff*/)
{
for (uint8 i = 0; i < 6; ++i)
AddWaypoint(i, HordeWPs[i][0]+irand(-3, 3), HordeWPs[i][1]+irand(-3, 3), HordeWPs[i][2]);
switch(OverrunType)
switch (OverrunType)
{
case 0:
AddWaypoint(5, HordeOverrunWP[16][0]+irand(-10, 10), HordeOverrunWP[16][1]+irand(-10, 10), HordeOverrunWP[16][2]);
@@ -117,7 +117,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case 182060:
HordeGate = go->GetGUID();
@@ -141,7 +141,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case 17767: RageWinterchill = creature->GetGUID(); break;
case 17808: Anetheron = creature->GetGUID(); break;
@@ -156,7 +156,7 @@ public:
uint64 GetData64(uint32 identifier)
{
switch(identifier)
switch (identifier)
{
case DATA_RAGEWINTERCHILL: return RageWinterchill;
case DATA_ANETHERON: return Anetheron;
@@ -173,7 +173,7 @@ public:
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case DATA_RAGEWINTERCHILLEVENT: m_auiEncounter[0] = data; break;
case DATA_ANETHERONEVENT:
@@ -282,7 +282,7 @@ public:
uint32 GetData(uint32 type)
{
switch(type)
switch (type)
{
case DATA_RAGEWINTERCHILLEVENT: return m_auiEncounter[0];
case DATA_ANETHERONEVENT: return m_auiEncounter[1];
@@ -126,7 +126,7 @@ public:
void UpdateAI(const uint32 diff)
{
switch(Phase)
switch (Phase)
{
case COMBAT:
//Return since we have no target
@@ -195,7 +195,7 @@ public:
case OUTRO:
if (uiOutroTimer < diff)
{
switch(uiOutroStep)
switch (uiOutroStep)
{
case 1:
DoScriptText(SAY_ESCAPE_SPEECH_1, me);
@@ -377,7 +377,7 @@ public:
if (pInstance) {
pInstance->SetData(DATA_ARTHAS_EVENT, NOT_STARTED);
switch(pInstance->GetData(DATA_ARTHAS_EVENT))
switch (pInstance->GetData(DATA_ARTHAS_EVENT))
{
case NOT_STARTED:
bStepping = true;
@@ -448,7 +448,7 @@ public:
void WaypointReached(uint32 uiPointId)
{
switch(uiPointId)
switch (uiPointId)
{
case 0:
case 1:
@@ -575,7 +575,7 @@ public:
{
if (uiPhaseTimer <= diff)
{
switch(uiStep)
switch (uiStep)
{
//After reset
case 0:
@@ -149,7 +149,7 @@ public:
uint8 GetRiftWaveId()
{
switch(mRiftPortalCount)
switch (mRiftPortalCount)
{
case 6:
mRiftWaveId = 2;
@@ -166,7 +166,7 @@ public:
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case TYPE_MEDIVH:
if (data == SPECIAL && m_auiEncounter[0] == IN_PROGRESS)
@@ -237,7 +237,7 @@ public:
uint32 GetData(uint32 type)
{
switch(type)
switch (type)
{
case TYPE_MEDIVH:
return m_auiEncounter[0];
@@ -103,7 +103,7 @@ public:
void OnCreatureCreate(Creature* creature)
{
switch(creature->GetEntry())
switch (creature->GetEntry())
{
case THRALL_ENTRY:
ThrallGUID = creature->GetGUID();
@@ -127,7 +127,7 @@ public:
return;
}
switch(type)
switch (type)
{
case TYPE_BARREL_DIVERSION:
{
@@ -202,7 +202,7 @@ public:
uint32 GetData(uint32 data)
{
switch(data)
switch (data)
{
case TYPE_BARREL_DIVERSION:
return m_auiEncounter[0];
@@ -222,7 +222,7 @@ public:
uint64 GetData64(uint32 data)
{
switch(data)
switch (data)
{
case DATA_THRALL:
return ThrallGUID;
@@ -202,7 +202,7 @@ public:
{
player->PlayerTalkClass->ClearMenus();
InstanceScript* pInstance = creature->GetInstanceScript();
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF+1:
player->CLOSE_GOSSIP_MENU();
@@ -301,7 +301,7 @@ public:
if (!pInstance)
return;
switch(i)
switch (i)
{
case 8:
SetRun(false);
@@ -513,7 +513,7 @@ public:
void JustSummoned(Creature* summoned)
{
switch(summoned->GetEntry())
switch (summoned->GetEntry())
{
//TODO: make Scarloc start into event instead, and not start attack directly
case MOB_ENTRY_BARN_GUARDSMAN:
@@ -633,7 +633,7 @@ public:
void WaypointReached(uint32 i)
{
switch(i)
switch (i)
{
case 6:
DoScriptText(SAY_TA_FREE, me);
@@ -85,7 +85,7 @@ public:
return;
}
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_WHELP_SPAWNER:
Position goPos;
@@ -141,7 +141,7 @@ public:
void SetData(uint32 uiType, uint32 uiData)
{
switch(uiType)
switch (uiType)
{
case DATA_ONYXIA:
m_auiEncounter[0] = uiData;
@@ -174,7 +174,7 @@ public:
void SetData64(uint32 uiType, uint64 uiData)
{
switch(uiType)
switch (uiType)
{
case DATA_FLOOR_ERUPTION_GUID:
FloorEruptionGUID[1] = FloorEruptionGUID[0];
@@ -186,7 +186,7 @@ public:
uint32 GetData(uint32 uiType)
{
switch(uiType)
switch (uiType)
{
case DATA_ONYXIA:
return m_auiEncounter[0];
@@ -197,7 +197,7 @@ public:
uint64 GetData64(uint32 uiData)
{
switch(uiData)
switch (uiData)
{
case DATA_ONYXIA_GUID:
return m_uiOnyxiasGUID;
@@ -238,7 +238,7 @@ public:
bool CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* /*source*/, Unit const* /*target*/ = NULL, uint32 /*miscvalue1*/ = 0)
{
switch(criteria_id)
switch (criteria_id)
{
case ACHIEV_CRITERIA_MANY_WHELPS_10_PLAYER: // Criteria for achievement 4403: Many Whelps! Handle It! (10 player) Hatch 50 eggs in 10s
case ACHIEV_CRITERIA_MANY_WHELPS_25_PLAYER: // Criteria for achievement 4406: Many Whelps! Handle It! (25 player) Hatch 50 eggs in 10s
@@ -100,7 +100,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_GONG:
uiGongGUID = go->GetGUID();
@@ -118,7 +118,7 @@ public:
{
uiGongWaves = uiData;
switch(uiGongWaves)
switch (uiGongWaves)
{
case 9:
case 14:
@@ -139,7 +139,7 @@ public:
uint32 uiCreature = 0;
uint8 uiSummonTimes = 0;
switch(uiGongWaves)
switch (uiGongWaves)
{
case 1:
uiCreature = CREATURE_TOMB_FIEND;
@@ -186,7 +186,7 @@ public:
uint32 GetData(uint32 uiType)
{
switch(uiType)
switch (uiType)
{
case DATA_GONG_WAVES:
return uiGongWaves;
@@ -197,7 +197,7 @@ public:
uint64 GetData64(uint32 uiType)
{
switch(uiType)
switch (uiType)
{
case DATA_GONG: return uiGongGUID;
}
@@ -69,7 +69,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case 21099: DoorWardGUID = go->GetGUID(); break;
}
@@ -78,7 +78,7 @@ public:
void Update(uint32 /*diff*/)
{
if (WardKeeperDeath == WARD_KEEPERS_NR)
if(GameObject* pGo = instance->GetGameObject(DoorWardGUID))
if (GameObject* pGo = instance->GetGameObject(DoorWardGUID))
{
pGo->SetUInt32Value(GAMEOBJECT_FLAGS, 33);
pGo->SetGoState(GO_STATE_ACTIVE);
@@ -87,7 +87,7 @@ public:
void SetData(uint32 type, uint32 /*data*/)
{
switch(type)
switch (type)
{
case EVENT_WARD_KEEPER: WardKeeperDeath++; break;
}
@@ -54,7 +54,7 @@ class boss_kurinnaxx : public CreatureScript
_Reset();
_enraged = false;
events.ScheduleEvent(EVENT_MORTAL_WOUND, 8000);
events.ScheduleEvent(EVENT_SANDTRAP, urand(5000,15000));
events.ScheduleEvent(EVENT_SANDTRAP, urand(5000, 15000));
events.ScheduleEvent(EVENT_TRASH, 1000);
events.ScheduleEvent(EVENT_WIDE_SLASH, 11000);
}
@@ -91,7 +91,7 @@ class boss_kurinnaxx : public CreatureScript
target->CastSpell(target, SPELL_SANDTRAP, true);
else if (Unit* victim = me->getVictim())
victim->CastSpell(victim, SPELL_SANDTRAP, true);
events.ScheduleEvent(EVENT_SANDTRAP, urand(5000,15000));
events.ScheduleEvent(EVENT_SANDTRAP, urand(5000, 15000));
break;
case EVENT_WIDE_SLASH:
DoCast(me, SPELL_WIDE_SLASH);
@@ -152,7 +152,7 @@ class boss_moam : public CreatureScript
for (std::list<Unit*>::iterator itr = targetList.begin(); itr != targetList.end(); ++itr)
DoCast(*itr, SPELL_DRAIN_MANA);
events.ScheduleEvent(EVENT_DRAIN_MANA, urand(5000,15000));
events.ScheduleEvent(EVENT_DRAIN_MANA, urand(5000, 15000));
break;
}/*
case EVENT_WIDE_SLASH:
@@ -592,7 +592,7 @@ public:
//Get random but only if we have more than one unit on threat list
if (temp.size() > 1)
advance (j , rand() % (temp.size() - 1));
advance (j, rand() % (temp.size() - 1));
return (*j);
}
@@ -916,7 +916,7 @@ public:
void DoAction(const int32 param)
{
switch(param)
switch (param)
{
case ACTION_FLESH_TENTACLE_KILLED:
++FleshTentaclesKilled;
@@ -145,7 +145,7 @@ public:
if (DoGetThreat(target))
DoModifyThreatPercent(target, -100);
switch(urand(0, 2))
switch (urand(0, 2))
{
case 0:
DoTeleportPlayer(target, -8106.0142f, 1289.2900f, -74.419533f, 5.112f);
@@ -91,7 +91,7 @@ public:
uint32 GetData(uint32 type)
{
switch(type)
switch (type)
{
case DATA_VEMISDEAD:
if (IsBossDied[0])
@@ -119,7 +119,7 @@ public:
uint64 GetData64 (uint32 identifier)
{
switch(identifier)
switch (identifier)
{
case DATA_SKERAM:
return SkeramGUID;
@@ -137,7 +137,7 @@ public:
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case DATA_VEM_DEATH:
IsBossDied[0] = true;
@@ -158,7 +158,7 @@ public:
void OnGameObjectCreate(GameObject* go)
{
switch(go->GetEntry())
switch (go->GetEntry())
{
case GO_END_DOOR:
EndDoorGUID = go->GetGUID();
@@ -168,7 +168,7 @@ public:
uint32 GetData(uint32 type)
{
switch(type)
switch (type)
{
case EVENT_PYRAMID:
return PyramidPhase;
@@ -178,7 +178,7 @@ public:
uint64 GetData64(uint32 data)
{
switch(data)
switch (data)
{
case ENTRY_ZUMRAH:
return ZumrahGUID;
@@ -200,7 +200,7 @@ public:
void SetData(uint32 type, uint32 data)
{
switch(type)
switch (type)
{
case EVENT_PYRAMID:
PyramidPhase=data;
@@ -322,7 +322,7 @@ public:
}
bool IsWaveAllDead(){
for(std::list<uint64>::iterator itr = addsAtBase.begin(); itr != addsAtBase.end(); ++itr)
for (std::list<uint64>::iterator itr = addsAtBase.begin(); itr != addsAtBase.end(); ++itr)
{
if (Creature* add = instance->GetCreature((*itr)))
{
@@ -330,7 +330,7 @@ public:
return false;
}
}
for(std::list<uint64>::iterator itr = movedadds.begin(); itr != movedadds.end(); ++itr)
for (std::list<uint64>::iterator itr = movedadds.begin(); itr != movedadds.end(); ++itr)
{
if (Creature* add = instance->GetCreature(((*itr))))
{
@@ -24,7 +24,7 @@ enum zfPyramidPhases
{
PYRAMID_NOT_STARTED, //default
PYRAMID_CAGES_OPEN, //happens in GO hello for cages
PYRAMID_ARRIVED_AT_STAIR , //happens in Weegli's movementinform
PYRAMID_ARRIVED_AT_STAIR, //happens in Weegli's movementinform
PYRAMID_WAVE_1,
PYRAMID_PRE_WAVE_2,
PYRAMID_WAVE_2,
+3 -3
View File
@@ -186,7 +186,7 @@ class npc_ruul_snowhoof : public CreatureScript
if (!player)
return;
switch(i)
switch (i)
{
case 0: {
me->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
@@ -319,7 +319,7 @@ class npc_muglash : public CreatureScript
{
Player* player = GetPlayerForEscort();
switch(i)
switch (i)
{
case 0:
if (player)
@@ -382,7 +382,7 @@ class npc_muglash : public CreatureScript
void DoWaveSummon()
{
switch(m_uiWaveId)
switch (m_uiWaveId)
{
case 1:
me->SummonCreature(NPC_WRATH_RIDER, m_afFirstNagaCoord[0][0], m_afFirstNagaCoord[0][1], m_afFirstNagaCoord[0][2], 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 60000);
@@ -376,7 +376,7 @@ public:
if (!player)
return;
switch(i)
switch (i)
{
case 0:
DoScriptText(SAY_START, me, player);
@@ -479,7 +479,7 @@ public:
{
Creature* Spark = Unit::GetCreature(*me, SparkGUID);
switch(Step)
switch (Step)
{
case 0:
if (Spark)
+1 -1
View File
@@ -238,7 +238,7 @@ public:
if (!player)
return;
switch(i)
switch (i)
{
case 0:
DoScriptText(SAY_REM_START, me, player);
@@ -299,7 +299,7 @@ public:
if (bYellTimer && uiYellTimer <= uiDiff)
{
switch(uiStep)
switch (uiStep)
{
case 0:
DoScriptText(RAND(SAY_QUEST2, SAY_QUEST3, SAY_QUEST4, SAY_QUEST5, SAY_QUEST6), me);
+2 -2
View File
@@ -146,9 +146,9 @@ public:
case 30:
DoScriptText(SAY_OOX_AMBUSH, me);
me->SummonCreature(NPC_WOODPAW_REAVER, -4425.14f, 2075.87f, 47.77f, 3.77f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
me->SummonCreature(NPC_WOODPAW_BRUTE , -4426.68f, 2077.98f, 47.57f, 3.77f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
me->SummonCreature(NPC_WOODPAW_BRUTE, -4426.68f, 2077.98f, 47.57f, 3.77f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
me->SummonCreature(NPC_WOODPAW_MYSTIC, -4428.33f, 2080.24f, 47.43f, 3.87f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
me->SummonCreature(NPC_WOODPAW_ALPHA , -4430.04f, 2075.54f, 46.83f, 3.81f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
me->SummonCreature(NPC_WOODPAW_ALPHA, -4430.04f, 2075.54f, 46.83f, 3.81f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
break;
case 37:
DoScriptText(SAY_OOX_END, me);
+12 -12
View File
@@ -57,7 +57,7 @@ public:
bool OnGossipSelect(Player* player, Creature* creature, uint32 /*uiSender*/, uint32 uiAction)
{
player->PlayerTalkClass->ClearMenus();
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF + 1:
player->CLOSE_GOSSIP_MENU();
@@ -172,7 +172,7 @@ public:
bool OnGossipSelect(Player* player, Creature* creature, uint32 /*uiSender*/, uint32 uiAction)
{
player->PlayerTalkClass->ClearMenus();
switch(uiAction)
switch (uiAction)
{
case GOSSIP_ACTION_INFO_DEF + 1:
player->CLOSE_GOSSIP_MENU();
@@ -348,7 +348,7 @@ public:
void EnterCombat(Unit* who)
{
uint32 rnd = rand()%2;
switch(rnd)
switch (rnd)
{
case 0: DoScriptText(CLINTAR_SPIRIT_SAY_UNDER_ATTACK_1, me, who); break;
case 1: DoScriptText(CLINTAR_SPIRIT_SAY_UNDER_ATTACK_2, me, who); break;
@@ -402,10 +402,10 @@ public:
return;
}
switch(CurrWP)
switch (CurrWP)
{
case 0:
switch(Step)
switch (Step)
{
case 0:
me->Say(CLINTAR_SPIRIT_SAY_START, 0, PlayerGUID);
@@ -418,7 +418,7 @@ public:
}
break;
case 6:
switch(Step)
switch (Step)
{
case 0:
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, 133);
@@ -433,7 +433,7 @@ public:
}
break;
case 15:
switch(Step)
switch (Step)
{
case 0:
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, 133);
@@ -447,7 +447,7 @@ public:
}
break;
case 16:
switch(Step)
switch (Step)
{
case 0:
DoScriptText(CLINTAR_SPIRIT_SAY_GET_TWO, me, player);
@@ -460,7 +460,7 @@ public:
}
break;
case 20:
switch(Step)
switch (Step)
{
case 0:
{
@@ -480,7 +480,7 @@ public:
}
break;
case 24:
switch(Step)
switch (Step)
{
case 0:
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, 133);
@@ -494,7 +494,7 @@ public:
}
break;
case 25:
switch(Step)
switch (Step)
{
case 0:
DoScriptText(CLINTAR_SPIRIT_SAY_GET_THREE, me, player);
@@ -507,7 +507,7 @@ public:
}
break;
case 40:
switch(Step)
switch (Step)
{
case 0:
me->SetUInt32Value(UNIT_NPC_EMOTESTATE, 2);
+1 -1
View File
@@ -157,7 +157,7 @@ public:
uiEventTimer = 5000;
++uiEventPhase;
switch(uiEventPhase)
switch (uiEventPhase)
{
case 1:
if (Unit* pUnit = Unit::GetUnit(*me, uiPlayerGUID))
+5 -5
View File
@@ -37,7 +37,7 @@ EndContentData */
###*/
#define GOSSIP_DEMITRIAN1 "What do you know of it?"
#define GOSSIP_DEMITRIAN2 "I am listening , Demitrian."
#define GOSSIP_DEMITRIAN2 "I am listening, Demitrian."
#define GOSSIP_DEMITRIAN3 "Continue, please."
#define GOSSIP_DEMITRIAN4 "A battle?"
#define GOSSIP_DEMITRIAN5 "<Nod>"
@@ -541,7 +541,7 @@ public:
switch (AnimationCount)
{
case 0:
DoScriptText(ANACHRONOS_SAY_1, me , Fandral);
DoScriptText(ANACHRONOS_SAY_1, me, Fandral);
break;
case 1:
Fandral->SetTarget(me->GetGUID());
@@ -762,7 +762,7 @@ public:
case 61:
me->GetMotionMaster()->MoveCharge(-8057.1f, 1470.32f, 2.61f, 6);
if (player->IsInRange(me, 0, 15))
player->GroupEventHappens(QUEST_A_PAWN_ON_THE_ETERNAL_BOARD , me);
player->GroupEventHappens(QUEST_A_PAWN_ON_THE_ETERNAL_BOARD, me);
break;
case 62:
me->SetDisplayId(15500);
@@ -1181,12 +1181,12 @@ enum WSCreatures
NPC_TEMPLAR_WATER = 15211,
NPC_TEMPLAR_AIR = 15212,
NPC_TEMPLAR_EARTH = 15307,
NPC_DUKE_FIRE = 15206,
NPC_DUKE_WATER = 15207,
NPC_DUKE_EARTH = 15208,
NPC_DUKE_AIR = 15220,
NPC_ROYAL_FIRE = 15203,
NPC_ROYAL_AIR = 15204,
NPC_ROYAL_EARTH = 15205,
@@ -121,7 +121,7 @@ public:
if (!player)
return;
switch(i)
switch (i)
{
case 16:
DoScriptText(SAY_AMBUSH, me);
+3 -3
View File
@@ -178,7 +178,7 @@ public:
if (!player)
return;
switch(i)
switch (i)
{
case 0: DoScriptText(WHISPER_CUSTODIAN_1, me, player); break;
case 1: DoScriptText(WHISPER_CUSTODIAN_2, me, player); break;
@@ -435,7 +435,7 @@ public:
if (!player)
return;
switch(i) {
switch (i) {
case 23:
me->SummonCreature(SPAWN_FIRST, -8350.96f, -4445.79f, 10.10f, 6.20f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
me->SummonCreature(SPAWN_FIRST, -8355.96f, -4447.79f, 10.10f, 6.27f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 25000);
@@ -591,7 +591,7 @@ public:
return;
}
switch(m_uiPhasePostEvent)
switch (m_uiPhasePostEvent)
{
case 1:
DoScriptText(SAY_TOOG_POST_1, me);
+4 -4
View File
@@ -134,7 +134,7 @@ public:
if (!player)
return;
switch(uiPointId)
switch (uiPointId)
{
case 16:
DoScriptText(SAY_GIL_AT_LAST, me, player);
@@ -597,7 +597,7 @@ public:
if (!player)
return;
switch(uiPointId)
switch (uiPointId)
{
case 0:
DoScriptText(SAY_STARTUP1, me);
@@ -625,7 +625,7 @@ public:
if (!player)
return;
switch(uiPointId)
switch (uiPointId)
{
case 9:
DoScriptText(SAY_STARTUP2, me, player);
@@ -654,7 +654,7 @@ public:
{
if (m_uiPostEventTimer <= uiDiff)
{
switch(m_uiPostEventCount)
switch (m_uiPostEventCount)
{
case 0:
DoScriptText(SAY_PROGRESS_2, me);

Some files were not shown because too many files have changed in this diff Show More