mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-26 07:06:23 +00:00
refactor(Core): code cleanup (part 1) (#6361)
This commit is contained in:
@@ -5,11 +5,8 @@
|
||||
*/
|
||||
|
||||
#include "CreatureAIImpl.h"
|
||||
#include "Errors.h"
|
||||
#include "GuardAI.h"
|
||||
#include "ObjectAccessor.h"
|
||||
#include "Player.h"
|
||||
#include "World.h"
|
||||
|
||||
int GuardAI::Permissible(Creature const* creature)
|
||||
{
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
*/
|
||||
|
||||
#include "Creature.h"
|
||||
#include "DBCStores.h"
|
||||
#include "Errors.h"
|
||||
#include "Group.h"
|
||||
#include "ObjectAccessor.h"
|
||||
@@ -17,8 +16,6 @@
|
||||
#include "SpellInfo.h"
|
||||
#include "SpellMgr.h"
|
||||
#include "Util.h"
|
||||
#include "World.h"
|
||||
#include "WorldSession.h"
|
||||
|
||||
int PetAI::Permissible(const Creature* creature)
|
||||
{
|
||||
|
||||
@@ -4,11 +4,8 @@
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
*/
|
||||
|
||||
#include "ByteBuffer.h"
|
||||
#include "CreatureAIImpl.h"
|
||||
#include "Errors.h"
|
||||
#include "Log.h"
|
||||
#include "ObjectAccessor.h"
|
||||
#include "ReactorAI.h"
|
||||
|
||||
int ReactorAI::Permissible(const Creature* creature)
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
#include "Player.h"
|
||||
#include "SpellMgr.h"
|
||||
#include "Vehicle.h"
|
||||
#include "World.h"
|
||||
|
||||
//Disable CreatureAI when charmed
|
||||
void CreatureAI::OnCharmed(bool /*apply*/)
|
||||
@@ -103,8 +102,10 @@ void CreatureAI::DoZoneInCombat(Creature* creature /*= nullptr*/, float maxRange
|
||||
// MoveInLineOfSight can be called inside another MoveInLineOfSight and cause stack overflow
|
||||
void CreatureAI::MoveInLineOfSight_Safe(Unit* who)
|
||||
{
|
||||
if (m_MoveInLineOfSight_locked == true)
|
||||
if (m_MoveInLineOfSight_locked)
|
||||
{
|
||||
return;
|
||||
}
|
||||
m_MoveInLineOfSight_locked = true;
|
||||
MoveInLineOfSight(who);
|
||||
m_MoveInLineOfSight_locked = false;
|
||||
|
||||
Reference in New Issue
Block a user