diff options
Diffstat (limited to 'src/game/Unit.cpp')
-rw-r--r-- | src/game/Unit.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 709ec8619db..3e75a6409f0 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -91,7 +91,7 @@ static bool isNonTriggerAura[TOTAL_AURAS]; static bool procPrepared = InitTriggerAuraData(); Unit::Unit() -: WorldObject(), i_motionMaster(this), m_ThreatManager(this), m_HostilRefManager(this) +: WorldObject(), i_motionMaster(this), m_ThreatManager(this), m_HostileRefManager(this) , IsAIEnabled(false), NeedChangeAI(false) , i_AI(NULL), i_disabledAI(NULL), m_removedAurasCount(0), m_vehicle(NULL), m_transport(NULL) , m_ControlledByPlayer(false), m_procDeep(0), m_unitTypeMask(UNIT_MASK_NONE), m_vehicleKit(NULL) @@ -246,7 +246,7 @@ void Unit::Update(uint32 p_time) // Check UNIT_STAT_MELEE_ATTACKING or UNIT_STAT_CHASE (without UNIT_STAT_FOLLOW in this case) so pets can reach far away // targets without stopping half way there and running off. // These flags are reset after target dies or another command is given. - if (m_HostilRefManager.isEmpty()) + if (m_HostileRefManager.isEmpty()) { // m_CombatTimer set at aura start and it will be freeze until aura removing if (m_CombatTimer <= p_time) @@ -11984,7 +11984,7 @@ void Unit::setDeathState(DeathState s) { CombatStop(); DeleteThreatList(); - getHostilRefManager().deleteReferences(); + getHostileRefManager().deleteReferences(); ClearComboPointHolders(); // any combo points pointed to unit lost at it death if (IsNonMeleeSpellCasted(false)) @@ -13108,7 +13108,7 @@ void Unit::CleanupsBeforeDelete(bool finalCleanup) CombatStop(); ClearComboPointHolders(); DeleteThreatList(); - getHostilRefManager().setOnlineOfflineState(false); + getHostileRefManager().setOnlineOfflineState(false); GetMotionMaster()->Clear(false); // remove different non-standard movement generators. } @@ -15075,7 +15075,7 @@ void Unit::RemoveCharmedBy(Unit *charmer) CastStop(); CombatStop(); //TODO: CombatStop(true) may cause crash (interrupt spells) - getHostilRefManager().deleteReferences(); + getHostileRefManager().deleteReferences(); DeleteThreatList(); RestoreFaction(); GetMotionMaster()->InitDefault(); @@ -16103,8 +16103,8 @@ void Unit::SendThreatListUpdate() WorldPacket data(SMSG_THREAT_UPDATE, 8 + count * 8); data.append(GetPackGUID()); data << uint32(count); - std::list<HostilReference*>& tlist = getThreatManager().getThreatList(); - for (std::list<HostilReference*>::const_iterator itr = tlist.begin(); itr != tlist.end(); ++itr) + std::list<HostileReference*>& tlist = getThreatManager().getThreatList(); + for (std::list<HostileReference*>::const_iterator itr = tlist.begin(); itr != tlist.end(); ++itr) { data.appendPackGUID((*itr)->getUnitGuid()); data << uint32((*itr)->getThreat()); @@ -16113,17 +16113,17 @@ void Unit::SendThreatListUpdate() } } -void Unit::SendChangeCurrentVictimOpcode(HostilReference* pHostilReference) +void Unit::SendChangeCurrentVictimOpcode(HostileReference* pHostileReference) { if (uint32 count = getThreatManager().getThreatList().size()) { sLog.outDebug( "WORLD: Send SMSG_HIGHEST_THREAT_UPDATE Message" ); WorldPacket data(SMSG_HIGHEST_THREAT_UPDATE, 8 + 8 + count * 8); data.append(GetPackGUID()); - data.appendPackGUID(pHostilReference->getUnitGuid()); + data.appendPackGUID(pHostileReference->getUnitGuid()); data << uint32(count); - std::list<HostilReference*>& tlist = getThreatManager().getThreatList(); - for (std::list<HostilReference*>::const_iterator itr = tlist.begin(); itr != tlist.end(); ++itr) + std::list<HostileReference*>& tlist = getThreatManager().getThreatList(); + for (std::list<HostileReference*>::const_iterator itr = tlist.begin(); itr != tlist.end(); ++itr) { data.appendPackGUID((*itr)->getUnitGuid()); data << uint32((*itr)->getThreat()); @@ -16140,12 +16140,12 @@ void Unit::SendClearThreatListOpcode() SendMessageToSet(&data, false); } -void Unit::SendRemoveFromThreatListOpcode(HostilReference* pHostilReference) +void Unit::SendRemoveFromThreatListOpcode(HostileReference* pHostileReference) { sLog.outDebug( "WORLD: Send SMSG_THREAT_REMOVE Message" ); WorldPacket data(SMSG_THREAT_REMOVE, 8 + 8); data.append(GetPackGUID()); - data.appendPackGUID(pHostilReference->getUnitGuid()); + data.appendPackGUID(pHostileReference->getUnitGuid()); SendMessageToSet(&data, false); } @@ -16208,7 +16208,7 @@ void Unit::StopAttackFaction(uint32 faction_id) ++itr; } - getHostilRefManager().deleteReferencesForFaction(faction_id); + getHostileRefManager().deleteReferencesForFaction(faction_id); for(ControlList::const_iterator itr = m_Controlled.begin(); itr != m_Controlled.end(); ++itr) (*itr)->StopAttackFaction(faction_id); |