aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKudlaty <none@none>2009-08-16 18:34:45 +0200
committerKudlaty <none@none>2009-08-16 18:34:45 +0200
commita4b91e2cc4a4d0a09bce01c686df1fc7c812a12a (patch)
treef8530a665348452f6a59cda0661451c6958b54cd
parent9ddfd5bf22269f8622f72ee3797a56b0dcc37422 (diff)
Merge [SD2]
r1311 Move SetData from Reset to JustReachedHome for channelers and boss. r1312 Added class for FollowerAI. Note this is under development and may have issues in some situations. FollowerAI is generally to be used for escort quests where NPC follow leader instead of using a predefined path. --HG-- branch : trunk
-rw-r--r--src/bindings/scripts/CMakeLists.txt6
-rw-r--r--src/bindings/scripts/VC80/80ScriptDev2.vcproj12
-rw-r--r--src/bindings/scripts/VC90/90ScriptDev2.vcproj12
-rw-r--r--src/bindings/scripts/base/escort_ai.cpp (renamed from src/bindings/scripts/base/escortAI.cpp)2
-rw-r--r--src/bindings/scripts/base/escort_ai.h (renamed from src/bindings/scripts/base/escortAI.h)0
-rw-r--r--src/bindings/scripts/base/follower_ai.cpp309
-rw-r--r--src/bindings/scripts/base/follower_ai.h50
-rw-r--r--src/bindings/scripts/scripts/custom/test.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/arathi_highlands.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/blackrock_depths/blackrock_depths.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/eversong_woods.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/ghostlands.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/hinterlands.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/karazhan/karazhan.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/scarlet_enclave/the_scarlet_enclave.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/scarlet_monastery/boss_herod.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/shadowfang_keep/shadowfang_keep.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/silverpine_forest.cpp2
-rw-r--r--src/bindings/scripts/scripts/eastern_kingdoms/westfall.cpp2
-rw-r--r--src/bindings/scripts/scripts/examples/example_escort.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/ashenvale.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/azuremyst_isle.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjalAI.h2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjal_trash.h2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/darkshore.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/feralas.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/moonglade.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/mulgore.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/razorfen_kraul/razorfen_kraul.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/stonetalon_mountains.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/tanaris.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/the_barrens.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/thousand_needles.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/ungoro_crater.cpp2
-rw-r--r--src/bindings/scripts/scripts/kalimdor/wailing_caverns/wailing_caverns.cpp2
-rw-r--r--src/bindings/scripts/scripts/northrend/sholazar_basin.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp33
-rw-r--r--src/bindings/scripts/scripts/outland/hellfire_peninsula.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/netherstorm.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/shadowmoon_valley.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/shattrath_city.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/terokkar_forest.cpp2
-rw-r--r--src/bindings/scripts/scripts/outland/zangarmarsh.cpp2
-rw-r--r--src/bindings/scripts/scripts/world/npcs_special.cpp2
48 files changed, 444 insertions, 60 deletions
diff --git a/src/bindings/scripts/CMakeLists.txt b/src/bindings/scripts/CMakeLists.txt
index 3ee74c0e592..571dbc1b2a9 100644
--- a/src/bindings/scripts/CMakeLists.txt
+++ b/src/bindings/scripts/CMakeLists.txt
@@ -4,8 +4,10 @@
SET(trinityscript_LIB_SRCS
ScriptMgr.cpp
ScriptMgr.h
- base/escortAI.cpp
- base/escortAI.h
+ base/escort_ai.cpp
+ base/escort_ai.h
+ base/follower_ai.cpp
+ base/follower_ai.h
base/guard_ai.cpp
base/guard_ai.h
base/simple_ai.cpp
diff --git a/src/bindings/scripts/VC80/80ScriptDev2.vcproj b/src/bindings/scripts/VC80/80ScriptDev2.vcproj
index 7368025639f..ee1a8c87592 100644
--- a/src/bindings/scripts/VC80/80ScriptDev2.vcproj
+++ b/src/bindings/scripts/VC80/80ScriptDev2.vcproj
@@ -364,11 +364,19 @@
Name="base"
>
<File
- RelativePath="..\base\escortAI.cpp"
+ RelativePath="..\base\escort_ai.cpp"
>
</File>
<File
- RelativePath="..\base\escortAI.h"
+ RelativePath="..\base\escort_ai.h"
+ >
+ </File>
+ <File
+ RelativePath="..\base\follower_ai.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\base\follower_ai.h"
>
</File>
<File
diff --git a/src/bindings/scripts/VC90/90ScriptDev2.vcproj b/src/bindings/scripts/VC90/90ScriptDev2.vcproj
index ea5fbf72f26..6cb095e68e1 100644
--- a/src/bindings/scripts/VC90/90ScriptDev2.vcproj
+++ b/src/bindings/scripts/VC90/90ScriptDev2.vcproj
@@ -361,11 +361,19 @@
Name="base"
>
<File
- RelativePath="..\base\escortAI.cpp"
+ RelativePath="..\base\escort_ai.cpp"
>
</File>
<File
- RelativePath="..\base\escortAI.h"
+ RelativePath="..\base\escort_ai.h"
+ >
+ </File>
+ <File
+ RelativePath="..\base\follower_ai.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\base\follower_ai.h"
>
</File>
<File
diff --git a/src/bindings/scripts/base/escortAI.cpp b/src/bindings/scripts/base/escort_ai.cpp
index 2c9b968d281..3f4c8601f90 100644
--- a/src/bindings/scripts/base/escortAI.cpp
+++ b/src/bindings/scripts/base/escort_ai.cpp
@@ -10,7 +10,7 @@ SDCategory: Npc
EndScriptData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
enum
{
diff --git a/src/bindings/scripts/base/escortAI.h b/src/bindings/scripts/base/escort_ai.h
index 8ce82eb370a..8ce82eb370a 100644
--- a/src/bindings/scripts/base/escortAI.h
+++ b/src/bindings/scripts/base/escort_ai.h
diff --git a/src/bindings/scripts/base/follower_ai.cpp b/src/bindings/scripts/base/follower_ai.cpp
new file mode 100644
index 00000000000..eb847c219db
--- /dev/null
+++ b/src/bindings/scripts/base/follower_ai.cpp
@@ -0,0 +1,309 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software licensed under GPL version 2
+ * Please see the included DOCS/LICENSE.TXT for more information */
+
+/* ScriptData
+SDName: FollowerAI
+SD%Complete: 50
+SDComment: This AI is under development
+SDCategory: Npc
+EndScriptData */
+
+#include "precompiled.h"
+#include "follower_ai.h"
+
+const float MAX_PLAYER_DISTANCE = 100.0f;
+
+enum
+{
+ POINT_COMBAT_START = 0xFFFFFF
+};
+
+FollowerAI::FollowerAI(Creature* pCreature) : ScriptedAI(pCreature),
+ m_uiLeaderGUID(0),
+ m_pQuestForFollow(NULL),
+ m_uiUpdateFollowTimer(2500),
+ m_bIsFollowing(false),
+ m_bIsReturnToLeader(false),
+ m_bIsFollowComplete(false)
+{}
+
+void FollowerAI::AttackStart(Unit* pWho)
+{
+ if (!pWho)
+ return;
+
+ if (m_creature->Attack(pWho, true))
+ {
+ m_creature->AddThreat(pWho, 0.0f);
+ m_creature->SetInCombatWith(pWho);
+ pWho->SetInCombatWith(m_creature);
+
+ if (m_creature->hasUnitState(UNIT_STAT_FOLLOW))
+ m_creature->clearUnitState(UNIT_STAT_FOLLOW);
+
+ if (IsCombatMovement())
+ m_creature->GetMotionMaster()->MoveChase(pWho);
+ }
+}
+
+void FollowerAI::MoveInLineOfSight(Unit* pWho)
+{
+ if (!m_creature->hasUnitState(UNIT_STAT_STUNNED) && pWho->isTargetableForAttack() &&
+ m_creature->IsHostileTo(pWho) && pWho->isInAccessiblePlaceFor(m_creature))
+ {
+ if (!m_creature->canFly() && m_creature->GetDistanceZ(pWho) > CREATURE_Z_ATTACK_RANGE)
+ return;
+
+ //This part provides assistance to a player that are attacked by pWho, even if out of normal aggro range
+ //It will cause m_creature to attack pWho that are attacking _any_ player (which has been confirmed may happen also on offi)
+ //The flag (type_flag) is unconfirmed, but used here for further research and is a good candidate.
+ if (m_creature->hasUnitState(UNIT_STAT_FOLLOW) &&
+ m_creature->GetCreatureInfo()->type_flags & 0x01000 &&
+ pWho->getVictim() &&
+ pWho->getVictim()->GetCharmerOrOwnerPlayerOrPlayerItself() &&
+ m_creature->IsWithinDistInMap(pWho, MAX_PLAYER_DISTANCE) &&
+ m_creature->IsWithinLOSInMap(pWho))
+ {
+ pWho->RemoveAurasDueToSpell(SPELL_AURA_MOD_STEALTH);
+ AttackStart(pWho);
+ }
+ else
+ {
+ float attackRadius = m_creature->GetAttackDistance(pWho);
+ if (m_creature->IsWithinDistInMap(pWho, attackRadius) && m_creature->IsWithinLOSInMap(pWho))
+ {
+ if (!m_creature->getVictim())
+ {
+ pWho->RemoveAurasDueToSpell(SPELL_AURA_MOD_STEALTH);
+ AttackStart(pWho);
+ }
+ else if (m_creature->GetMap()->IsDungeon())
+ {
+ pWho->SetInCombatWith(m_creature);
+ m_creature->AddThreat(pWho, 0.0f);
+ }
+ }
+ }
+ }
+}
+
+void FollowerAI::JustDied(Unit* pKiller)
+{
+ if (!m_bIsFollowing || !m_uiLeaderGUID)
+ return;
+
+ //TODO: need a better check for quests with time limit.
+ if (Player* pPlayer = GetLeaderForFollower())
+ {
+ if (Group* pGroup = pPlayer->GetGroup())
+ {
+ for(GroupReference* pRef = pGroup->GetFirstMember(); pRef != NULL; pRef = pRef->next())
+ {
+ if (Player* pMember = pRef->getSource())
+ {
+ if (pPlayer->GetQuestStatus(m_pQuestForFollow->GetQuestId()) == QUEST_STATUS_INCOMPLETE)
+ pPlayer->FailQuest(m_pQuestForFollow->GetQuestId());
+ }
+ }
+ }
+ else
+ {
+ if (pPlayer->GetQuestStatus(m_pQuestForFollow->GetQuestId()) == QUEST_STATUS_INCOMPLETE)
+ pPlayer->FailQuest(m_pQuestForFollow->GetQuestId());
+ }
+ }
+}
+
+void FollowerAI::JustRespawned()
+{
+ m_bIsFollowing = false;
+ m_bIsReturnToLeader = false;
+ m_bIsFollowComplete = false;
+
+ if (!IsCombatMovement())
+ SetCombatMovement(true);
+
+ if (m_creature->getFaction() != m_creature->GetCreatureInfo()->faction_A)
+ m_creature->setFaction(m_creature->GetCreatureInfo()->faction_A);
+
+ Reset();
+}
+
+void FollowerAI::EnterEvadeMode()
+{
+ m_creature->RemoveAllAuras();
+ m_creature->DeleteThreatList();
+ m_creature->CombatStop(true);
+ m_creature->SetLootRecipient(NULL);
+
+ if (m_bIsFollowing)
+ {
+ debug_log("SD2: FollowerAI left combat, returning to CombatStartPosition.");
+
+ if (m_creature->GetMotionMaster()->GetCurrentMovementGeneratorType() == TARGETED_MOTION_TYPE)
+ {
+ float fPosX, fPosY, fPosZ;
+ m_creature->GetPosition(fPosX, fPosY, fPosZ);
+ m_creature->GetMotionMaster()->MovePoint(POINT_COMBAT_START, fPosX, fPosY, fPosZ);
+ }
+ }
+ else
+ {
+ if (m_creature->GetMotionMaster()->GetCurrentMovementGeneratorType() == TARGETED_MOTION_TYPE)
+ m_creature->GetMotionMaster()->MoveTargetedHome();
+ }
+
+ Reset();
+}
+
+void FollowerAI::UpdateAI(const uint32 uiDiff)
+{
+ if (m_bIsFollowing && !m_creature->getVictim())
+ {
+ if (m_uiUpdateFollowTimer < uiDiff)
+ {
+ if (m_bIsFollowComplete)
+ {
+ debug_log("SD2: FollowerAI is set completed, despawns.");
+ m_creature->ForcedDespawn();
+ return;
+ }
+
+ bool bIsMaxRangeExceeded = true;
+
+ if (Player* pPlayer = GetLeaderForFollower())
+ {
+ if (m_bIsReturnToLeader)
+ {
+ debug_log("SD2: FollowerAI is returning to leader.");
+ m_creature->GetMotionMaster()->MoveFollow(pPlayer, PET_FOLLOW_DIST, PET_FOLLOW_ANGLE);
+ m_bIsReturnToLeader = false;
+ return;
+ }
+
+ if (Group* pGroup = pPlayer->GetGroup())
+ {
+ for(GroupReference* pRef = pGroup->GetFirstMember(); pRef != NULL; pRef = pRef->next())
+ {
+ Player* pMember = pRef->getSource();
+
+ if (pMember && m_creature->IsWithinDistInMap(pMember, MAX_PLAYER_DISTANCE))
+ {
+ bIsMaxRangeExceeded = false;
+ break;
+ }
+ }
+ }
+ else
+ {
+ if (m_creature->IsWithinDistInMap(pPlayer, MAX_PLAYER_DISTANCE))
+ bIsMaxRangeExceeded = false;
+ }
+ }
+
+ if (bIsMaxRangeExceeded)
+ {
+ debug_log("SD2: FollowerAI failed because player/group was to far away or not found");
+ m_creature->ForcedDespawn();
+ return;
+ }
+
+ m_uiUpdateFollowTimer = 1000;
+ }
+ else
+ m_uiUpdateFollowTimer -= uiDiff;
+ }
+
+ UpdateFollowerAI(uiDiff);
+}
+
+void FollowerAI::UpdateFollowerAI(const uint32 uiDiff)
+{
+ if (!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+}
+
+void FollowerAI::MovementInform(uint32 uiMotionType, uint32 uiPointId)
+{
+ if (uiMotionType != POINT_MOTION_TYPE || !m_bIsFollowing)
+ return;
+
+ if (uiPointId == POINT_COMBAT_START)
+ {
+ if (GetLeaderForFollower())
+ m_bIsReturnToLeader = true;
+ else
+ m_creature->ForcedDespawn();
+ }
+}
+
+void FollowerAI::StartFollow(Player* pLeader, uint32 uiFactionForFollower, const Quest* pQuest)
+{
+ if (m_creature->getVictim())
+ {
+ debug_log("SD2: FollowerAI attempt to StartFollow while in combat.");
+ return;
+ }
+
+ if (m_bIsFollowing)
+ {
+ error_log("SD2: FollowerAI attempt to StartFollow while already following.");
+ return;
+ }
+
+ //set variables
+ m_uiLeaderGUID = pLeader->GetGUID();
+
+ if (uiFactionForFollower)
+ m_creature->setFaction(uiFactionForFollower);
+
+ m_pQuestForFollow = pQuest;
+
+ if (m_creature->GetMotionMaster()->GetCurrentMovementGeneratorType() == WAYPOINT_MOTION_TYPE)
+ {
+ m_creature->GetMotionMaster()->Clear();
+ m_creature->GetMotionMaster()->MoveIdle();
+ debug_log("SD2: FollowerAI start with WAYPOINT_MOTION_TYPE, set to MoveIdle.");
+ }
+
+ m_creature->SetUInt32Value(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_NONE);
+
+ m_creature->GetMotionMaster()->MoveFollow(pLeader, PET_FOLLOW_DIST, PET_FOLLOW_ANGLE);
+
+ m_bIsFollowing = true;
+
+ debug_log("SD2: FollowerAI start follow %s (GUID %u)", pLeader->GetName(), m_uiLeaderGUID);
+}
+
+Player* FollowerAI::GetLeaderForFollower()
+{
+ if (Player* pLeader = (Player*)Unit::GetUnit(*m_creature, m_uiLeaderGUID))
+ {
+ if (pLeader->isAlive())
+ return pLeader;
+ else
+ {
+ if (Group* pGroup = pLeader->GetGroup())
+ {
+ for(GroupReference* pRef = pGroup->GetFirstMember(); pRef != NULL; pRef = pRef->next())
+ {
+ Player* pMember = pRef->getSource();
+
+ if (pMember && pMember->isAlive() && m_creature->IsWithinDistInMap(pMember, MAX_PLAYER_DISTANCE))
+ {
+ debug_log("SD2: FollowerAI GetLeader changed and returned new leader.");
+ m_uiLeaderGUID = pMember->GetGUID();
+ return pMember;
+ break;
+ }
+ }
+ }
+ }
+ }
+
+ debug_log("SD2: FollowerAI GetLeader can not find suitable leader.");
+ return NULL;
+}
diff --git a/src/bindings/scripts/base/follower_ai.h b/src/bindings/scripts/base/follower_ai.h
new file mode 100644
index 00000000000..d62980d4951
--- /dev/null
+++ b/src/bindings/scripts/base/follower_ai.h
@@ -0,0 +1,50 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software licensed under GPL version 2
+ * Please see the included DOCS/LICENSE.TXT for more information */
+
+#ifndef SC_FOLLOWERAI_H
+#define SC_FOLLOWERAI_H
+
+class TRINITY_DLL_DECL FollowerAI : public ScriptedAI
+{
+ public:
+ explicit FollowerAI(Creature* pCreature);
+ ~FollowerAI() {}
+
+ //virtual void WaypointReached(uint32 uiPointId) = 0;
+
+ void MovementInform(uint32 uiMotionType, uint32 uiPointId);
+
+ void AttackStart(Unit*);
+
+ void MoveInLineOfSight(Unit*);
+
+ void EnterEvadeMode();
+
+ void JustDied(Unit*);
+
+ void JustRespawned();
+
+ void UpdateAI(const uint32); //the "internal" update, calls UpdateFollowerAI()
+ virtual void UpdateFollowerAI(const uint32); //used when it's needed to add code in update (abilities, scripted events, etc)
+
+ void StartFollow(Player* pPlayer, uint32 uiFactionForFollower = 0, const Quest* pQuest = NULL);
+
+ protected:
+ void SetFollowComplete() { m_bIsFollowComplete = true; }
+ bool IsFollowComplete() { return m_bIsFollowComplete; }
+
+ Player* GetLeaderForFollower();
+
+ private:
+ uint64 m_uiLeaderGUID;
+ uint32 m_uiUpdateFollowTimer;
+
+ bool m_bIsFollowing;
+ bool m_bIsReturnToLeader;
+ bool m_bIsFollowComplete;
+
+ const Quest* m_pQuestForFollow; //normally we have a quest
+};
+
+#endif
diff --git a/src/bindings/scripts/scripts/custom/test.cpp b/src/bindings/scripts/scripts/custom/test.cpp
index 20a3e2a20e3..121f5a5ec10 100644
--- a/src/bindings/scripts/scripts/custom/test.cpp
+++ b/src/bindings/scripts/scripts/custom/test.cpp
@@ -22,7 +22,7 @@ SDCategory: Script Examples
EndScriptData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
struct TRINITY_DLL_DECL npc_testAI : public npc_escortAI
{
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/arathi_highlands.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/arathi_highlands.cpp
index bc33d9841eb..c5325da12d3 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/arathi_highlands.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/arathi_highlands.cpp
@@ -26,7 +26,7 @@ npc_professor_phizzlethorpe
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_professor_phizzlethorpe
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/blackrock_depths/blackrock_depths.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/blackrock_depths/blackrock_depths.cpp
index a9cf7b7391f..ee193df3430 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/blackrock_depths/blackrock_depths.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/blackrock_depths/blackrock_depths.cpp
@@ -37,7 +37,7 @@ npc_rocknot
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include "def_blackrock_depths.h"
/*######
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/eversong_woods.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/eversong_woods.cpp
index 6c76adeaecb..929fea7f41a 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/eversong_woods.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/eversong_woods.cpp
@@ -30,7 +30,7 @@ go_harbinger_second_trial
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_prospector_anvilward
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/ghostlands.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/ghostlands.cpp
index c96923661de..42122c1f002 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/ghostlands.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/ghostlands.cpp
@@ -29,7 +29,7 @@ npc_ranger_lilatha
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_blood_knight_dawnstar
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/hinterlands.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/hinterlands.cpp
index 46f12159acf..b02d3fb918b 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/hinterlands.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/hinterlands.cpp
@@ -26,7 +26,7 @@ npc_rinji
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_rinji
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/karazhan/karazhan.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/karazhan/karazhan.cpp
index 91dd4e44ad3..cecdcc6330e 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/karazhan/karazhan.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/karazhan/karazhan.cpp
@@ -29,7 +29,7 @@ EndContentData */
#include "precompiled.h"
#include "def_karazhan.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
# npc_barnesAI
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_enclave/the_scarlet_enclave.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_enclave/the_scarlet_enclave.cpp
index ae6c4942c1a..1a081a49050 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_enclave/the_scarlet_enclave.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_enclave/the_scarlet_enclave.cpp
@@ -19,7 +19,7 @@
#include "precompiled.h"
#include "Vehicle.h"
#include "ObjectMgr.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#define GCD_CAST 1
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_monastery/boss_herod.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_monastery/boss_herod.cpp
index 5a1c8e6d364..6235499fe13 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_monastery/boss_herod.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/scarlet_monastery/boss_herod.cpp
@@ -22,7 +22,7 @@ SDCategory: Scarlet Monastery
EndScriptData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#define SAY_AGGRO -1189000
#define SAY_WHIRLWIND -1189001
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/shadowfang_keep/shadowfang_keep.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/shadowfang_keep/shadowfang_keep.cpp
index 5f9d42ea65e..346e922a1b4 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/shadowfang_keep/shadowfang_keep.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/shadowfang_keep/shadowfang_keep.cpp
@@ -26,7 +26,7 @@ npc_shadowfang_prisoner
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include "def_shadowfang_keep.h"
/*######
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/silverpine_forest.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/silverpine_forest.cpp
index bd8b2906c92..07b1979f87f 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/silverpine_forest.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/silverpine_forest.cpp
@@ -27,7 +27,7 @@ npc_deathstalker_erland
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_astor_hadren
diff --git a/src/bindings/scripts/scripts/eastern_kingdoms/westfall.cpp b/src/bindings/scripts/scripts/eastern_kingdoms/westfall.cpp
index 3ddaffe6e25..d6cbea99fb5 100644
--- a/src/bindings/scripts/scripts/eastern_kingdoms/westfall.cpp
+++ b/src/bindings/scripts/scripts/eastern_kingdoms/westfall.cpp
@@ -27,7 +27,7 @@ npc_defias_traitor
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_daphne_stilwell
diff --git a/src/bindings/scripts/scripts/examples/example_escort.cpp b/src/bindings/scripts/scripts/examples/example_escort.cpp
index 23c97fb9b60..e603d3ce79c 100644
--- a/src/bindings/scripts/scripts/examples/example_escort.cpp
+++ b/src/bindings/scripts/scripts/examples/example_escort.cpp
@@ -22,7 +22,7 @@ SDCategory: Script Examples
EndScriptData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
enum
{
diff --git a/src/bindings/scripts/scripts/kalimdor/ashenvale.cpp b/src/bindings/scripts/scripts/kalimdor/ashenvale.cpp
index 86f3286c92f..88572bf3463 100644
--- a/src/bindings/scripts/scripts/kalimdor/ashenvale.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/ashenvale.cpp
@@ -27,7 +27,7 @@ npc_ruul_snowhoof
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*####
# npc_torek
diff --git a/src/bindings/scripts/scripts/kalimdor/azuremyst_isle.cpp b/src/bindings/scripts/scripts/kalimdor/azuremyst_isle.cpp
index 71341f4d0ee..0e21a4b310d 100644
--- a/src/bindings/scripts/scripts/kalimdor/azuremyst_isle.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/azuremyst_isle.cpp
@@ -31,7 +31,7 @@ mob_nestlewood_owlkin
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include <cmath>
/*######
diff --git a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjalAI.h b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjalAI.h
index 3b0ff32a429..c646c47699c 100644
--- a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjalAI.h
+++ b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjalAI.h
@@ -6,7 +6,7 @@
#define SC_HYJALAI_H
#include "def_hyjal.h"
-#include "escortAI.h"
+#include "escort_ai.h"
// Trash Mobs summoned in waves
#define NECROMANCER 17899//done
diff --git a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjal_trash.h b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjal_trash.h
index 9eeff8a03f4..17fdbad5fda 100644
--- a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjal_trash.h
+++ b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/hyjal/hyjal_trash.h
@@ -3,7 +3,7 @@
#define SC_HYJAL_TRASH_AI_H
#include "def_hyjal.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#define MINRAIDDAMAGE 700000//minimal damage before trash can drop loot and reputation, resets if faction leader dies
diff --git a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp
index 266f61354c0..6200d947b63 100644
--- a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp
@@ -23,7 +23,7 @@ EndScriptData */
#include "precompiled.h"
#include "def_old_hillsbrad.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## go_barrel_old_hillsbrad
diff --git a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp
index 5559989ef65..7c0290fe565 100644
--- a/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp
@@ -28,7 +28,7 @@ npc_taretha
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include "def_old_hillsbrad.h"
#define QUEST_ENTRY_HILLSBRAD 10282
diff --git a/src/bindings/scripts/scripts/kalimdor/darkshore.cpp b/src/bindings/scripts/scripts/kalimdor/darkshore.cpp
index fef5cf36e43..6c2520cd8b5 100644
--- a/src/bindings/scripts/scripts/kalimdor/darkshore.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/darkshore.cpp
@@ -27,7 +27,7 @@ npc_threshwackonator
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*####
# npc_prospector_remtravel
diff --git a/src/bindings/scripts/scripts/kalimdor/feralas.cpp b/src/bindings/scripts/scripts/kalimdor/feralas.cpp
index 826d9cf19f8..08c00a9a5a7 100644
--- a/src/bindings/scripts/scripts/kalimdor/feralas.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/feralas.cpp
@@ -22,7 +22,7 @@ SDCategory: Feralas
EndScriptData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_gregan_brewspewer
diff --git a/src/bindings/scripts/scripts/kalimdor/moonglade.cpp b/src/bindings/scripts/scripts/kalimdor/moonglade.cpp
index 4206e370f4c..10d61132c5b 100644
--- a/src/bindings/scripts/scripts/kalimdor/moonglade.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/moonglade.cpp
@@ -30,7 +30,7 @@ npc_clintar_dreamwalker
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_bunthen_plainswind
diff --git a/src/bindings/scripts/scripts/kalimdor/mulgore.cpp b/src/bindings/scripts/scripts/kalimdor/mulgore.cpp
index 544cce69d28..97e2e1233cc 100644
--- a/src/bindings/scripts/scripts/kalimdor/mulgore.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/mulgore.cpp
@@ -28,7 +28,7 @@ npc_plains_vision
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
# npc_skorn_whitecloud
diff --git a/src/bindings/scripts/scripts/kalimdor/razorfen_kraul/razorfen_kraul.cpp b/src/bindings/scripts/scripts/kalimdor/razorfen_kraul/razorfen_kraul.cpp
index a6bd845b13e..5c51e64f5a2 100644
--- a/src/bindings/scripts/scripts/kalimdor/razorfen_kraul/razorfen_kraul.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/razorfen_kraul/razorfen_kraul.cpp
@@ -26,7 +26,7 @@ npc_willix
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include "def_razorfen_kraul.h"
#define SAY_READY -1047000
diff --git a/src/bindings/scripts/scripts/kalimdor/stonetalon_mountains.cpp b/src/bindings/scripts/scripts/kalimdor/stonetalon_mountains.cpp
index 5c9dbe0b199..2b927af4852 100644
--- a/src/bindings/scripts/scripts/kalimdor/stonetalon_mountains.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/stonetalon_mountains.cpp
@@ -27,7 +27,7 @@ npc_kaya_flathoof
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_braug_dimspirit
diff --git a/src/bindings/scripts/scripts/kalimdor/tanaris.cpp b/src/bindings/scripts/scripts/kalimdor/tanaris.cpp
index 44d9c67d9e6..9745fce9966 100644
--- a/src/bindings/scripts/scripts/kalimdor/tanaris.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/tanaris.cpp
@@ -32,7 +32,7 @@ npc_tooga
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## mob_aquementas
diff --git a/src/bindings/scripts/scripts/kalimdor/the_barrens.cpp b/src/bindings/scripts/scripts/kalimdor/the_barrens.cpp
index aff67963445..d17d0b06cd1 100644
--- a/src/bindings/scripts/scripts/kalimdor/the_barrens.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/the_barrens.cpp
@@ -31,7 +31,7 @@ npc_wizzlecrank_shredder
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_beaten_corpse
diff --git a/src/bindings/scripts/scripts/kalimdor/thousand_needles.cpp b/src/bindings/scripts/scripts/kalimdor/thousand_needles.cpp
index 6ec4a1403ab..be0c2db5aa9 100644
--- a/src/bindings/scripts/scripts/kalimdor/thousand_needles.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/thousand_needles.cpp
@@ -29,7 +29,7 @@ npc_plucky
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*#####
# npc_kanati
diff --git a/src/bindings/scripts/scripts/kalimdor/ungoro_crater.cpp b/src/bindings/scripts/scripts/kalimdor/ungoro_crater.cpp
index 426b7fa2217..323faf67814 100644
--- a/src/bindings/scripts/scripts/kalimdor/ungoro_crater.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/ungoro_crater.cpp
@@ -26,7 +26,7 @@ npc_a-me
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#define SAY_READY -1000200
#define SAY_AGGRO1 -1000201
diff --git a/src/bindings/scripts/scripts/kalimdor/wailing_caverns/wailing_caverns.cpp b/src/bindings/scripts/scripts/kalimdor/wailing_caverns/wailing_caverns.cpp
index 622800127db..be222c33e3d 100644
--- a/src/bindings/scripts/scripts/kalimdor/wailing_caverns/wailing_caverns.cpp
+++ b/src/bindings/scripts/scripts/kalimdor/wailing_caverns/wailing_caverns.cpp
@@ -25,7 +25,7 @@ EndScriptData */
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include "def_wailing_caverns.h"
/*######
diff --git a/src/bindings/scripts/scripts/northrend/sholazar_basin.cpp b/src/bindings/scripts/scripts/northrend/sholazar_basin.cpp
index da370ac4978..bb97fb12d18 100644
--- a/src/bindings/scripts/scripts/northrend/sholazar_basin.cpp
+++ b/src/bindings/scripts/scripts/northrend/sholazar_basin.cpp
@@ -26,7 +26,7 @@ npc_injured_rainspeaker_oracle
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_injured_rainspeaker_oracle
diff --git a/src/bindings/scripts/scripts/outland/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp b/src/bindings/scripts/scripts/outland/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp
index f9961e10174..66e6b3a108d 100644
--- a/src/bindings/scripts/scripts/outland/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp
+++ b/src/bindings/scripts/scripts/outland/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp
@@ -22,7 +22,7 @@ SDCategory: Auchindoun, Shadow Labyrinth
EndScriptData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include "def_shadow_labyrinth.h"
enum
diff --git a/src/bindings/scripts/scripts/outland/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp b/src/bindings/scripts/scripts/outland/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp
index 1e62083f1f9..33e6e8f1b3a 100644
--- a/src/bindings/scripts/scripts/outland/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp
+++ b/src/bindings/scripts/scripts/outland/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp
@@ -23,7 +23,7 @@ EndScriptData */
#include "precompiled.h"
#include "def_serpent_shrine.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#define SAY_AGGRO -1548021
#define SAY_GAIN_BLESSING -1548022
diff --git a/src/bindings/scripts/scripts/outland/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp b/src/bindings/scripts/scripts/outland/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp
index 8f7c076a701..24a3afa1d4b 100644
--- a/src/bindings/scripts/scripts/outland/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp
+++ b/src/bindings/scripts/scripts/outland/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp
@@ -205,12 +205,6 @@ struct TRINITY_DLL_DECL boss_magtheridonAI : public ScriptedAI
void Reset()
{
- if (pInstance)
- {
- pInstance->SetData(DATA_MAGTHERIDON_EVENT, NOT_STARTED);
- pInstance->SetData(DATA_COLLAPSE, false);
- }
-
Berserk_Timer = 1320000;
Quake_Timer = 40000;
Debris_Timer = 10000;
@@ -229,6 +223,15 @@ struct TRINITY_DLL_DECL boss_magtheridonAI : public ScriptedAI
m_creature->CastSpell(m_creature, SPELL_SHADOW_CAGE_C, true);
}
+ void JustReachedHome()
+ {
+ if (pInstance)
+ {
+ pInstance->SetData(DATA_MAGTHERIDON_EVENT, NOT_STARTED);
+ pInstance->SetData(DATA_COLLAPSE, false);
+ }
+ }
+
void SetClicker(uint64 cubeGUID, uint64 clickerGUID)
{
// to avoid multiclicks from 1 cube
@@ -432,11 +435,6 @@ struct TRINITY_DLL_DECL mob_hellfire_channelerAI : public ScriptedAI
Infernal_Timer = 10000 + rand()%40000;
Check_Timer = 5000;
-
- if (pInstance)
- pInstance->SetData(DATA_CHANNELER_EVENT, NOT_STARTED);
-
- m_creature->CastSpell(m_creature, SPELL_SHADOW_GRASP_C, false);
}
void EnterCombat(Unit *who)
@@ -448,9 +446,18 @@ struct TRINITY_DLL_DECL mob_hellfire_channelerAI : public ScriptedAI
DoZoneInCombat();
}
- void JustSummoned(Creature *summon) {summon->AI()->AttackStart(m_creature->getVictim());}
+ void JustReachedHome()
+ {
+ if (pInstance)
+ pInstance->SetData(DATA_CHANNELER_EVENT, NOT_STARTED);
+
+ m_creature->CastSpell(m_creature, SPELL_SHADOW_GRASP_C, false);
+ }
- void MoveInLineOfSight(Unit* who) {}
+ void JustSummoned(Creature *summon)
+ {
+ summon->AI()->AttackStart(m_creature->getVictim());
+ }
void DamageTaken(Unit*, uint32 &damage)
{
diff --git a/src/bindings/scripts/scripts/outland/hellfire_peninsula.cpp b/src/bindings/scripts/scripts/outland/hellfire_peninsula.cpp
index 171258922d6..209d11c3509 100644
--- a/src/bindings/scripts/scripts/outland/hellfire_peninsula.cpp
+++ b/src/bindings/scripts/scripts/outland/hellfire_peninsula.cpp
@@ -30,7 +30,7 @@ npc_wounded_blood_elf
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_aeranas
diff --git a/src/bindings/scripts/scripts/outland/netherstorm.cpp b/src/bindings/scripts/scripts/outland/netherstorm.cpp
index e251951f4aa..1e3c4349116 100644
--- a/src/bindings/scripts/scripts/outland/netherstorm.cpp
+++ b/src/bindings/scripts/scripts/outland/netherstorm.cpp
@@ -29,7 +29,7 @@ npc_bessy
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_manaforge_control_console
diff --git a/src/bindings/scripts/scripts/outland/shadowmoon_valley.cpp b/src/bindings/scripts/scripts/outland/shadowmoon_valley.cpp
index 41b1ec159b8..998cedf9c1e 100644
--- a/src/bindings/scripts/scripts/outland/shadowmoon_valley.cpp
+++ b/src/bindings/scripts/scripts/outland/shadowmoon_valley.cpp
@@ -40,7 +40,7 @@ npc_enraged_spirit
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*#####
# mob_mature_netherwing_drake
diff --git a/src/bindings/scripts/scripts/outland/shattrath_city.cpp b/src/bindings/scripts/scripts/outland/shattrath_city.cpp
index e44aea2e0a0..5e0904f7661 100644
--- a/src/bindings/scripts/scripts/outland/shattrath_city.cpp
+++ b/src/bindings/scripts/scripts/outland/shattrath_city.cpp
@@ -33,7 +33,7 @@ npc_khadgar
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npc_raliq_the_drunk
diff --git a/src/bindings/scripts/scripts/outland/terokkar_forest.cpp b/src/bindings/scripts/scripts/outland/terokkar_forest.cpp
index ebe8c0b944f..b2c658c0eef 100644
--- a/src/bindings/scripts/scripts/outland/terokkar_forest.cpp
+++ b/src/bindings/scripts/scripts/outland/terokkar_forest.cpp
@@ -32,7 +32,7 @@ npc_slim
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## mob_unkor_the_ruthless
diff --git a/src/bindings/scripts/scripts/outland/zangarmarsh.cpp b/src/bindings/scripts/scripts/outland/zangarmarsh.cpp
index 5267767c544..0ce14cc0aee 100644
--- a/src/bindings/scripts/scripts/outland/zangarmarsh.cpp
+++ b/src/bindings/scripts/scripts/outland/zangarmarsh.cpp
@@ -30,7 +30,7 @@ npc_kayra_longmane
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
/*######
## npcs_ashyen_and_keleth
diff --git a/src/bindings/scripts/scripts/world/npcs_special.cpp b/src/bindings/scripts/scripts/world/npcs_special.cpp
index 2a56a825b11..ef826d4af3a 100644
--- a/src/bindings/scripts/scripts/world/npcs_special.cpp
+++ b/src/bindings/scripts/scripts/world/npcs_special.cpp
@@ -38,7 +38,7 @@ npc_snake_trap_serpents 80% AI for snakes that summoned by Snake Trap
EndContentData */
#include "precompiled.h"
-#include "escortAI.h"
+#include "escort_ai.h"
#include "ObjectMgr.h"
/*########