refactor(Core): NULL -> nullptr (#3275)
* NULL to nullptr * NULL to nullptr * NULL to nullptr * NULL to nullptr * NULL to nullptr Co-authored-by: Francesco Borzì <borzifrancesco@gmail.com> Co-authored-by: Stefano Borzì <stefanoborzi32@gmail.com>
This commit is contained in:
@@ -347,7 +347,7 @@ void PetAI::UpdateAI(uint32 diff)
|
||||
void PetAI::UpdateAllies()
|
||||
{
|
||||
Unit* owner = me->GetCharmerOrOwner();
|
||||
Group* group = NULL;
|
||||
Group* group = nullptr;
|
||||
|
||||
m_updateAlliesTimer = 10*IN_MILLISECONDS; //update friendly targets every 10 seconds, lesser checks increase performance
|
||||
|
||||
@@ -367,7 +367,7 @@ void PetAI::UpdateAllies()
|
||||
m_AllySet.insert(me->GetGUID());
|
||||
if (group) //add group
|
||||
{
|
||||
for (GroupReference* itr = group->GetFirstMember(); itr != NULL; itr = itr->next())
|
||||
for (GroupReference* itr = group->GetFirstMember(); itr != nullptr; itr = itr->next())
|
||||
{
|
||||
Player* Target = itr->GetSource();
|
||||
if (!Target || !Target->IsInMap(owner) || !group->SameSubGroup(owner->ToPlayer(), Target))
|
||||
@@ -470,7 +470,7 @@ Unit* PetAI::SelectNextTarget(bool allowAutoSelect) const
|
||||
|
||||
// Passive pets don't do next target selection
|
||||
if (me->HasReactState(REACT_PASSIVE))
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
// Check pet attackers first so we don't drag a bunch of targets to the owner
|
||||
if (Unit* myAttacker = me->getAttackerForHelper())
|
||||
@@ -491,7 +491,7 @@ Unit* PetAI::SelectNextTarget(bool allowAutoSelect) const
|
||||
// Not sure why we wouldn't have an owner but just in case...
|
||||
Unit* owner = me->GetCharmerOrOwner();
|
||||
if (!owner)
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
// Check owner attackers
|
||||
if (Unit* ownerAttacker = owner->getAttackerForHelper())
|
||||
@@ -513,7 +513,7 @@ Unit* PetAI::SelectNextTarget(bool allowAutoSelect) const
|
||||
return nearTarget;
|
||||
|
||||
// Default - no valid targets
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void PetAI::HandleReturnMovement()
|
||||
@@ -703,7 +703,7 @@ bool PetAI::CanAttack(Unit* target, const SpellInfo* spellInfo)
|
||||
if (me->GetVictim() && me->GetVictim() != target)
|
||||
{
|
||||
// Check if our owner selected this target and clicked "attack"
|
||||
Unit* ownerTarget = NULL;
|
||||
Unit* ownerTarget = nullptr;
|
||||
if (Player* owner = me->GetCharmerOrOwner()->ToPlayer())
|
||||
ownerTarget = owner->GetSelectedUnit();
|
||||
else
|
||||
|
||||
@@ -74,7 +74,7 @@ class PetAI : public CreatureAI
|
||||
Unit* SelectNextTarget(bool allowAutoSelect) const;
|
||||
void HandleReturnMovement();
|
||||
void DoAttack(Unit* target, bool chase);
|
||||
bool CanAttack(Unit* target, const SpellInfo* spellInfo = NULL);
|
||||
bool CanAttack(Unit* target, const SpellInfo* spellInfo = nullptr);
|
||||
void ClearCharmInfoFlags();
|
||||
};
|
||||
#endif
|
||||
|
||||
@@ -64,14 +64,14 @@ void TotemAI::UpdateAI(uint32 /*diff*/)
|
||||
// SPELLMOD_RANGE not applied in this place just because not existence range mods for attacking totems
|
||||
|
||||
// pointer to appropriate target if found any
|
||||
Unit* victim = i_victimGuid ? ObjectAccessor::GetUnit(*me, i_victimGuid) : NULL;
|
||||
Unit* victim = i_victimGuid ? ObjectAccessor::GetUnit(*me, i_victimGuid) : nullptr;
|
||||
|
||||
// Search victim if no, not attackable, or out of range, or friendly (possible in case duel end)
|
||||
if (!victim ||
|
||||
!victim->isTargetableForAttack(true, me) || !me->IsWithinDistInMap(victim, max_range) ||
|
||||
me->IsFriendlyTo(victim) || !me->CanSeeOrDetect(victim))
|
||||
{
|
||||
victim = NULL;
|
||||
victim = nullptr;
|
||||
acore::NearestAttackableUnitInObjectRangeCheck u_check(me, me, max_range);
|
||||
acore::UnitLastSearcher<acore::NearestAttackableUnitInObjectRangeCheck> checker(me, victim, u_check);
|
||||
me->VisitNearbyObject(max_range, checker);
|
||||
|
||||
@@ -125,7 +125,7 @@ void UnitAI::DoCastToAllHostilePlayers(uint32 spellid, bool triggered)
|
||||
|
||||
void UnitAI::DoCast(uint32 spellId)
|
||||
{
|
||||
Unit* target = NULL;
|
||||
Unit* target = nullptr;
|
||||
//sLog->outError("aggre %u %u", spellId, (uint32)AISpellInfo[spellId].target);
|
||||
switch (AISpellInfo[spellId].target)
|
||||
{
|
||||
|
||||
@@ -196,7 +196,7 @@ class UnitAI
|
||||
{
|
||||
ThreatContainer::StorageType const& threatlist = me->getThreatManager().getThreatList();
|
||||
if (position >= threatlist.size())
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
std::list<Unit*> targetList;
|
||||
for (ThreatContainer::StorageType::const_iterator itr = threatlist.begin(); itr != threatlist.end(); ++itr)
|
||||
@@ -204,7 +204,7 @@ class UnitAI
|
||||
targetList.push_back((*itr)->getTarget());
|
||||
|
||||
if (position >= targetList.size())
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
if (targetType == SELECT_TARGET_NEAREST || targetType == SELECT_TARGET_FARTHEST)
|
||||
targetList.sort(acore::ObjectDistanceOrderPred(me));
|
||||
@@ -235,7 +235,7 @@ class UnitAI
|
||||
break;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void SelectTargetList(std::list<Unit*>& targetList, uint32 num, SelectAggroTarget targetType, float dist = 0.0f, bool playerOnly = false, int32 aura = 0);
|
||||
|
||||
@@ -246,7 +246,7 @@ bool CreatureAI::_EnterEvadeMode()
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(true);
|
||||
me->LoadCreaturesAddon(true);
|
||||
me->SetLootRecipient(NULL);
|
||||
me->SetLootRecipient(nullptr);
|
||||
me->ResetPlayerDamageReq();
|
||||
me->SetLastDamagedTime(0);
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@ class CreatureAI : public UnitAI
|
||||
Creature* DoSummonFlyer(uint32 entry, WorldObject* obj, float flightZ, float radius = 5.0f, uint32 despawnTime = 30000, TempSummonType summonType = TEMPSUMMON_CORPSE_TIMED_DESPAWN);
|
||||
|
||||
public:
|
||||
void Talk(uint8 id, WorldObject const* whisperTarget = NULL);
|
||||
void Talk(uint8 id, WorldObject const* whisperTarget = nullptr);
|
||||
explicit CreatureAI(Creature* creature) : UnitAI(creature), me(creature), m_MoveInLineOfSight_locked(false) {}
|
||||
|
||||
virtual ~CreatureAI() {}
|
||||
@@ -85,7 +85,7 @@ class CreatureAI : public UnitAI
|
||||
// Called for reaction at stopping attack at no attackers or targets
|
||||
virtual void EnterEvadeMode();
|
||||
|
||||
// Called for reaction at enter to combat if not in combat yet (enemy can be NULL)
|
||||
// Called for reaction at enter to combat if not in combat yet (enemy can be nullptr)
|
||||
virtual void EnterCombat(Unit* /*victim*/) {}
|
||||
|
||||
// Called when the creature is killed
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace FactorySelector
|
||||
{
|
||||
CreatureAI* selectAI(Creature* creature)
|
||||
{
|
||||
const CreatureAICreator* ai_factory = NULL;
|
||||
const CreatureAICreator* ai_factory = nullptr;
|
||||
CreatureAIRegistry& ai_registry(*CreatureAIRegistry::instance());
|
||||
|
||||
// xinef: if we have controlable guardian, define petai for players as they can steer him, otherwise db / normal ai
|
||||
@@ -84,7 +84,7 @@ namespace FactorySelector
|
||||
|
||||
#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS)
|
||||
// select NullCreatureAI if not another cases
|
||||
ainame = (ai_factory == NULL) ? "NullCreatureAI" : ai_factory->key();
|
||||
ainame = (ai_factory == nullptr) ? "NullCreatureAI" : ai_factory->key();
|
||||
sLog->outDebug(LOG_FILTER_TSCR, "Creature %u used AI is %s.", creature->GetGUIDLow(), ainame.c_str());
|
||||
#endif
|
||||
return (ai_factory == NULL ? new NullCreatureAI(creature) : ai_factory->Create(creature));
|
||||
@@ -96,7 +96,7 @@ namespace FactorySelector
|
||||
ASSERT(creature->GetCreatureTemplate());
|
||||
const MovementGeneratorCreator* mv_factory = mv_registry.GetRegistryItem(creature->GetDefaultMovementType());
|
||||
|
||||
/* if (mv_factory == NULL)
|
||||
/* if (mv_factory == nullptr)
|
||||
{
|
||||
int best_val = -1;
|
||||
StringVector l;
|
||||
@@ -105,7 +105,7 @@ namespace FactorySelector
|
||||
{
|
||||
const MovementGeneratorCreator *factory = mv_registry.GetRegistryItem((*iter).c_str());
|
||||
const SelectableMovement *p = dynamic_cast<const SelectableMovement *>(factory);
|
||||
ASSERT(p != NULL);
|
||||
ASSERT(p != nullptr);
|
||||
int val = p->Permit(creature);
|
||||
if (val > best_val)
|
||||
{
|
||||
@@ -121,7 +121,7 @@ namespace FactorySelector
|
||||
|
||||
GameObjectAI* SelectGameObjectAI(GameObject* go)
|
||||
{
|
||||
const GameObjectAICreator* ai_factory = NULL;
|
||||
const GameObjectAICreator* ai_factory = nullptr;
|
||||
GameObjectAIRegistry& ai_registry(*GameObjectAIRegistry::instance());
|
||||
|
||||
if (GameObjectAI* scriptedAI = sScriptMgr->GetGameObjectAI(go))
|
||||
|
||||
@@ -123,7 +123,7 @@ Creature* SummonList::GetCreatureWithEntry(uint32 entry) const
|
||||
return summon;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
ScriptedAI::ScriptedAI(Creature* creature) : CreatureAI(creature),
|
||||
@@ -207,7 +207,7 @@ void ScriptedAI::DoPlaySoundToSet(WorldObject* source, uint32 soundId)
|
||||
|
||||
void ScriptedAI::DoPlayMusic(uint32 soundId, bool zone)
|
||||
{
|
||||
ObjectList* targets = NULL;
|
||||
ObjectList* targets = nullptr;
|
||||
|
||||
if (me && me->FindMap())
|
||||
{
|
||||
@@ -253,11 +253,11 @@ SpellInfo const* ScriptedAI::SelectSpell(Unit* target, uint32 school, uint32 mec
|
||||
{
|
||||
//No target so we can't cast
|
||||
if (!target)
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
//Silenced so we can't cast
|
||||
if (me->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_SILENCED))
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
//Using the extended script system we first create a list of viable spells
|
||||
SpellInfo const* apSpell[CREATURE_MAX_SPELLS];
|
||||
@@ -265,7 +265,7 @@ SpellInfo const* ScriptedAI::SelectSpell(Unit* target, uint32 school, uint32 mec
|
||||
|
||||
uint32 spellCount = 0;
|
||||
|
||||
SpellInfo const* tempSpell = NULL;
|
||||
SpellInfo const* tempSpell = nullptr;
|
||||
|
||||
//Check if each spell is viable(set it to null if not)
|
||||
for (uint32 i = 0; i < CREATURE_MAX_SPELLS; i++)
|
||||
@@ -321,7 +321,7 @@ SpellInfo const* ScriptedAI::SelectSpell(Unit* target, uint32 school, uint32 mec
|
||||
|
||||
//We got our usable spells so now lets randomly pick one
|
||||
if (!spellCount)
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
return apSpell[urand(0, spellCount - 1)];
|
||||
}
|
||||
@@ -377,7 +377,7 @@ void ScriptedAI::DoTeleportAll(float x, float y, float z, float o)
|
||||
|
||||
Unit* ScriptedAI::DoSelectLowestHpFriendly(float range, uint32 minHPDiff)
|
||||
{
|
||||
Unit* unit = NULL;
|
||||
Unit* unit = nullptr;
|
||||
acore::MostHPMissingInRange u_check(me, range, minHPDiff);
|
||||
acore::UnitLastSearcher<acore::MostHPMissingInRange> searcher(me, unit, u_check);
|
||||
me->VisitNearbyObject(range, searcher);
|
||||
@@ -405,7 +405,7 @@ std::list<Creature*> ScriptedAI::DoFindFriendlyMissingBuff(float range, uint32 u
|
||||
|
||||
Player* ScriptedAI::GetPlayerAtMinimumRange(float minimumRange)
|
||||
{
|
||||
Player* player = NULL;
|
||||
Player* player = nullptr;
|
||||
|
||||
CellCoord pair(acore::ComputeCellCoord(me->GetPositionX(), me->GetPositionY()));
|
||||
Cell cell(pair);
|
||||
@@ -456,9 +456,9 @@ bool ScriptedAI::EnterEvadeIfOutOfCombatArea()
|
||||
if (me->IsInEvadeMode() || !me->IsInCombat())
|
||||
return false;
|
||||
|
||||
if (_evadeCheckCooldown == time(NULL))
|
||||
if (_evadeCheckCooldown == time(nullptr))
|
||||
return false;
|
||||
_evadeCheckCooldown = time(NULL);
|
||||
_evadeCheckCooldown = time(nullptr);
|
||||
|
||||
if (!CheckEvadeIfOutOfCombatArea())
|
||||
return false;
|
||||
@@ -484,7 +484,7 @@ Player* ScriptedAI::SelectTargetFromPlayerList(float maxdist, uint32 excludeAura
|
||||
if (!tList.empty())
|
||||
return tList[urand(0,tList.size()-1)];
|
||||
else
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// BossAI - for instanced bosses
|
||||
@@ -492,7 +492,7 @@ Player* ScriptedAI::SelectTargetFromPlayerList(float maxdist, uint32 excludeAura
|
||||
BossAI::BossAI(Creature* creature, uint32 bossId) : ScriptedAI(creature),
|
||||
instance(creature->GetInstanceScript()),
|
||||
summons(creature),
|
||||
_boundary(instance ? instance->GetBossBoundary(bossId) : NULL),
|
||||
_boundary(instance ? instance->GetBossBoundary(bossId) : nullptr),
|
||||
_bossId(bossId)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -27,7 +27,7 @@ npc_escortAI::npc_escortAI(Creature* creature) : ScriptedAI(creature),
|
||||
m_uiPlayerCheckTimer(0),
|
||||
m_uiEscortState(STATE_ESCORT_NONE),
|
||||
MaxPlayerDistance(DEFAULT_MAX_PLAYER_DISTANCE),
|
||||
m_pQuestForEscort(NULL),
|
||||
m_pQuestForEscort(nullptr),
|
||||
m_bIsActiveAttacker(true),
|
||||
m_bIsRunning(false),
|
||||
m_bCanInstantRespawn(false),
|
||||
@@ -116,7 +116,7 @@ void npc_escortAI::JustDied(Unit* /*killer*/)
|
||||
{
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
if (Player* member = groupRef->GetSource())
|
||||
if (member->IsInMap(player) && member->GetQuestStatus(m_pQuestForEscort->GetQuestId()) == QUEST_STATUS_INCOMPLETE)
|
||||
member->FailQuest(m_pQuestForEscort->GetQuestId());
|
||||
@@ -158,7 +158,7 @@ void npc_escortAI::EnterEvadeMode()
|
||||
me->RemoveAllAuras();
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(true);
|
||||
me->SetLootRecipient(NULL);
|
||||
me->SetLootRecipient(nullptr);
|
||||
|
||||
if (HasEscortState(STATE_ESCORT_ESCORTING))
|
||||
{
|
||||
@@ -183,7 +183,7 @@ bool npc_escortAI::IsPlayerOrGroupInRange()
|
||||
{
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
if (Player* member = groupRef->GetSource())
|
||||
if (me->IsWithinDistInMap(member, GetMaxPlayerDistance()))
|
||||
return true;
|
||||
|
||||
@@ -26,7 +26,7 @@ FollowerAI::FollowerAI(Creature* creature) : ScriptedAI(creature),
|
||||
m_uiLeaderGUID(0),
|
||||
m_uiUpdateFollowTimer(2500),
|
||||
m_uiFollowState(STATE_FOLLOW_NONE),
|
||||
m_pQuestForFollow(NULL)
|
||||
m_pQuestForFollow(nullptr)
|
||||
{}
|
||||
|
||||
void FollowerAI::AttackStart(Unit* who)
|
||||
@@ -109,7 +109,7 @@ void FollowerAI::JustDied(Unit* /*pKiller*/)
|
||||
{
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
{
|
||||
if (Player* member = groupRef->GetSource())
|
||||
{
|
||||
@@ -144,7 +144,7 @@ void FollowerAI::EnterEvadeMode()
|
||||
me->RemoveAllAuras();
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(true);
|
||||
me->SetLootRecipient(NULL);
|
||||
me->SetLootRecipient(nullptr);
|
||||
|
||||
if (HasFollowState(STATE_FOLLOW_INPROGRESS))
|
||||
{
|
||||
@@ -200,7 +200,7 @@ void FollowerAI::UpdateAI(uint32 uiDiff)
|
||||
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
{
|
||||
Player* member = groupRef->GetSource();
|
||||
|
||||
@@ -315,7 +315,7 @@ Player* FollowerAI::GetLeaderForFollower()
|
||||
{
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
{
|
||||
Player* member = groupRef->GetSource();
|
||||
|
||||
@@ -335,7 +335,7 @@ Player* FollowerAI::GetLeaderForFollower()
|
||||
#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS)
|
||||
sLog->outDebug(LOG_FILTER_TSCR, "TSCR: FollowerAI GetLeader can not find suitable leader.");
|
||||
#endif
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void FollowerAI::SetFollowComplete(bool bWithEndEvent)
|
||||
|
||||
@@ -42,7 +42,7 @@ class FollowerAI : public ScriptedAI
|
||||
void UpdateAI(uint32); //the "internal" update, calls UpdateFollowerAI()
|
||||
virtual void UpdateFollowerAI(uint32); //used when it's needed to add code in update (abilities, scripted events, etc)
|
||||
|
||||
void StartFollow(Player* player, uint32 factionForFollower = 0, const Quest* quest = NULL);
|
||||
void StartFollow(Player* player, uint32 factionForFollower = 0, const Quest* quest = nullptr);
|
||||
|
||||
void SetFollowPaused(bool bPaused); //if special event require follow mode to hold/resume during the follow
|
||||
void SetFollowComplete(bool bWithEndEvent = false);
|
||||
|
||||
@@ -24,13 +24,13 @@ SmartAI::SmartAI(Creature* c) : CreatureAI(c)
|
||||
{
|
||||
// copy script to local (protection for table reload)
|
||||
|
||||
mWayPoints = NULL;
|
||||
mWayPoints = nullptr;
|
||||
mEscortState = SMART_ESCORT_NONE;
|
||||
mCurrentWPID = 0;//first wp id is 1 !!
|
||||
mWPReached = false;
|
||||
mOOCReached = false;
|
||||
mWPPauseTimer = 0;
|
||||
mLastWP = NULL;
|
||||
mLastWP = nullptr;
|
||||
mEscortNPCFlags = 0;
|
||||
|
||||
mCanRepeatPath = false;
|
||||
@@ -91,7 +91,7 @@ void SmartAI::UpdateDespawn(const uint32 diff)
|
||||
WayPoint* SmartAI::GetNextWayPoint()
|
||||
{
|
||||
if (!mWayPoints || mWayPoints->empty())
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
mCurrentWPID++;
|
||||
WPPath::const_iterator itr = mWayPoints->find(mCurrentWPID);
|
||||
@@ -103,7 +103,7 @@ WayPoint* SmartAI::GetNextWayPoint()
|
||||
|
||||
return (*itr).second;
|
||||
}
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void SmartAI::GenerateWayPointArray(Movement::PointsArray* points)
|
||||
@@ -273,8 +273,8 @@ void SmartAI::StopPath(uint32 DespawnTime, uint32 quest, bool fail)
|
||||
void SmartAI::EndPath(bool fail)
|
||||
{
|
||||
RemoveEscortState(SMART_ESCORT_ESCORTING | SMART_ESCORT_PAUSED | SMART_ESCORT_RETURNING);
|
||||
mWayPoints = NULL;
|
||||
mLastWP = NULL;
|
||||
mWayPoints = nullptr;
|
||||
mLastWP = nullptr;
|
||||
mWPPauseTimer = 0;
|
||||
|
||||
if (mEscortNPCFlags)
|
||||
@@ -291,7 +291,7 @@ void SmartAI::EndPath(bool fail)
|
||||
Player* player = (*targets->begin())->ToPlayer();
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
{
|
||||
Player* groupGuy = groupRef->GetSource();
|
||||
if (!groupGuy || !player->IsInMap(groupGuy))
|
||||
@@ -525,7 +525,7 @@ bool SmartAI::IsEscortInvokerInRange()
|
||||
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
{
|
||||
Player* groupGuy = groupRef->GetSource();
|
||||
|
||||
@@ -629,7 +629,7 @@ void SmartAI::EnterEvadeMode()
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(true);
|
||||
me->LoadCreaturesAddon(true);
|
||||
me->SetLootRecipient(NULL);
|
||||
me->SetLootRecipient(nullptr);
|
||||
me->ResetPlayerDamageReq();
|
||||
me->SetLastDamagedTime(0);
|
||||
|
||||
@@ -1190,7 +1190,7 @@ class SmartTrigger : public AreaTriggerScript
|
||||
sLog->outDebug(LOG_FILTER_DATABASE_AI, "AreaTrigger %u is using SmartTrigger script", trigger->entry);
|
||||
#endif
|
||||
SmartScript script;
|
||||
script.OnInitialize(NULL, trigger);
|
||||
script.OnInitialize(nullptr, trigger);
|
||||
script.ProcessEventsFor(SMART_EVENT_AREATRIGGER_ONTRIGGER, player, trigger->entry);
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ class SmartAI : public CreatureAI
|
||||
explicit SmartAI(Creature* c);
|
||||
|
||||
// Start moving to the desired MovePoint
|
||||
void StartPath(bool run = false, uint32 path = 0, bool repeat = false, Unit* invoker = NULL);
|
||||
void StartPath(bool run = false, uint32 path = 0, bool repeat = false, Unit* invoker = nullptr);
|
||||
bool LoadPath(uint32 entry);
|
||||
void PausePath(uint32 delay, bool forced = false);
|
||||
void StopPath(uint32 DespawnTime = 0, uint32 quest = 0, bool fail = false);
|
||||
@@ -66,7 +66,7 @@ class SmartAI : public CreatureAI
|
||||
// Called at reaching home after evade, InitializeAI(), EnterEvadeMode() for resetting variables
|
||||
void JustReachedHome();
|
||||
|
||||
// Called for reaction at enter to combat if not in combat yet (enemy can be NULL)
|
||||
// Called for reaction at enter to combat if not in combat yet (enemy can be nullptr)
|
||||
void EnterCombat(Unit* enemy);
|
||||
|
||||
// Called for reaction at stopping attack at no attackers or targets
|
||||
|
||||
@@ -50,9 +50,9 @@ public:
|
||||
|
||||
SmartScript::SmartScript()
|
||||
{
|
||||
go = NULL;
|
||||
me = NULL;
|
||||
trigger = NULL;
|
||||
go = nullptr;
|
||||
me = nullptr;
|
||||
trigger = nullptr;
|
||||
mEventPhase = 0;
|
||||
mPathId = 0;
|
||||
mTargetStorage = new ObjectListMap();
|
||||
@@ -122,7 +122,7 @@ void SmartScript::ProcessEventsFor(SMART_EVENT e, Unit* unit, uint32 var0, uint3
|
||||
if (eventType == e/* && (!(*i).event.event_phase_mask || IsInPhase((*i).event.event_phase_mask)) && !((*i).event.event_flags & SMART_EVENT_FLAG_NOT_REPEATABLE && (*i).runOnce)*/)
|
||||
{
|
||||
ConditionList conds = sConditionMgr->GetConditionsForSmartEvent((*i).entryOrGuid, (*i).event_id, (*i).source_type);
|
||||
ConditionSourceInfo info = ConditionSourceInfo(unit, GetBaseObject(), me ? me->GetVictim() : NULL);
|
||||
ConditionSourceInfo info = ConditionSourceInfo(unit, GetBaseObject(), me ? me->GetVictim() : nullptr);
|
||||
|
||||
if (sConditionMgr->IsObjectMeetToConditions(info, conds))
|
||||
ProcessEvent(*i, unit, var0, var1, bvar, spell, gob);
|
||||
@@ -154,8 +154,8 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
case SMART_ACTION_TALK:
|
||||
{
|
||||
ObjectList* targets = GetTargets(e, unit);
|
||||
Creature* talker = e.target.type == 0 ? me : NULL; // xinef: tc retardness fix
|
||||
Unit* talkTarget = NULL;
|
||||
Creature* talker = e.target.type == 0 ? me : nullptr; // xinef: tc retardness fix
|
||||
Unit* talkTarget = nullptr;
|
||||
if (targets)
|
||||
{
|
||||
for (ObjectList::const_iterator itr = targets->begin(); itr != targets->end(); ++itr)
|
||||
@@ -316,7 +316,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
}
|
||||
case SMART_ACTION_MUSIC:
|
||||
{
|
||||
ObjectList* targets = NULL;
|
||||
ObjectList* targets = nullptr;
|
||||
|
||||
if (e.action.music.type > 0)
|
||||
{
|
||||
@@ -367,7 +367,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
}
|
||||
case SMART_ACTION_RANDOM_MUSIC:
|
||||
{
|
||||
ObjectList* targets = NULL;
|
||||
ObjectList* targets = nullptr;
|
||||
|
||||
if (e.action.randomMusic.type > 0)
|
||||
{
|
||||
@@ -1045,7 +1045,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
me->DoFleeToGetAssistance();
|
||||
if (e.action.flee.withEmote)
|
||||
{
|
||||
AcoreStringTextBuilder builder(me, CHAT_MSG_MONSTER_EMOTE, LANG_FLEE, LANG_UNIVERSAL, NULL);
|
||||
AcoreStringTextBuilder builder(me, CHAT_MSG_MONSTER_EMOTE, LANG_FLEE, LANG_UNIVERSAL, nullptr);
|
||||
sCreatureTextMgr->SendChatPacket(me, builder, CHAT_MSG_MONSTER_EMOTE);
|
||||
}
|
||||
#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS)
|
||||
@@ -1358,7 +1358,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
(*itr)->ToCreature()->CallForHelp((float)e.action.callHelp.range);
|
||||
if (e.action.callHelp.withEmote)
|
||||
{
|
||||
AcoreStringTextBuilder builder(*itr, CHAT_MSG_MONSTER_EMOTE, LANG_CALL_FOR_HELP, LANG_UNIVERSAL, NULL);
|
||||
AcoreStringTextBuilder builder(*itr, CHAT_MSG_MONSTER_EMOTE, LANG_CALL_FOR_HELP, LANG_UNIVERSAL, nullptr);
|
||||
sCreatureTextMgr->SendChatPacket(*itr, builder, CHAT_MSG_MONSTER_EMOTE);
|
||||
}
|
||||
}
|
||||
@@ -1916,7 +1916,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
if (!IsSmart())
|
||||
break;
|
||||
|
||||
WorldObject* target = NULL;
|
||||
WorldObject* target = nullptr;
|
||||
|
||||
if (e.GetTargetType() == SMART_TARGET_RANDOM_POINT)
|
||||
{
|
||||
@@ -2125,7 +2125,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
meOrigGUID = me ? me->GetGUID() : 0;
|
||||
if (!goOrigGUID)
|
||||
goOrigGUID = go ? go->GetGUID() : 0;
|
||||
go = NULL;
|
||||
go = nullptr;
|
||||
me = (*itr)->ToCreature();
|
||||
break;
|
||||
}
|
||||
@@ -2136,7 +2136,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
if (!goOrigGUID)
|
||||
goOrigGUID = go ? go->GetGUID() : 0;
|
||||
go = (*itr)->ToGameObject();
|
||||
me = NULL;
|
||||
me = nullptr;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -2817,7 +2817,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
waypoints[4] = e.action.closestWaypointFromList.wp5;
|
||||
waypoints[5] = e.action.closestWaypointFromList.wp6;
|
||||
float distanceToClosest = std::numeric_limits<float>::max();
|
||||
WayPoint* closestWp = NULL;
|
||||
WayPoint* closestWp = nullptr;
|
||||
|
||||
ObjectList* targets = GetTargets(e, unit);
|
||||
if (targets)
|
||||
@@ -3304,7 +3304,7 @@ void SmartScript::ProcessTimedAction(SmartScriptHolder& e, uint32 const& min, ui
|
||||
{
|
||||
// xinef: extended by selfs victim
|
||||
ConditionList const conds = sConditionMgr->GetConditionsForSmartEvent(e.entryOrGuid, e.event_id, e.source_type);
|
||||
ConditionSourceInfo info = ConditionSourceInfo(unit, GetBaseObject(), me ? me->GetVictim() : NULL);
|
||||
ConditionSourceInfo info = ConditionSourceInfo(unit, GetBaseObject(), me ? me->GetVictim() : nullptr);
|
||||
|
||||
if (sConditionMgr->IsObjectMeetToConditions(info, conds))
|
||||
{
|
||||
@@ -3428,7 +3428,7 @@ SmartScriptHolder SmartScript::CreateSmartEvent(SMART_EVENT e, uint32 event_flag
|
||||
|
||||
ObjectList* SmartScript::GetTargets(SmartScriptHolder const& e, Unit* invoker /*= NULL*/)
|
||||
{
|
||||
Unit* scriptTrigger = NULL;
|
||||
Unit* scriptTrigger = nullptr;
|
||||
if (invoker)
|
||||
scriptTrigger = invoker;
|
||||
else if (Unit* tempLastInvoker = GetLastInvoker())
|
||||
@@ -3517,7 +3517,7 @@ ObjectList* SmartScript::GetTargets(SmartScriptHolder const& e, Unit* invoker /*
|
||||
{
|
||||
if (Group* group = player->GetGroup())
|
||||
{
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != NULL; groupRef = groupRef->next())
|
||||
for (GroupReference* groupRef = group->GetFirstMember(); groupRef != nullptr; groupRef = groupRef->next())
|
||||
if (Player* member = groupRef->GetSource())
|
||||
if (member->IsInMap(player))
|
||||
l->push_back(member);
|
||||
@@ -3626,7 +3626,7 @@ ObjectList* SmartScript::GetTargets(SmartScriptHolder const& e, Unit* invoker /*
|
||||
}
|
||||
case SMART_TARGET_CREATURE_GUID:
|
||||
{
|
||||
Creature* target = NULL;
|
||||
Creature* target = nullptr;
|
||||
if (!scriptTrigger && !baseObject)
|
||||
{
|
||||
sLog->outError("SMART_TARGET_CREATURE_GUID can not be used without invoker");
|
||||
@@ -3649,7 +3649,7 @@ ObjectList* SmartScript::GetTargets(SmartScriptHolder const& e, Unit* invoker /*
|
||||
}
|
||||
case SMART_TARGET_GAMEOBJECT_GUID:
|
||||
{
|
||||
GameObject* target = NULL;
|
||||
GameObject* target = nullptr;
|
||||
if (!scriptTrigger && !GetBaseObject())
|
||||
{
|
||||
sLog->outError("SMART_TARGET_GAMEOBJECT_GUID can not be used without invoker");
|
||||
@@ -3863,7 +3863,7 @@ ObjectList* SmartScript::GetTargets(SmartScriptHolder const& e, Unit* invoker /*
|
||||
if (l->empty())
|
||||
{
|
||||
delete l;
|
||||
l = NULL;
|
||||
l = nullptr;
|
||||
}
|
||||
|
||||
return l;
|
||||
@@ -4325,7 +4325,7 @@ void SmartScript::ProcessEvent(SmartScriptHolder& e, Unit* unit, uint32 var0, ui
|
||||
if (!me || !me->IsInCombat())
|
||||
return;
|
||||
|
||||
ObjectList* _targets = NULL;
|
||||
ObjectList* _targets = nullptr;
|
||||
|
||||
switch (e.GetTargetType())
|
||||
{
|
||||
@@ -4345,7 +4345,7 @@ void SmartScript::ProcessEvent(SmartScriptHolder& e, Unit* unit, uint32 var0, ui
|
||||
if (!_targets)
|
||||
return;
|
||||
|
||||
Unit* target = NULL;
|
||||
Unit* target = nullptr;
|
||||
|
||||
for (ObjectList::const_iterator itr = _targets->begin(); itr != _targets->end(); ++itr)
|
||||
{
|
||||
@@ -4374,7 +4374,7 @@ void SmartScript::ProcessEvent(SmartScriptHolder& e, Unit* unit, uint32 var0, ui
|
||||
if (!me)
|
||||
return;
|
||||
|
||||
WorldObject* creature = NULL;
|
||||
WorldObject* creature = nullptr;
|
||||
|
||||
if (e.event.distance.guid != 0)
|
||||
{
|
||||
@@ -4405,7 +4405,7 @@ void SmartScript::ProcessEvent(SmartScriptHolder& e, Unit* unit, uint32 var0, ui
|
||||
if (!me)
|
||||
return;
|
||||
|
||||
WorldObject* gameobject = NULL;
|
||||
WorldObject* gameobject = nullptr;
|
||||
|
||||
if (e.event.distance.guid != 0)
|
||||
{
|
||||
@@ -4704,14 +4704,14 @@ void SmartScript::GetScript()
|
||||
e = sSmartScriptMgr->GetScript(-((int32)me->GetDBTableGUIDLow()), mScriptType);
|
||||
if (e.empty())
|
||||
e = sSmartScriptMgr->GetScript((int32)me->GetEntry(), mScriptType);
|
||||
FillScript(e, me, NULL);
|
||||
FillScript(e, me, nullptr);
|
||||
}
|
||||
else if (go)
|
||||
{
|
||||
e = sSmartScriptMgr->GetScript(-((int32)go->GetDBTableGUIDLow()), mScriptType);
|
||||
if (e.empty())
|
||||
e = sSmartScriptMgr->GetScript((int32)go->GetEntry(), mScriptType);
|
||||
FillScript(e, go, NULL);
|
||||
FillScript(e, go, nullptr);
|
||||
}
|
||||
else if (trigger)
|
||||
{
|
||||
@@ -4854,9 +4854,9 @@ return 0;
|
||||
Unit* SmartScript::DoSelectLowestHpFriendly(float range, uint32 MinHPDiff)
|
||||
{
|
||||
if (!me)
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
Unit* unit = NULL;
|
||||
Unit* unit = nullptr;
|
||||
|
||||
acore::MostHPMissingInRange u_check(me, range, MinHPDiff);
|
||||
acore::UnitLastSearcher<acore::MostHPMissingInRange> searcher(me, unit, u_check);
|
||||
@@ -4887,9 +4887,9 @@ void SmartScript::DoFindFriendlyMissingBuff(std::list<Creature*>& list, float ra
|
||||
Unit* SmartScript::DoFindClosestFriendlyInRange(float range, bool playerOnly)
|
||||
{
|
||||
if (!me)
|
||||
return NULL;
|
||||
return nullptr;
|
||||
|
||||
Unit* unit = NULL;
|
||||
Unit* unit = nullptr;
|
||||
acore::AnyFriendlyNotSelfUnitInObjectRangeCheck u_check(me, me, range, playerOnly);
|
||||
acore::UnitLastSearcher<acore::AnyFriendlyNotSelfUnitInObjectRangeCheck> searcher(me, unit, u_check);
|
||||
me->VisitNearbyObject(range, searcher);
|
||||
@@ -4933,5 +4933,5 @@ Unit* SmartScript::GetLastInvoker(Unit* invoker)
|
||||
// xinef: used for area triggers invoker cast
|
||||
else if (invoker)
|
||||
return ObjectAccessor::GetUnit(*invoker, mLastInvoker);
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -23,19 +23,19 @@ class SmartScript
|
||||
SmartScript();
|
||||
~SmartScript();
|
||||
|
||||
void OnInitialize(WorldObject* obj, AreaTrigger const* at = NULL);
|
||||
void OnInitialize(WorldObject* obj, AreaTrigger const* at = nullptr);
|
||||
void GetScript();
|
||||
void FillScript(SmartAIEventList e, WorldObject* obj, AreaTrigger const* at);
|
||||
|
||||
void ProcessEventsFor(SMART_EVENT e, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = NULL);
|
||||
void ProcessEvent(SmartScriptHolder& e, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = NULL);
|
||||
void ProcessEventsFor(SMART_EVENT e, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = nullptr);
|
||||
void ProcessEvent(SmartScriptHolder& e, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = nullptr);
|
||||
bool CheckTimer(SmartScriptHolder const& e) const;
|
||||
void RecalcTimer(SmartScriptHolder& e, uint32 min, uint32 max);
|
||||
void UpdateTimer(SmartScriptHolder& e, uint32 const diff);
|
||||
void InitTimer(SmartScriptHolder& e);
|
||||
void ProcessAction(SmartScriptHolder& e, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = NULL);
|
||||
void ProcessTimedAction(SmartScriptHolder& e, uint32 const& min, uint32 const& max, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = NULL);
|
||||
ObjectList* GetTargets(SmartScriptHolder const& e, Unit* invoker = NULL);
|
||||
void ProcessAction(SmartScriptHolder& e, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = nullptr);
|
||||
void ProcessTimedAction(SmartScriptHolder& e, uint32 const& min, uint32 const& max, Unit* unit = NULL, uint32 var0 = 0, uint32 var1 = 0, bool bvar = false, const SpellInfo* spell = NULL, GameObject* gob = nullptr);
|
||||
ObjectList* GetTargets(SmartScriptHolder const& e, Unit* invoker = nullptr);
|
||||
ObjectList* GetWorldObjectsInDist(float dist);
|
||||
void InstallTemplate(SmartScriptHolder const& e);
|
||||
SmartScriptHolder CreateSmartEvent(SMART_EVENT e, uint32 event_flags, uint32 event_param1, uint32 event_param2, uint32 event_param3, uint32 event_param4, uint32 event_param5, SMART_ACTION action, uint32 action_param1, uint32 action_param2, uint32 action_param3, uint32 action_param4, uint32 action_param5, uint32 action_param6, SMARTAI_TARGETS t, uint32 target_param1, uint32 target_param2, uint32 target_param3, uint32 target_param4, uint32 phaseMask);
|
||||
@@ -44,7 +44,7 @@ class SmartScript
|
||||
uint32 GetPathId() const { return mPathId; }
|
||||
WorldObject* GetBaseObject()
|
||||
{
|
||||
WorldObject* obj = NULL;
|
||||
WorldObject* obj = nullptr;
|
||||
if (me)
|
||||
obj = me;
|
||||
else if (go)
|
||||
@@ -97,7 +97,7 @@ class SmartScript
|
||||
(*mTargetStorage)[id] = new ObjectGuidList(targets, GetBaseObject());
|
||||
}
|
||||
|
||||
bool IsSmart(Creature* c = NULL)
|
||||
bool IsSmart(Creature* c = nullptr)
|
||||
{
|
||||
bool smart = true;
|
||||
if (c && c->GetAIName() != "SmartAI")
|
||||
@@ -112,7 +112,7 @@ class SmartScript
|
||||
return smart;
|
||||
}
|
||||
|
||||
bool IsSmartGO(GameObject* g = NULL)
|
||||
bool IsSmartGO(GameObject* g = nullptr)
|
||||
{
|
||||
bool smart = true;
|
||||
if (g && g->GetAIName() != "SmartGameObjectAI")
|
||||
@@ -131,7 +131,7 @@ class SmartScript
|
||||
ObjectListMap::iterator itr = mTargetStorage->find(id);
|
||||
if (itr != mTargetStorage->end())
|
||||
return (*itr).second->GetObjectList();
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void StoreCounter(uint32 id, uint32 value, uint32 reset)
|
||||
@@ -160,7 +160,7 @@ class SmartScript
|
||||
|
||||
GameObject* FindGameObjectNear(WorldObject* searchObject, uint32 guid) const
|
||||
{
|
||||
GameObject* gameObject = NULL;
|
||||
GameObject* gameObject = nullptr;
|
||||
|
||||
CellCoord p(acore::ComputeCellCoord(searchObject->GetPositionX(), searchObject->GetPositionY()));
|
||||
Cell cell(p);
|
||||
@@ -176,7 +176,7 @@ class SmartScript
|
||||
|
||||
Creature* FindCreatureNear(WorldObject* searchObject, uint32 guid) const
|
||||
{
|
||||
Creature* creature = NULL;
|
||||
Creature* creature = nullptr;
|
||||
CellCoord p(acore::ComputeCellCoord(searchObject->GetPositionX(), searchObject->GetPositionY()));
|
||||
Cell cell(p);
|
||||
|
||||
@@ -199,14 +199,14 @@ class SmartScript
|
||||
if (Creature* m = HashMapHolder<Creature>::Find(meOrigGUID))
|
||||
{
|
||||
me = m;
|
||||
go = NULL;
|
||||
go = nullptr;
|
||||
}
|
||||
}
|
||||
if (goOrigGUID)
|
||||
{
|
||||
if (GameObject* o = HashMapHolder<GameObject>::Find(goOrigGUID))
|
||||
{
|
||||
me = NULL;
|
||||
me = nullptr;
|
||||
go = o;
|
||||
}
|
||||
}
|
||||
@@ -216,7 +216,7 @@ class SmartScript
|
||||
|
||||
//TIMED_ACTIONLIST (script type 9 aka script9)
|
||||
void SetScript9(SmartScriptHolder& e, uint32 entry);
|
||||
Unit* GetLastInvoker(Unit* invoker = NULL);
|
||||
Unit* GetLastInvoker(Unit* invoker = nullptr);
|
||||
uint64 mLastInvoker;
|
||||
typedef std::unordered_map<uint32, uint32> CounterMap;
|
||||
CounterMap mCounterList;
|
||||
|
||||
@@ -1711,7 +1711,7 @@ class ObjectGuidList
|
||||
public:
|
||||
ObjectGuidList(ObjectList* objectList, WorldObject* baseObject)
|
||||
{
|
||||
ASSERT(objectList != NULL);
|
||||
ASSERT(objectList != nullptr);
|
||||
m_objectList = objectList;
|
||||
m_baseObject = baseObject;
|
||||
m_guidList = new GuidList();
|
||||
|
||||
Reference in New Issue
Block a user