Skip to content
This repository has been archived by the owner on Feb 29, 2024. It is now read-only.

Remove obsolete macro #1103

Merged
merged 1 commit into from
Jun 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 3 additions & 3 deletions src/server/game/AI/CoreAI/GuardAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ class GuardAI : public ScriptedAI
explicit GuardAI(Creature* creature);

static int Permissible(Creature const* creature);
bool CanSeeAlways(WorldObject const* obj) OVERRIDE;
bool CanSeeAlways(WorldObject const* obj) override;

void EnterEvadeMode() OVERRIDE;
void JustDied(Unit* killer) OVERRIDE;
void EnterEvadeMode() override;
void JustDied(Unit* killer) override;
};
#endif
34 changes: 17 additions & 17 deletions src/server/game/AI/CoreAI/PassiveAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ class PassiveAI : public CreatureAI
public:
explicit PassiveAI(Creature* c);

void MoveInLineOfSight(Unit*) OVERRIDE { }
void AttackStart(Unit*) OVERRIDE { }
void UpdateAI(uint32) OVERRIDE;
void MoveInLineOfSight(Unit*) override { }
void AttackStart(Unit*) override { }
void UpdateAI(uint32) override;

static int Permissible(const Creature*) { return PERMIT_BASE_IDLE; }
};
Expand All @@ -39,13 +39,13 @@ class PossessedAI : public CreatureAI
public:
explicit PossessedAI(Creature* c);

void MoveInLineOfSight(Unit*) OVERRIDE { }
void AttackStart(Unit* target) OVERRIDE;
void UpdateAI(uint32) OVERRIDE;
void EnterEvadeMode() OVERRIDE { }
void MoveInLineOfSight(Unit*) override { }
void AttackStart(Unit* target) override;
void UpdateAI(uint32) override;
void EnterEvadeMode() override { }

void JustDied(Unit*) OVERRIDE;
void KilledUnit(Unit* victim) OVERRIDE;
void JustDied(Unit*) override;
void KilledUnit(Unit* victim) override;

static int Permissible(const Creature*) { return PERMIT_BASE_IDLE; }
};
Expand All @@ -55,11 +55,11 @@ class NullCreatureAI : public CreatureAI
public:
explicit NullCreatureAI(Creature* c);

void MoveInLineOfSight(Unit*) OVERRIDE { }
void AttackStart(Unit*) OVERRIDE { }
void UpdateAI(uint32) OVERRIDE { }
void EnterEvadeMode() OVERRIDE { }
void OnCharmed(bool /*apply*/) OVERRIDE { }
void MoveInLineOfSight(Unit*) override { }
void AttackStart(Unit*) override { }
void UpdateAI(uint32) override { }
void EnterEvadeMode() override { }
void OnCharmed(bool /*apply*/) override { }

static int Permissible(const Creature*) { return PERMIT_BASE_IDLE; }
};
Expand All @@ -69,15 +69,15 @@ class CritterAI : public PassiveAI
public:
explicit CritterAI(Creature* c) : PassiveAI(c) { }

void DamageTaken(Unit* done_by, uint32& /*damage*/) OVERRIDE;
void EnterEvadeMode() OVERRIDE;
void DamageTaken(Unit* done_by, uint32& /*damage*/) override;
void EnterEvadeMode() override;
};

class TriggerAI : public NullCreatureAI
{
public:
explicit TriggerAI(Creature* c) : NullCreatureAI(c) { }
void IsSummonedBy(Unit* summoner) OVERRIDE;
void IsSummonedBy(Unit* summoner) override;
};

#endif
20 changes: 10 additions & 10 deletions src/server/game/AI/CoreAI/PetAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,23 +31,23 @@ class PetAI : public CreatureAI
public:
explicit PetAI(Creature* c);

void UpdateAI(uint32) OVERRIDE;
void UpdateAI(uint32) override;
static int Permissible(const Creature*);

void KilledUnit(Unit* /*victim*/) OVERRIDE;
void AttackStart(Unit* target) OVERRIDE;
void MovementInform(uint32 moveType, uint32 data) OVERRIDE;
void OwnerAttackedBy(Unit* attacker) OVERRIDE;
void OwnerAttacked(Unit* target) OVERRIDE;
void AttackedBy(Unit* attacker) OVERRIDE;
void ReceiveEmote(Player* player, uint32 textEmote) OVERRIDE;
void KilledUnit(Unit* /*victim*/) override;
void AttackStart(Unit* target) override;
void MovementInform(uint32 moveType, uint32 data) override;
void OwnerAttackedBy(Unit* attacker) override;
void OwnerAttacked(Unit* target) override;
void AttackedBy(Unit* attacker) override;
void ReceiveEmote(Player* player, uint32 textEmote) override;

// The following aren't used by the PetAI but need to be defined to override
// default CreatureAI functions which interfere with the PetAI
//
void MoveInLineOfSight(Unit* /*who*/) OVERRIDE { } // CreatureAI interferes with returning pets
void MoveInLineOfSight(Unit* /*who*/) override { } // CreatureAI interferes with returning pets
void MoveInLineOfSight_Safe(Unit* /*who*/) { } // CreatureAI interferes with returning pets
void EnterEvadeMode() OVERRIDE { } // For fleeing, pets don't use this type of Evade mechanic
void EnterEvadeMode() override { } // For fleeing, pets don't use this type of Evade mechanic

private:
bool _isVisible(Unit*) const;
Expand Down
4 changes: 2 additions & 2 deletions src/server/game/AI/CoreAI/ReactorAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ class ReactorAI : public CreatureAI
public:
explicit ReactorAI(Creature* c) : CreatureAI(c) { }

void MoveInLineOfSight(Unit*) OVERRIDE { }
void UpdateAI(uint32 diff) OVERRIDE;
void MoveInLineOfSight(Unit*) override { }
void UpdateAI(uint32 diff) override;

static int Permissible(const Creature*);
};
Expand Down
8 changes: 4 additions & 4 deletions src/server/game/AI/CoreAI/TotemAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,11 @@ class TotemAI : public CreatureAI
public:
explicit TotemAI(Creature* c);

void MoveInLineOfSight(Unit* who) OVERRIDE;
void AttackStart(Unit* victim) OVERRIDE;
void EnterEvadeMode() OVERRIDE;
void MoveInLineOfSight(Unit* who) override;
void AttackStart(Unit* victim) override;
void EnterEvadeMode() override;

void UpdateAI(uint32 diff) OVERRIDE;
void UpdateAI(uint32 diff) override;
static int Permissible(Creature const* creature);

private:
Expand Down
4 changes: 2 additions & 2 deletions src/server/game/AI/CoreAI/UnitAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -277,13 +277,13 @@ class PlayerAI : public UnitAI
public:
explicit PlayerAI(Player* player) : UnitAI((Unit*)player), me(player) { }

void OnCharmed(bool apply) OVERRIDE;
void OnCharmed(bool apply) override;
};

class SimpleCharmedAI : public PlayerAI
{
public:
void UpdateAI(uint32 diff) OVERRIDE;
void UpdateAI(uint32 diff) override;
SimpleCharmedAI(Player* player): PlayerAI(player) { }
};

Expand Down
24 changes: 12 additions & 12 deletions src/server/game/AI/ScriptedAI/ScriptedCreature.h
Original file line number Diff line number Diff line change
Expand Up @@ -156,31 +156,31 @@ struct ScriptedAI : public CreatureAI
void AttackStartNoMove(Unit* target);

// Called at any Damage from any attacker (before damage apply)
void DamageTaken(Unit* /*attacker*/, uint32& /*damage*/) OVERRIDE { }
void DamageTaken(Unit* /*attacker*/, uint32& /*damage*/) override { }

//Called at World update tick
void UpdateAI(uint32 diff) OVERRIDE;
void UpdateAI(uint32 diff) override;

//Called at creature death
void JustDied(Unit* /*killer*/) OVERRIDE { }
void JustDied(Unit* /*killer*/) override { }

//Called at creature killing another unit
void KilledUnit(Unit* /*victim*/) OVERRIDE { }
void KilledUnit(Unit* /*victim*/) override { }

// Called when the creature summon successfully other creature
void JustSummoned(Creature* /*summon*/) OVERRIDE { }
void JustSummoned(Creature* /*summon*/) override { }

// Called when a summoned creature is despawned
void SummonedCreatureDespawn(Creature* /*summon*/) OVERRIDE { }
void SummonedCreatureDespawn(Creature* /*summon*/) override { }

// Called when hit by a spell
void SpellHit(Unit* /*caster*/, SpellInfo const* /*spell*/) OVERRIDE { }
void SpellHit(Unit* /*caster*/, SpellInfo const* /*spell*/) override { }

// Called when spell hits a target
void SpellHitTarget(Unit* /*target*/, SpellInfo const* /*spell*/) OVERRIDE { }
void SpellHitTarget(Unit* /*target*/, SpellInfo const* /*spell*/) override { }

//Called at waypoint reached or PointMovement end
void MovementInform(uint32 /*type*/, uint32 /*id*/) OVERRIDE { }
void MovementInform(uint32 /*type*/, uint32 /*id*/) override { }

// Called when AI is temporarily replaced or put back when possess is applied or removed
void OnPossess(bool /*apply*/)
Expand All @@ -201,13 +201,13 @@ struct ScriptedAI : public CreatureAI
// *************

//Called at creature reset either by death or evade
void Reset() OVERRIDE { }
void Reset() override { }

//Called at creature aggro either by MoveInLOS or Attack Start
void EnterCombat(Unit* /*victim*/) OVERRIDE { }
void EnterCombat(Unit* /*victim*/) override { }

// Called before EnterCombat even before the creature is in combat.
void AttackStart(Unit* /*target*/) OVERRIDE;
void AttackStart(Unit* /*target*/) override;

// *************
//AI Helper Functions
Expand Down
16 changes: 8 additions & 8 deletions src/server/game/AI/ScriptedAI/ScriptedEscortAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,22 +57,22 @@ struct npc_escortAI : public ScriptedAI
~npc_escortAI() { }

// CreatureAI functions
void AttackStart(Unit* who) OVERRIDE;
void AttackStart(Unit* who) override;

void MoveInLineOfSight(Unit* who) OVERRIDE;
void MoveInLineOfSight(Unit* who) override;

void JustDied(Unit*) OVERRIDE;
void JustDied(Unit*) override;

void JustRespawned() OVERRIDE;
void JustRespawned() override;

void ReturnToLastPoint();

void EnterEvadeMode() OVERRIDE;
void EnterEvadeMode() override;

void UpdateAI(uint32 diff) OVERRIDE; //the "internal" update, calls UpdateEscortAI()
void UpdateAI(uint32 diff) override; //the "internal" update, calls UpdateEscortAI()
virtual void UpdateEscortAI(uint32 const diff); //used when it's needed to add code in update (abilities, scripted events, etc)

void MovementInform(uint32, uint32) OVERRIDE;
void MovementInform(uint32, uint32) override;

// EscortAI functions
void AddWaypoint(uint32 id, float x, float y, float z, uint32 waitTime = 0); // waitTime is in ms
Expand All @@ -95,7 +95,7 @@ struct npc_escortAI : public ScriptedAI
void SetEscortPaused(bool on);

bool HasEscortState(uint32 escortState) { return (m_uiEscortState & escortState); }
virtual bool IsEscorted() OVERRIDE { return (m_uiEscortState & STATE_ESCORT_ESCORTING); }
virtual bool IsEscorted() override { return (m_uiEscortState & STATE_ESCORT_ESCORTING); }

void SetMaxPlayerDistance(float newMax) { MaxPlayerDistance = newMax; }
float GetMaxPlayerDistance() { return MaxPlayerDistance; }
Expand Down
14 changes: 7 additions & 7 deletions src/server/game/AI/ScriptedAI/ScriptedFollowerAI.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,19 +41,19 @@ class FollowerAI : public ScriptedAI

//virtual void WaypointReached(uint32 uiPointId) = 0;

void MovementInform(uint32 motionType, uint32 pointId) OVERRIDE;
void MovementInform(uint32 motionType, uint32 pointId) override;

void AttackStart(Unit*) OVERRIDE;
void AttackStart(Unit*) override;

void MoveInLineOfSight(Unit*) OVERRIDE;
void MoveInLineOfSight(Unit*) override;

void EnterEvadeMode() OVERRIDE;
void EnterEvadeMode() override;

void JustDied(Unit*) OVERRIDE;
void JustDied(Unit*) override;

void JustRespawned() OVERRIDE;
void JustRespawned() override;

void UpdateAI(uint32) OVERRIDE; //the "internal" update, calls UpdateFollowerAI()
void UpdateAI(uint32) override; //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);
Expand Down
Loading