diff options
| author | ariel- <ariel-@users.noreply.github.com> | 2017-06-19 23:20:06 -0300 |
|---|---|---|
| committer | ariel- <ariel-@users.noreply.github.com> | 2017-06-19 23:20:06 -0300 |
| commit | 85a7d5ce9ac68b30da2277cc91d4b70358f1880d (patch) | |
| tree | df3d2084ee2e35008903c03178039b9c986e2d08 /src/server/scripts/EasternKingdoms/ScarletEnclave | |
| parent | 052fc24315ace866ea1cf610e85df119b68100c9 (diff) | |
Core: ported headers cleanup from master branch
Diffstat (limited to 'src/server/scripts/EasternKingdoms/ScarletEnclave')
4 files changed, 40 insertions, 28 deletions
diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp index c384419db06..630e362957b 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp @@ -16,18 +16,21 @@ */ #include "ScriptMgr.h" -#include "ScriptedCreature.h" -#include "ScriptedGossip.h" -#include "Vehicle.h" -#include "ObjectMgr.h" -#include "ScriptedEscortAI.h" #include "CombatAI.h" -#include "PassiveAI.h" +#include "CreatureTextMgr.h" +#include "GameObject.h" #include "GameObjectAI.h" +#include "Log.h" +#include "MotionMaster.h" +#include "MoveSplineInit.h" +#include "ObjectAccessor.h" +#include "ObjectMgr.h" +#include "PassiveAI.h" #include "Player.h" +#include "ScriptedEscortAI.h" +#include "ScriptedGossip.h" #include "SpellInfo.h" -#include "CreatureTextMgr.h" -#include "MoveSplineInit.h" +#include "Vehicle.h" /*###### ##Quest 12848 @@ -191,7 +194,7 @@ public: TC_LOG_ERROR("scripts", "npc_unworthy_initiateAI: unable to find anchor!"); float dist = 99.0f; - GameObject* prison = NULL; + GameObject* prison = nullptr; for (uint8 i = 0; i < 12; ++i) { @@ -512,7 +515,7 @@ public: me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_UNK_15); } - void SpellHit(Unit* pCaster, const SpellInfo* pSpell) override + void SpellHit(Unit* pCaster, SpellInfo const* pSpell) override { if (!m_bIsDuelInProgress && pSpell->Id == SPELL_DUEL) { @@ -767,7 +770,7 @@ public: return false; } - void SpellHit(Unit* caster, const SpellInfo* spell) override + void SpellHit(Unit* caster, SpellInfo const* spell) override { if (spell->Id == SPELL_DELIVER_STOLEN_HORSE) { @@ -1068,7 +1071,7 @@ class npc_scarlet_miner_cart : public CreatureScript if (apply) { _playerGUID = who->GetGUID(); - me->CastSpell((Unit*)NULL, SPELL_SUMMON_MINER, true); + me->CastSpell((Unit*)nullptr, SPELL_SUMMON_MINER, true); } else { diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp index 8ee7049398e..2378d8ddad2 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp @@ -16,11 +16,13 @@ */ #include "ScriptMgr.h" -#include "ScriptedCreature.h" -#include "ScriptedEscortAI.h" +#include "CreatureTextMgr.h" +#include "GameObject.h" +#include "MotionMaster.h" +#include "ObjectAccessor.h" #include "Player.h" +#include "ScriptedEscortAI.h" #include "SpellInfo.h" -#include "CreatureTextMgr.h" //How to win friends and influence enemies // texts signed for creature 28939 but used for 28939, 28940, 28610 @@ -74,7 +76,7 @@ public: me->RestoreFaction(); } - void SpellHit(Unit* caster, const SpellInfo* spell) override + void SpellHit(Unit* caster, SpellInfo const* spell) override { if (spell->Id == SPELL_PERSUASIVE_STRIKE && caster->GetTypeId() == TYPEID_PLAYER && me->IsAlive() && !speechCounter) { @@ -91,7 +93,7 @@ public: me->SetReactState(REACT_PASSIVE); DoCastAOE(SPELL_THREAT_PULSE, true); - sCreatureTextMgr->SendChat(me, SAY_PERSUADE_RAND, NULL, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_NORMAL, 0, TEAM_OTHER, false, player); + sCreatureTextMgr->SendChat(me, SAY_PERSUADE_RAND, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_NORMAL, 0, TEAM_OTHER, false, player); Talk(SAY_CRUSADER); } } @@ -134,7 +136,7 @@ public: break; case 5: - sCreatureTextMgr->SendChat(me, SAY_PERSUADED5, NULL, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_NORMAL, 0, TEAM_OTHER, false, player); + sCreatureTextMgr->SendChat(me, SAY_PERSUADED5, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_NORMAL, 0, TEAM_OTHER, false, player); speechTimer = 8000; break; diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp index 319ac6b8ad3..bc950388ec7 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp @@ -16,10 +16,14 @@ */ #include "ScriptMgr.h" -#include "ScriptedCreature.h" -#include "ScriptedGossip.h" -#include "ScriptedEscortAI.h" +#include "GameObject.h" +#include "Map.h" +#include "MotionMaster.h" +#include "ObjectAccessor.h" #include "Player.h" +#include "ScriptedEscortAI.h" +#include "ScriptedGossip.h" +#include "TemporarySummon.h" #define LESS_MOB // if you do not have a good server and do not want it to be laggy as hell //Light of Dawn @@ -1084,7 +1088,7 @@ public: case 48: // Show the cleansing effect (dawn of light) //if (GameObject* go = me->GetMap()->GetGameObject(uiDawnofLightGUID)) // go->SetPhaseMask(128, true); - me->SummonGameObject(GO_LIGHT_OF_DAWN, 2283.896f, -5287.914f, 83.066f, 0.f, G3D::Quat(), 30); + me->SummonGameObject(GO_LIGHT_OF_DAWN, 2283.896f, -5287.914f, 83.066f, 0.f, QuaternionData(), 30); if (Creature* temp = ObjectAccessor::GetCreature(*me, uiTirionGUID)) { if (temp->HasAura(SPELL_REBIRTH_OF_THE_ASHBRINGER)) @@ -1262,7 +1266,7 @@ public: // go->SetPhaseMask(0, true); { // search players with in 50 yards for quest credit - Map::PlayerList const &PlayerList = me->GetMap()->GetPlayers(); + Map::PlayerList const& PlayerList = me->GetMap()->GetPlayers(); if (!PlayerList.isEmpty()) { for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) @@ -1494,7 +1498,7 @@ public: void SpawnNPC() { - Unit* temp = NULL; + Unit* temp = nullptr; // Death for (uint8 i = 0; i < ENCOUNTER_GHOUL_NUMBER; ++i) diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp index 6eb25dbd8f0..2adfea2f577 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp @@ -16,9 +16,11 @@ */ #include "ScriptMgr.h" -#include "ScriptedCreature.h" +#include "MotionMaster.h" #include "PassiveAI.h" #include "Player.h" +#include "ScriptedCreature.h" +#include "TemporarySummon.h" /*#### ## npc_valkyr_battle_maiden @@ -83,7 +85,7 @@ public: { if (FlyBackTimer <= diff) { - Player* player = NULL; + Player* player = nullptr; if (me->IsSummon()) if (Unit* summoner = me->ToTempSummon()->GetSummoner()) player = summoner->ToPlayer(); @@ -129,10 +131,11 @@ public: break; } ++phase; - } else FlyBackTimer-=diff; + } + else + FlyBackTimer -= diff; } }; - }; void AddSC_the_scarlet_enclave() |
