summaryrefslogtreecommitdiff
path: root/src/server/game/Instances/InstanceScript.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/game/Instances/InstanceScript.cpp')
-rw-r--r--src/server/game/Instances/InstanceScript.cpp20
1 files changed, 11 insertions, 9 deletions
diff --git a/src/server/game/Instances/InstanceScript.cpp b/src/server/game/Instances/InstanceScript.cpp
index bc02489706..8d160bf2f6 100644
--- a/src/server/game/Instances/InstanceScript.cpp
+++ b/src/server/game/Instances/InstanceScript.cpp
@@ -42,7 +42,8 @@ void InstanceScript::HandleGameObject(uint64 GUID, bool open, GameObject* go)
go = instance->GetGameObject(GUID);
if (go)
go->SetGoState(open ? GO_STATE_ACTIVE : GO_STATE_READY);
- else {
+ else
+ {
#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS)
sLog->outDebug(LOG_FILTER_TSCR, "TSCR: InstanceScript: HandleGameObject failed");
#endif
@@ -230,7 +231,7 @@ bool InstanceScript::SetBossState(uint32 id, EncounterState state)
return false;
}
-std::string InstanceScript::LoadBossState(const char * data)
+std::string InstanceScript::LoadBossState(const char* data)
{
if (!data)
return nullptr;
@@ -281,7 +282,7 @@ void InstanceScript::DoRespawnGameObject(uint64 uiGuid, uint32 uiTimeToDespawn)
{
//not expect any of these should ever be handled
if (go->GetGoType() == GAMEOBJECT_TYPE_FISHINGNODE || go->GetGoType() == GAMEOBJECT_TYPE_DOOR ||
- go->GetGoType() == GAMEOBJECT_TYPE_BUTTON || go->GetGoType() == GAMEOBJECT_TYPE_TRAP)
+ go->GetGoType() == GAMEOBJECT_TYPE_BUTTON || go->GetGoType() == GAMEOBJECT_TYPE_TRAP)
return;
if (go->isSpawned())
@@ -301,7 +302,8 @@ void InstanceScript::DoUpdateWorldState(uint32 uiStateId, uint32 uiStateData)
if (Player* player = itr->GetSource())
player->SendUpdateWorldState(uiStateId, uiStateData);
}
- else {
+ else
+ {
#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS)
sLog->outDebug(LOG_FILTER_TSCR, "TSCR: DoUpdateWorldState attempt send data but no players in map.");
#endif
@@ -329,7 +331,7 @@ void InstanceScript::DoSendNotifyToInstance(char const* format, ...)
// Update Achievement Criteria for all players in instance
void InstanceScript::DoUpdateAchievementCriteria(AchievementCriteriaTypes type, uint32 miscValue1 /*= 0*/, uint32 miscValue2 /*= 0*/, Unit* unit /*= NULL*/)
{
- Map::PlayerList const &PlayerList = instance->GetPlayers();
+ Map::PlayerList const& PlayerList = instance->GetPlayers();
if (!PlayerList.isEmpty())
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
@@ -340,7 +342,7 @@ void InstanceScript::DoUpdateAchievementCriteria(AchievementCriteriaTypes type,
// Start timed achievement for all players in instance
void InstanceScript::DoStartTimedAchievement(AchievementCriteriaTimedTypes type, uint32 entry)
{
- Map::PlayerList const &PlayerList = instance->GetPlayers();
+ Map::PlayerList const& PlayerList = instance->GetPlayers();
if (!PlayerList.isEmpty())
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
@@ -351,7 +353,7 @@ void InstanceScript::DoStartTimedAchievement(AchievementCriteriaTimedTypes type,
// Stop timed achievement for all players in instance
void InstanceScript::DoStopTimedAchievement(AchievementCriteriaTimedTypes type, uint32 entry)
{
- Map::PlayerList const &PlayerList = instance->GetPlayers();
+ Map::PlayerList const& PlayerList = instance->GetPlayers();
if (!PlayerList.isEmpty())
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
@@ -380,7 +382,7 @@ void InstanceScript::DoRemoveAurasDueToSpellOnPlayers(uint32 spell)
// Cast spell on all players in instance
void InstanceScript::DoCastSpellOnPlayers(uint32 spell)
{
- Map::PlayerList const &PlayerList = instance->GetPlayers();
+ Map::PlayerList const& PlayerList = instance->GetPlayers();
if (!PlayerList.isEmpty())
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
@@ -391,7 +393,7 @@ void InstanceScript::DoCastSpellOnPlayers(uint32 spell)
bool InstanceScript::CheckAchievementCriteriaMeet(uint32 criteria_id, Player const* /*source*/, Unit const* /*target*/ /*= NULL*/, uint32 /*miscvalue1*/ /*= 0*/)
{
sLog->outError("Achievement system call InstanceScript::CheckAchievementCriteriaMeet but instance script for map %u not have implementation for achievement criteria %u",
- instance->GetId(), criteria_id);
+ instance->GetId(), criteria_id);
return false;
}