aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sql/updates/world/3.3.5/2018_01_10_04_world_335.sql1
-rw-r--r--src/server/game/Combat/ThreatManager.cpp8
-rw-r--r--src/server/game/Combat/ThreatManager.h4
-rw-r--r--src/server/game/Entities/Creature/Creature.cpp6
-rw-r--r--src/server/game/Entities/Player/Player.cpp2
-rw-r--r--src/server/game/Entities/Unit/Unit.cpp4
-rw-r--r--src/server/game/Entities/Unit/Unit.h2
-rw-r--r--src/server/scripts/Commands/cs_debug.cpp2
-rw-r--r--src/server/scripts/Kalimdor/boss_azuregos.cpp2
9 files changed, 15 insertions, 16 deletions
diff --git a/sql/updates/world/3.3.5/2018_01_10_04_world_335.sql b/sql/updates/world/3.3.5/2018_01_10_04_world_335.sql
index 958d818209b..8d2f05abf7f 100644
--- a/sql/updates/world/3.3.5/2018_01_10_04_world_335.sql
+++ b/sql/updates/world/3.3.5/2018_01_10_04_world_335.sql
@@ -124,4 +124,3 @@ INSERT INTO `waypoint_data` (`id`, `point`, `position_x`, `position_y`, `positio
(854780,31,-312.576,-2859.04,80.4389,0,0,0,0,100,0),
(854780,32,-320.584,-2852.24,78.3489,0,0,0,0,100,0),
(854780,33,-336.88,-2851.17,77.2118,0,0,0,0,100,0);
- \ No newline at end of file
diff --git a/src/server/game/Combat/ThreatManager.cpp b/src/server/game/Combat/ThreatManager.cpp
index c7e36557b30..ffc1e1cbe31 100644
--- a/src/server/game/Combat/ThreatManager.cpp
+++ b/src/server/game/Combat/ThreatManager.cpp
@@ -115,7 +115,7 @@ void ThreatReference::UpdateTauntState(bool victimIsTaunting)
HeapNotifyIncreased();
return;
}
-
+
// Check for SPELL_AURA_MOD_DETAUNT (applied from owner to victim)
for (AuraEffect const* eff : _victim->GetAuraEffectsByType(SPELL_AURA_MOD_DETAUNT))
if (eff->GetCasterGUID() == _owner->GetGUID())
@@ -334,7 +334,7 @@ void ThreatManager::AddThreat(Unit* target, float amount, SpellInfo const* spell
{
float const origAmount = amount;
// intentional iteration by index - there's a nested AddThreat call further down that might cause AI calls which might modify redirect info through spells
- for (size_t i=0; i<redirInfo.size(); ++i)
+ for (size_t i = 0; i < redirInfo.size(); ++i)
{
auto const pair = redirInfo[i]; // (victim,pct)
Unit* redirTarget = nullptr;
@@ -366,7 +366,7 @@ void ThreatManager::AddThreat(Unit* target, float amount, SpellInfo const* spell
// otherwise, ensure we're in combat (threat implies combat!)
if (!_owner->GetCombatManager().SetInCombatWith(target)) // if this returns false, we're not actually in combat, and thus cannot have threat!
return; // typical causes: bad scripts trying to add threat to GMs, dead targets etc
-
+
// ok, we're now in combat - create the threat list reference and push it to the respective managers
ThreatReference* ref = new ThreatReference(this, target, amount);
PutThreatListRef(target->GetGUID(), ref);
@@ -710,7 +710,7 @@ void ThreatManager::PurgeThreatListRef(ObjectGuid const& guid, bool sendRemove)
if (_currentVictimRef == ref)
_currentVictimRef = nullptr;
-
+
_sortedThreatList.erase(ref->_handle);
if (sendRemove && ref->IsOnline())
SendRemoveToClients(ref->_victim);
diff --git a/src/server/game/Combat/ThreatManager.h b/src/server/game/Combat/ThreatManager.h
index 0bfba38e7c6..d17120392d1 100644
--- a/src/server/game/Combat/ThreatManager.h
+++ b/src/server/game/Combat/ThreatManager.h
@@ -14,7 +14,7 @@
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-
+
#ifndef TRINITY_THREATMANAGER_H
#define TRINITY_THREATMANAGER_H
@@ -274,5 +274,5 @@ class TC_GAME_API ThreatReference
};
inline bool CompareThreatLessThan::operator()(ThreatReference const* a, ThreatReference const* b) const { return ThreatManager::CompareReferencesLT(a, b, 1.0f); }
-
+
#endif
diff --git a/src/server/game/Entities/Creature/Creature.cpp b/src/server/game/Entities/Creature/Creature.cpp
index dd41cf1d681..b64b0cf89f5 100644
--- a/src/server/game/Entities/Creature/Creature.cpp
+++ b/src/server/game/Entities/Creature/Creature.cpp
@@ -723,7 +723,7 @@ void Creature::Update(uint32 diff)
if (m_shouldReacquireTarget && !IsFocusing(nullptr, true))
{
SetTarget(m_suppressedTarget);
-
+
if (!HasFlag(UNIT_FIELD_FLAGS_2, UNIT_FLAG2_DISABLE_TURN))
{
if (m_suppressedTarget)
@@ -1805,7 +1805,7 @@ void Creature::DeleteFromDB()
stmt->setUInt32(0, m_spawnId);
stmt->setUInt32(1, LINKED_RESPAWN_CREATURE_TO_GO);
trans->Append(stmt);
-
+
stmt = WorldDatabase.GetPreparedStatement(WORLD_DEL_LINKED_RESPAWN_MASTER);
stmt->setUInt32(0, m_spawnId);
stmt->setUInt32(1, LINKED_RESPAWN_CREATURE_TO_CREATURE);
@@ -3127,7 +3127,7 @@ void Creature::FocusTarget(Spell const* focusSpell, WorldObject const* target)
}
bool const noTurnDuringCast = spellInfo->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST);
-
+
if (!HasFlag(UNIT_FIELD_FLAGS_2, UNIT_FLAG2_DISABLE_TURN))
{
// Face the target - we need to do this before the unit state is modified for no-turn spells
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp
index 14ed5e04bec..862f36b8dfc 100644
--- a/src/server/game/Entities/Player/Player.cpp
+++ b/src/server/game/Entities/Player/Player.cpp
@@ -13680,7 +13680,7 @@ void Player::ApplyEnchantment(Item* item, EnchantmentSlot slot, bool apply, bool
}
}
}
-
+
CastSpellExtraArgs args(item);
// Cast custom spell vs all equal basepoints got from enchant_amount
if (basepoints)
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp
index 86df2a6d13d..811be1e2076 100644
--- a/src/server/game/Entities/Unit/Unit.cpp
+++ b/src/server/game/Entities/Unit/Unit.cpp
@@ -8550,7 +8550,7 @@ void Unit::AttackedTarget(Unit* target, bool canInitialAggro)
target->EngageWithTarget(this);
if (Unit* targetOwner = target->GetCharmerOrOwner())
targetOwner->EngageWithTarget(this);
-
+
Player* myPlayerOwner = GetCharmerOrOwnerPlayerOrPlayerItself();
Player* targetPlayerOwner = target->GetCharmerOrOwnerPlayerOrPlayerItself();
if (myPlayerOwner && targetPlayerOwner && !(myPlayerOwner->duel && myPlayerOwner->duel->opponent == targetPlayerOwner))
@@ -12401,7 +12401,7 @@ void Unit::RemoveCharmedBy(Unit* charmer)
}
player->SetClientControl(this, true);
}
-
+
EngageWithTarget(charmer);
// a guardian should always have charminfo
diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h
index 8b8c975597d..6adf01b367c 100644
--- a/src/server/game/Entities/Unit/Unit.h
+++ b/src/server/game/Entities/Unit/Unit.h
@@ -1020,7 +1020,7 @@ class TC_GAME_API Unit : public WorldObject
CombatManager& GetCombatManager() { return m_combatManager; }
CombatManager const& GetCombatManager() const { return m_combatManager; }
void AttackedTarget(Unit* target, bool canInitialAggro);
-
+
bool IsImmuneToAll() const { return IsImmuneToPC() && IsImmuneToNPC(); }
void SetImmuneToAll(bool apply, bool keepCombat);
virtual void SetImmuneToAll(bool apply) { SetImmuneToAll(apply, false); }
diff --git a/src/server/scripts/Commands/cs_debug.cpp b/src/server/scripts/Commands/cs_debug.cpp
index 20b75db890c..f4f6e713593 100644
--- a/src/server/scripts/Commands/cs_debug.cpp
+++ b/src/server/scripts/Commands/cs_debug.cpp
@@ -848,7 +848,7 @@ public:
Unit* target = handler->getSelectedUnit();
if (!target)
target = handler->GetSession()->GetPlayer();
-
+
ThreatManager& mgr = target->GetThreatManager();
if (!target->IsAlive())
{
diff --git a/src/server/scripts/Kalimdor/boss_azuregos.cpp b/src/server/scripts/Kalimdor/boss_azuregos.cpp
index e4e12a765ca..ef22f8451dd 100644
--- a/src/server/scripts/Kalimdor/boss_azuregos.cpp
+++ b/src/server/scripts/Kalimdor/boss_azuregos.cpp
@@ -121,7 +121,7 @@ class boss_azuregos : public CreatureScript
for (auto const& pair : me->GetCombatManager().GetPvECombatRefs())
if (Player* player = pair.second->GetOther(me)->ToPlayer())
DoTeleportPlayer(player, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ()+3, player->GetOrientation());
-
+
ResetThreatList();
events.ScheduleEvent(EVENT_TELEPORT, 30000);
break;