mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-15 10:00:28 +00:00
fix(Core/DB): Hardcoded text - Eastern Kingdoms (#1640)
This commit is contained in:
committed by
Francesco Borzì
parent
7eb703e708
commit
fe17a0eccc
@@ -375,98 +375,6 @@ public:
|
||||
};
|
||||
};
|
||||
|
||||
// npc_kharan_mighthammer
|
||||
enum KharamQuests
|
||||
{
|
||||
QUEST_4001 = 4001,
|
||||
QUEST_4342 = 4342
|
||||
};
|
||||
|
||||
#define GOSSIP_ITEM_KHARAN_1 "I need to know where the princess are, Kharan!"
|
||||
#define GOSSIP_ITEM_KHARAN_2 "All is not lost, Kharan!"
|
||||
#define GOSSIP_ITEM_KHARAN_3 "Gor'shak is my friend, you can trust me."
|
||||
#define GOSSIP_ITEM_KHARAN_4 "Not enough, you need to tell me more."
|
||||
#define GOSSIP_ITEM_KHARAN_5 "So what happened?"
|
||||
#define GOSSIP_ITEM_KHARAN_6 "Continue..."
|
||||
#define GOSSIP_ITEM_KHARAN_7 "So you suspect that someone on the inside was involved? That they were tipped off?"
|
||||
#define GOSSIP_ITEM_KHARAN_8 "Continue with your story please."
|
||||
#define GOSSIP_ITEM_KHARAN_9 "Indeed."
|
||||
#define GOSSIP_ITEM_KHARAN_10 "The door is open, Kharan. You are a free man."
|
||||
|
||||
class npc_kharan_mighthammer : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_kharan_mighthammer() : CreatureScript("npc_kharan_mighthammer") { }
|
||||
|
||||
bool OnGossipSelect(Player* player, Creature* creature, uint32 /*sender*/, uint32 action) override
|
||||
{
|
||||
ClearGossipMenuFor(player);
|
||||
switch (action)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF+1:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
|
||||
SendGossipMenuFor(player, 2475, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+2:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_4, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+3);
|
||||
SendGossipMenuFor(player, 2476, creature->GetGUID());
|
||||
break;
|
||||
|
||||
case GOSSIP_ACTION_INFO_DEF+3:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_5, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+4);
|
||||
SendGossipMenuFor(player, 2477, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+4:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_6, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5);
|
||||
SendGossipMenuFor(player, 2478, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+5:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_7, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+6);
|
||||
SendGossipMenuFor(player, 2479, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+6:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_8, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+7);
|
||||
SendGossipMenuFor(player, 2480, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+7:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_9, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+8);
|
||||
SendGossipMenuFor(player, 2481, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+8:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_10, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+9);
|
||||
SendGossipMenuFor(player, 2482, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+9:
|
||||
CloseGossipMenuFor(player);
|
||||
if (player->GetTeamId() == TEAM_HORDE)
|
||||
player->AreaExploredOrEventHappens(QUEST_4001);
|
||||
else
|
||||
player->AreaExploredOrEventHappens(QUEST_4342);
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool OnGossipHello(Player* player, Creature* creature) override
|
||||
{
|
||||
if (creature->IsQuestGiver())
|
||||
player->PrepareQuestMenu(creature->GetGUID());
|
||||
|
||||
if (player->GetQuestStatus(QUEST_4001) == QUEST_STATUS_INCOMPLETE)
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
|
||||
|
||||
if (player->GetQuestStatus(4342) == QUEST_STATUS_INCOMPLETE)
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_KHARAN_2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+3);
|
||||
|
||||
if (player->GetTeamId() == TEAM_HORDE)
|
||||
SendGossipMenuFor(player, 2473, creature->GetGUID());
|
||||
else
|
||||
SendGossipMenuFor(player, 2474, creature->GetGUID());
|
||||
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
// npc_lokhtos_darkbargainer
|
||||
enum LokhtosItems
|
||||
{
|
||||
@@ -484,9 +392,6 @@ enum LokhtosSpells
|
||||
SPELL_CREATE_THORIUM_BROTHERHOOD_CONTRACT_DND = 23059
|
||||
};
|
||||
|
||||
#define GOSSIP_ITEM_SHOW_ACCESS "Show me what I have access to, Lothos."
|
||||
#define GOSSIP_ITEM_GET_CONTRACT "Get Thorium Brotherhood Contract"
|
||||
|
||||
class npc_lokhtos_darkbargainer : public CreatureScript
|
||||
{
|
||||
public:
|
||||
@@ -512,13 +417,14 @@ public:
|
||||
player->PrepareQuestMenu(creature->GetGUID());
|
||||
|
||||
if (creature->IsVendor() && player->GetReputationRank(59) >= REP_FRIENDLY)
|
||||
AddGossipItemFor(player, GOSSIP_ICON_VENDOR, GOSSIP_ITEM_SHOW_ACCESS, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_TRADE);
|
||||
AddGossipItemFor(player, 4781, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_TRADE);
|
||||
|
||||
|
||||
if (player->GetQuestRewardStatus(QUEST_A_BINDING_CONTRACT) != 1 &&
|
||||
!player->HasItemCount(ITEM_THRORIUM_BROTHERHOOD_CONTRACT, 1, true) &&
|
||||
player->HasItemCount(ITEM_SULFURON_INGOT))
|
||||
{
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_GET_CONTRACT, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
AddGossipItemFor(player, 4781, 1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
}
|
||||
|
||||
if (player->GetReputationRank(59) < REP_FRIENDLY)
|
||||
@@ -1300,7 +1206,6 @@ void AddSC_blackrock_depths()
|
||||
new at_ring_of_law();
|
||||
new npc_grimstone();
|
||||
new npc_phalanx();
|
||||
new npc_kharan_mighthammer();
|
||||
new npc_lokhtos_darkbargainer();
|
||||
new npc_rocknot();
|
||||
// Fix us
|
||||
|
||||
@@ -26,11 +26,6 @@ enum Misc
|
||||
DATA_SKILLPOINT_MIN = 230
|
||||
};
|
||||
|
||||
#define GOSSIP_ITEM_TEACH_1 "Teach me the art of smelting dark iron"
|
||||
#define GOSSIP_ITEM_TEACH_2 "Continue..."
|
||||
#define GOSSIP_ITEM_TEACH_3 "[PH] Continue..."
|
||||
#define GOSSIP_ITEM_TRIBUTE "I want to pay tribute"
|
||||
|
||||
class boss_gloomrel : public CreatureScript
|
||||
{
|
||||
public:
|
||||
@@ -42,7 +37,7 @@ public:
|
||||
switch (action)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF+1:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_TEACH_2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 11);
|
||||
AddGossipItemFor(player, 1828, 1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 11);
|
||||
SendGossipMenuFor(player, 2606, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+11:
|
||||
@@ -50,7 +45,7 @@ public:
|
||||
player->CastSpell(player, SPELL_LEARN_SMELT, false);
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+2:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_TEACH_3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 22);
|
||||
AddGossipItemFor(player, 1828, 1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 22);
|
||||
SendGossipMenuFor(player, 2604, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+22:
|
||||
@@ -68,10 +63,10 @@ public:
|
||||
bool OnGossipHello(Player* player, Creature* creature) override
|
||||
{
|
||||
if (player->GetQuestRewardStatus(QUEST_SPECTRAL_CHALICE) == 1 && player->GetSkillValue(SKILL_MINING) >= DATA_SKILLPOINT_MIN && !player->HasSpell(SPELL_SMELT_DARK_IRON))
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_TEACH_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
AddGossipItemFor(player, 1945, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
|
||||
if (player->GetQuestRewardStatus(QUEST_SPECTRAL_CHALICE) == 0 && player->GetSkillValue(SKILL_MINING) >= DATA_SKILLPOINT_MIN)
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_TRIBUTE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
AddGossipItemFor(player, 1945, 1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
|
||||
SendGossipMenuFor(player, player->GetGossipTextId(creature), creature->GetGUID());
|
||||
return true;
|
||||
@@ -87,9 +82,6 @@ enum DoomrelSpells
|
||||
SPELL_SUMMON_VOIDWALKERS = 15092
|
||||
};
|
||||
|
||||
#define GOSSIP_ITEM_CHALLENGE "Your bondage is at an end, Doom'rel. I challenge you!"
|
||||
#define GOSSIP_SELECT_DOOMREL "[PH] Continue..."
|
||||
|
||||
class boss_doomrel : public CreatureScript
|
||||
{
|
||||
public:
|
||||
@@ -101,7 +93,7 @@ public:
|
||||
switch (action)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF+1:
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_SELECT_DOOMREL, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
AddGossipItemFor(player, 1828, 1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
SendGossipMenuFor(player, 2605, creature->GetGUID());
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+2:
|
||||
@@ -120,7 +112,7 @@ public:
|
||||
|
||||
bool OnGossipHello(Player* player, Creature* creature) override
|
||||
{
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ITEM_CHALLENGE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
AddGossipItemFor(player, 1947, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
SendGossipMenuFor(player, 2601, creature->GetGUID());
|
||||
|
||||
return true;
|
||||
@@ -176,7 +168,7 @@ public:
|
||||
me->LoadCreaturesAddon(true);
|
||||
if (me->IsAlive())
|
||||
me->GetMotionMaster()->MoveTargetedHome();
|
||||
me->SetLootRecipient(NULL);
|
||||
me->SetLootRecipient(nullptr);
|
||||
instance->SetData64(DATA_EVENSTARTER, 0);
|
||||
}
|
||||
|
||||
|
||||
@@ -41,7 +41,6 @@ enum Spells
|
||||
};
|
||||
|
||||
#define GOSSIP_HELLO 4995
|
||||
#define GOSSIP_SELECT "Tell me more."
|
||||
|
||||
enum Events
|
||||
{
|
||||
@@ -182,7 +181,7 @@ class boss_majordomo : public CreatureScript
|
||||
|
||||
bool OnGossipHello(Player* player, Creature* creature) override
|
||||
{
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_SELECT, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
|
||||
AddGossipItemFor(player, 4093, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
SendGossipMenuFor(player, GOSSIP_HELLO, creature->GetGUID());
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ class npc_eye_of_acherus : public CreatureScript
|
||||
public:
|
||||
npc_eye_of_acherus() : CreatureScript("npc_eye_of_acherus") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_eye_of_acherusAI(creature);
|
||||
}
|
||||
@@ -48,7 +48,7 @@ public:
|
||||
|
||||
EventMap events;
|
||||
|
||||
void InitializeAI()
|
||||
void InitializeAI() override
|
||||
{
|
||||
events.Reset();
|
||||
events.ScheduleEvent(EVENT_REMOVE_CONTROL, 500);
|
||||
@@ -58,7 +58,7 @@ public:
|
||||
me->CastSpell(me, SPELL_EYE_OF_ACHERUS_VISUAL, true);
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 point)
|
||||
void MovementInform(uint32 type, uint32 point) override
|
||||
{
|
||||
if (type == ESCORT_MOTION_TYPE || point !=0)
|
||||
events.ScheduleEvent(EVENT_REGAIN_CONTROL, 1000);
|
||||
@@ -72,13 +72,13 @@ public:
|
||||
player->GetSession()->SendPacket(&data);
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* creature)
|
||||
void JustSummoned(Creature* creature) override
|
||||
{
|
||||
if (Unit* target = creature->SelectNearbyTarget())
|
||||
creature->AI()->AttackStart(target);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
events.Update(diff);
|
||||
switch (events.ExecuteEvent())
|
||||
@@ -127,20 +127,18 @@ class spell_q12641_death_comes_from_on_high_summon_ghouls : public SpellScriptLo
|
||||
GetCaster()->CastSpell(target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 54522, true);
|
||||
}
|
||||
|
||||
void Register()
|
||||
void Register() override
|
||||
{
|
||||
OnEffectHitTarget += SpellEffectFn(spell_q12641_death_comes_from_on_high_summon_ghouls_SpellScript::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
SpellScript* GetSpellScript() const override
|
||||
{
|
||||
return new spell_q12641_death_comes_from_on_high_summon_ghouls_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
#define GOSSIP_ACCEPT_DUEL "I challenge you, death knight!"
|
||||
|
||||
enum deathsChallenge
|
||||
{
|
||||
SPELL_DUEL = 52996,
|
||||
@@ -197,7 +195,7 @@ public:
|
||||
return true;
|
||||
|
||||
if (!creature->AI()->GetData(player->GetGUIDLow()))
|
||||
AddGossipItemFor(player, GOSSIP_ICON_CHAT, GOSSIP_ACCEPT_DUEL, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF);
|
||||
AddGossipItemFor(player, 9465, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF);
|
||||
|
||||
SendGossipMenuFor(player, player->GetGossipTextId(creature), creature->GetGUID());
|
||||
}
|
||||
@@ -385,13 +383,13 @@ class spell_item_gift_of_the_harvester : public SpellScriptLoader
|
||||
return SPELL_CAST_OK;
|
||||
}
|
||||
|
||||
void Register()
|
||||
void Register() override
|
||||
{
|
||||
OnCheckCast += SpellCheckCastFn(spell_item_gift_of_the_harvester_SpellScript::CheckRequirement);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
SpellScript* GetSpellScript() const override
|
||||
{
|
||||
return new spell_item_gift_of_the_harvester_SpellScript();
|
||||
}
|
||||
@@ -412,13 +410,13 @@ class spell_q12698_the_gift_that_keeps_on_giving : public SpellScriptLoader
|
||||
GetOriginalCaster()->CastSpell(GetHitUnit(), urand(0, 1) ? GetEffectValue() : SPELL_SUMMON_SCARLET_GHOST, true);
|
||||
}
|
||||
|
||||
void Register()
|
||||
void Register() override
|
||||
{
|
||||
OnEffectHitTarget += SpellEffectFn(spell_q12698_the_gift_that_keeps_on_giving_SpellScript::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
SpellScript* GetSpellScript() const override
|
||||
{
|
||||
return new spell_q12698_the_gift_that_keeps_on_giving_SpellScript();
|
||||
}
|
||||
@@ -429,7 +427,7 @@ class npc_scarlet_ghoul : public CreatureScript
|
||||
public:
|
||||
npc_scarlet_ghoul() : CreatureScript("npc_scarlet_ghoul") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_scarlet_ghoulAI(creature);
|
||||
}
|
||||
@@ -443,7 +441,7 @@ public:
|
||||
EventMap events;
|
||||
uint64 gothikGUID;
|
||||
|
||||
void InitializeAI()
|
||||
void InitializeAI() override
|
||||
{
|
||||
gothikGUID = 0;
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_DISABLE_MOVE);
|
||||
@@ -454,20 +452,20 @@ public:
|
||||
events.ScheduleEvent(EVENT_GHOUL_RESTORE_STATE, 3500);
|
||||
}
|
||||
|
||||
void OwnerAttackedBy(Unit* attacker)
|
||||
void OwnerAttackedBy(Unit* attacker) override
|
||||
{
|
||||
if (!me->IsInCombat() && me->GetReactState() == REACT_DEFENSIVE)
|
||||
AttackStart(attacker);
|
||||
}
|
||||
|
||||
void SetGUID(uint64 guid, int32)
|
||||
void SetGUID(uint64 guid, int32) override
|
||||
{
|
||||
gothikGUID = guid;
|
||||
events.ScheduleEvent(EVENT_GHOUL_MOVE_TO_PIT, 3000);
|
||||
me->GetMotionMaster()->Clear(false);
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 point)
|
||||
void MovementInform(uint32 type, uint32 point) override
|
||||
{
|
||||
if (type == POINT_MOTION_TYPE && point == 1)
|
||||
{
|
||||
@@ -476,7 +474,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
events.Update(diff);
|
||||
switch (events.GetEvent())
|
||||
@@ -522,7 +520,7 @@ class npc_dkc1_gothik : public CreatureScript
|
||||
public:
|
||||
npc_dkc1_gothik() : CreatureScript("npc_dkc1_gothik") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_dkc1_gothikAI(creature);
|
||||
}
|
||||
@@ -533,7 +531,7 @@ public:
|
||||
|
||||
int32 spoken;
|
||||
|
||||
void DoAction(int32 action)
|
||||
void DoAction(int32 action) override
|
||||
{
|
||||
if (action == SAY_GOTHIK_PIT && spoken <= 0)
|
||||
{
|
||||
@@ -542,7 +540,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
void MoveInLineOfSight(Unit* who) override
|
||||
{
|
||||
ScriptedAI::MoveInLineOfSight(who);
|
||||
|
||||
@@ -559,7 +557,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (spoken > 0)
|
||||
spoken -= diff;
|
||||
@@ -574,7 +572,7 @@ class npc_scarlet_cannon : public CreatureScript
|
||||
public:
|
||||
npc_scarlet_cannon() : CreatureScript("npc_scarlet_cannon") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_scarlet_cannonAI(creature);
|
||||
}
|
||||
@@ -584,12 +582,12 @@ public:
|
||||
npc_scarlet_cannonAI(Creature* creature) : VehicleAI(creature) { summonAttackers = 0; }
|
||||
|
||||
uint32 summonAttackers;
|
||||
void PassengerBoarded(Unit* /*passenger*/, int8 /*seatId*/, bool apply)
|
||||
void PassengerBoarded(Unit* /*passenger*/, int8 /*seatId*/, bool apply) override
|
||||
{
|
||||
summonAttackers = apply ? 8000 : 0;
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
VehicleAI::UpdateAI(diff);
|
||||
|
||||
@@ -679,7 +677,7 @@ class npc_unworthy_initiate : public CreatureScript
|
||||
public:
|
||||
npc_unworthy_initiate() : CreatureScript("npc_unworthy_initiate") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_unworthy_initiateAI(creature);
|
||||
}
|
||||
@@ -701,7 +699,7 @@ public:
|
||||
|
||||
EventMap events;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
anchorGUID = 0;
|
||||
phase = PHASE_CHAINED;
|
||||
@@ -712,7 +710,7 @@ public:
|
||||
me->LoadEquipment(0, true);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
void EnterCombat(Unit* /*who*/) override
|
||||
{
|
||||
events.ScheduleEvent(EVENT_ICY_TOUCH, 1000, GCD_CAST);
|
||||
events.ScheduleEvent(EVENT_PLAGUE_STRIKE, 3000, GCD_CAST);
|
||||
@@ -720,7 +718,7 @@ public:
|
||||
events.ScheduleEvent(EVENT_DEATH_COIL, 5000, GCD_CAST);
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 id)
|
||||
void MovementInform(uint32 type, uint32 id) override
|
||||
{
|
||||
if (type != POINT_MOTION_TYPE)
|
||||
return;
|
||||
@@ -754,7 +752,7 @@ public:
|
||||
Talk(SAY_EVENT_START, target);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
switch (phase)
|
||||
{
|
||||
@@ -769,7 +767,7 @@ public:
|
||||
}
|
||||
|
||||
float dist = 99.0f;
|
||||
GameObject* prison = NULL;
|
||||
GameObject* prison = nullptr;
|
||||
|
||||
for (uint8 i = 0; i < 12; ++i)
|
||||
{
|
||||
@@ -865,7 +863,7 @@ class npc_unworthy_initiate_anchor : public CreatureScript
|
||||
public:
|
||||
npc_unworthy_initiate_anchor() : CreatureScript("npc_unworthy_initiate_anchor") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_unworthy_initiate_anchorAI(creature);
|
||||
}
|
||||
@@ -876,13 +874,13 @@ public:
|
||||
|
||||
uint64 prisonerGUID;
|
||||
|
||||
void SetGUID(uint64 guid, int32 /*id*/)
|
||||
void SetGUID(uint64 guid, int32 /*id*/) override
|
||||
{
|
||||
if (!prisonerGUID)
|
||||
prisonerGUID = guid;
|
||||
}
|
||||
|
||||
uint64 GetGUID(int32 /*id*/) const
|
||||
uint64 GetGUID(int32 /*id*/) const override
|
||||
{
|
||||
return prisonerGUID;
|
||||
}
|
||||
@@ -921,7 +919,7 @@ class npc_scarlet_miner_cart : public CreatureScript
|
||||
public:
|
||||
npc_scarlet_miner_cart() : CreatureScript("npc_scarlet_miner_cart") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_scarlet_miner_cartAI(creature);
|
||||
}
|
||||
@@ -937,12 +935,12 @@ public:
|
||||
|
||||
uint64 minerGUID;
|
||||
|
||||
void SetGUID(uint64 guid, int32 /*id*/)
|
||||
void SetGUID(uint64 guid, int32 /*id*/) override
|
||||
{
|
||||
minerGUID = guid;
|
||||
}
|
||||
|
||||
void DoAction(int32 /*param*/)
|
||||
void DoAction(int32 /*param*/) override
|
||||
{
|
||||
if (Creature* miner = ObjectAccessor::GetCreature(*me, minerGUID))
|
||||
{
|
||||
@@ -958,7 +956,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void PassengerBoarded(Unit* who, int8 /*seatId*/, bool apply)
|
||||
void PassengerBoarded(Unit* who, int8 /*seatId*/, bool apply) override
|
||||
{
|
||||
who->SetVisible(!apply);
|
||||
if (!apply)
|
||||
@@ -984,7 +982,7 @@ class npc_scarlet_miner : public CreatureScript
|
||||
public:
|
||||
npc_scarlet_miner() : CreatureScript("npc_scarlet_miner") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_scarlet_minerAI(creature);
|
||||
}
|
||||
@@ -1000,7 +998,7 @@ public:
|
||||
uint32 IntroPhase;
|
||||
uint64 carGUID;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
carGUID = 0;
|
||||
IntroTimer = 0;
|
||||
@@ -1048,7 +1046,7 @@ public:
|
||||
SetDespawnAtFar(false);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 waypointId)
|
||||
void WaypointReached(uint32 waypointId) override
|
||||
{
|
||||
switch (waypointId)
|
||||
{
|
||||
@@ -1080,7 +1078,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (IntroPhase)
|
||||
{
|
||||
|
||||
@@ -36,7 +36,7 @@ class npc_crusade_persuaded : public CreatureScript
|
||||
public:
|
||||
npc_crusade_persuaded() : CreatureScript("npc_crusade_persuaded") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_crusade_persuadedAI(creature);
|
||||
}
|
||||
@@ -49,7 +49,7 @@ public:
|
||||
uint32 speechCounter;
|
||||
uint64 playerGUID;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
speechTimer = 0;
|
||||
speechCounter = 0;
|
||||
@@ -58,13 +58,13 @@ public:
|
||||
me->RestoreFaction();
|
||||
}
|
||||
|
||||
void EnterCombat(Unit*)
|
||||
void EnterCombat(Unit*) override
|
||||
{
|
||||
if (roll_chance_i(33))
|
||||
Talk(SAY_AGGRO);
|
||||
}
|
||||
|
||||
void SpellHit(Unit* caster, const SpellInfo* spell)
|
||||
void SpellHit(Unit* caster, const SpellInfo* spell) override
|
||||
{
|
||||
if (spell->Id == SPELL_PERSUASIVE_STRIKE && caster->GetTypeId() == TYPEID_PLAYER && me->IsAlive() && !speechCounter)
|
||||
{
|
||||
@@ -88,7 +88,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (speechCounter)
|
||||
{
|
||||
@@ -186,7 +186,7 @@ class npc_koltira_deathweaver : public CreatureScript
|
||||
public:
|
||||
npc_koltira_deathweaver() : CreatureScript("npc_koltira_deathweaver") { }
|
||||
|
||||
bool OnQuestAccept(Player* player, Creature* creature, const Quest* quest)
|
||||
bool OnQuestAccept(Player* player, Creature* creature, const Quest* quest) override
|
||||
{
|
||||
if (quest->GetQuestId() == QUEST_BREAKOUT)
|
||||
{
|
||||
@@ -199,7 +199,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_koltira_deathweaverAI(creature);
|
||||
}
|
||||
@@ -216,7 +216,7 @@ public:
|
||||
uint64 m_uiValrothGUID;
|
||||
SummonList summons;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
if (!HasEscortState(STATE_ESCORT_ESCORTING))
|
||||
{
|
||||
@@ -231,7 +231,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void EnterEvadeMode()
|
||||
void EnterEvadeMode() override
|
||||
{
|
||||
me->DeleteThreatList();
|
||||
me->CombatStop(false);
|
||||
@@ -253,7 +253,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
void AttackStart(Unit* who) override
|
||||
{
|
||||
if (HasEscortState(STATE_ESCORT_PAUSED))
|
||||
return;
|
||||
@@ -261,7 +261,7 @@ public:
|
||||
npc_escortAI::AttackStart(who);
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 waypointId)
|
||||
void WaypointReached(uint32 waypointId) override
|
||||
{
|
||||
switch (waypointId)
|
||||
{
|
||||
@@ -297,7 +297,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* summoned)
|
||||
void JustSummoned(Creature* summoned) override
|
||||
{
|
||||
if (Player* player = GetPlayerForEscort())
|
||||
summoned->AI()->AttackStart(player);
|
||||
@@ -316,7 +316,7 @@ public:
|
||||
me->SummonCreature(NPC_CRIMSON_ACOLYTE, 1642.329f, -6045.818f, 127.583f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 uiDiff)
|
||||
void UpdateAI(uint32 uiDiff) override
|
||||
{
|
||||
npc_escortAI::UpdateAI(uiDiff);
|
||||
|
||||
@@ -407,7 +407,7 @@ class npc_scarlet_courier : public CreatureScript
|
||||
public:
|
||||
npc_scarlet_courier() : CreatureScript("npc_scarlet_courier") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_scarlet_courierAI(creature);
|
||||
}
|
||||
@@ -419,21 +419,21 @@ public:
|
||||
uint32 uiStage;
|
||||
uint32 uiStage_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
me->Mount(14338); // not sure about this id
|
||||
uiStage = 1;
|
||||
uiStage_timer = 3000;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
void EnterCombat(Unit* /*who*/) override
|
||||
{
|
||||
Talk(SAY_TREE2);
|
||||
me->Dismount();
|
||||
uiStage = 0;
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 id)
|
||||
void MovementInform(uint32 type, uint32 id) override
|
||||
{
|
||||
if (type != POINT_MOTION_TYPE)
|
||||
return;
|
||||
@@ -442,7 +442,7 @@ public:
|
||||
uiStage = 2;
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (uiStage && !me->IsInCombat())
|
||||
{
|
||||
@@ -499,7 +499,7 @@ class npc_high_inquisitor_valroth : public CreatureScript
|
||||
public:
|
||||
npc_high_inquisitor_valroth() : CreatureScript("npc_high_inquisitor_valroth") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_high_inquisitor_valrothAI(creature);
|
||||
}
|
||||
@@ -512,20 +512,20 @@ public:
|
||||
uint32 uiInquisitor_Penance_timer;
|
||||
uint32 uiValroth_Smite_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
uiRenew_timer = 1000;
|
||||
uiInquisitor_Penance_timer = 2000;
|
||||
uiValroth_Smite_timer = 1000;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
void EnterCombat(Unit* who) override
|
||||
{
|
||||
Talk(SAY_VALROTH_AGGRO);
|
||||
DoCast(who, SPELL_VALROTH_SMITE);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (uiRenew_timer <= diff)
|
||||
{
|
||||
@@ -557,7 +557,7 @@ public:
|
||||
Talk(SAY_VALROTH_RAND);
|
||||
}
|
||||
|
||||
void JustDied(Unit* killer)
|
||||
void JustDied(Unit* killer) override
|
||||
{
|
||||
Talk(SAY_VALROTH_DEATH);
|
||||
killer->CastSpell(me, SPELL_SUMMON_VALROTH_REMAINS, true);
|
||||
@@ -635,7 +635,7 @@ class npc_a_special_surprise : public CreatureScript
|
||||
public:
|
||||
npc_a_special_surprise() : CreatureScript("npc_a_special_surprise") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_a_special_surpriseAI(creature);
|
||||
}
|
||||
@@ -648,7 +648,7 @@ public:
|
||||
uint32 ExecuteSpeech_Counter;
|
||||
uint64 PlayerGUID;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
ExecuteSpeech_Timer = 0;
|
||||
ExecuteSpeech_Counter = 0;
|
||||
@@ -706,7 +706,7 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
void MoveInLineOfSight(Unit* who) override
|
||||
|
||||
{
|
||||
if (PlayerGUID || who->GetTypeId() != TYPEID_PLAYER || !who->IsWithinDist(me, INTERACTION_DISTANCE))
|
||||
@@ -716,7 +716,7 @@ public:
|
||||
PlayerGUID = who->GetGUID();
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (PlayerGUID && !me->GetVictim() && me->IsAlive())
|
||||
{
|
||||
@@ -1065,13 +1065,13 @@ class spell_q12779_an_end_to_all_things : public SpellScriptLoader
|
||||
GetHitUnit()->CastSpell(GetCaster(), GetEffectValue(), true);
|
||||
}
|
||||
|
||||
void Register()
|
||||
void Register() override
|
||||
{
|
||||
OnEffectHitTarget += SpellEffectFn(spell_q12779_an_end_to_all_things_SpellScript::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
SpellScript* GetSpellScript() const override
|
||||
{
|
||||
return new spell_q12779_an_end_to_all_things_SpellScript();
|
||||
}
|
||||
|
||||
@@ -333,8 +333,8 @@ public:
|
||||
player->PrepareQuestMenu(creature->GetGUID());
|
||||
|
||||
if (player->GetQuestStatus(12801) == QUEST_STATUS_INCOMPLETE && !creature->AI()->GetData(WORLD_STATE_SOLDIERS_ENABLE))
|
||||
AddGossipItemFor(player, 0, "I am ready, Highlord. Let the siege of Light's Hope begin!", GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
|
||||
|
||||
AddGossipItemFor(player, 9795, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
|
||||
|
||||
SendGossipMenuFor(player, player->GetGossipTextId(creature), creature->GetGUID());
|
||||
|
||||
return true;
|
||||
@@ -369,7 +369,7 @@ public:
|
||||
uint8 battleStarted;
|
||||
bool resetExecuted;
|
||||
|
||||
void DoAction(int32 param)
|
||||
void DoAction(int32 param) override
|
||||
{
|
||||
if (param == ACTION_START_EVENT && !startTimeRemaining && events.Empty())
|
||||
{
|
||||
@@ -399,7 +399,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
uint32 GetData(uint32 type) const
|
||||
uint32 GetData(uint32 type) const override
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
@@ -433,14 +433,14 @@ public:
|
||||
SendUpdateWorldState(WORLD_STATE_EVENT_BEGIN_ENABLE, GetData(WORLD_STATE_EVENT_BEGIN_ENABLE));
|
||||
}
|
||||
|
||||
void JustSummoned(Creature* cr)
|
||||
void JustSummoned(Creature* cr) override
|
||||
{
|
||||
summons.Summon(cr);
|
||||
|
||||
if (me->IsInCombat() && cr->GetEntry() != NPC_HIGHLORD_TIRION_FORDRING && battleStarted == ENCOUNTER_STATE_FIGHT)
|
||||
{
|
||||
Position pos = LightOfDawnFightPos[urand(0, 9)];
|
||||
if (Unit* target = cr->SelectNearbyTarget(NULL, 10.0f))
|
||||
if (Unit* target = cr->SelectNearbyTarget(nullptr, 10.0f))
|
||||
if (target->GetTypeId() == TYPEID_UNIT)
|
||||
target->GetMotionMaster()->MoveCharge(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), me->GetSpeed(MOVE_RUN));
|
||||
cr->GetMotionMaster()->MoveCharge(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), me->GetSpeed(MOVE_RUN));
|
||||
@@ -455,7 +455,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void SummonedCreatureDies(Creature* creature, Unit*)
|
||||
void SummonedCreatureDies(Creature* creature, Unit*) override
|
||||
{
|
||||
// Refill Armies and update counters
|
||||
if (battleStarted != ENCOUNTER_STATE_FIGHT)
|
||||
@@ -477,7 +477,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void JustDied(Unit*)
|
||||
void JustDied(Unit*) override
|
||||
{
|
||||
summons.DespawnAll();
|
||||
me->SetCorpseDelay(3*60);
|
||||
@@ -504,7 +504,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void EnterCombat(Unit*)
|
||||
void EnterCombat(Unit*) override
|
||||
{
|
||||
if (battleStarted != ENCOUNTER_STATE_FIGHT)
|
||||
return;
|
||||
@@ -516,7 +516,7 @@ public:
|
||||
events.RescheduleEvent(EVENT_SPELL_TALK, 10000);
|
||||
}
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
if (resetExecuted)
|
||||
return;
|
||||
@@ -525,7 +525,7 @@ public:
|
||||
JustRespawned();
|
||||
}
|
||||
|
||||
void JustRespawned()
|
||||
void JustRespawned() override
|
||||
{
|
||||
events.Reset();
|
||||
summons.DespawnAll();
|
||||
@@ -552,10 +552,10 @@ public:
|
||||
if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr))
|
||||
if (summon->GetEntry() == entry)
|
||||
return summon;
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 point)
|
||||
void MovementInform(uint32 type, uint32 point) override
|
||||
{
|
||||
if (type == POINT_MOTION_TYPE && point == 2)
|
||||
{
|
||||
@@ -585,7 +585,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
events.Update(diff);
|
||||
uint32 eventId = events.ExecuteEvent();
|
||||
@@ -1185,14 +1185,14 @@ class spell_chapter5_light_of_dawn_aura : public SpellScriptLoader
|
||||
GetUnitOwner()->GetMotionMaster()->MoveFall();
|
||||
}
|
||||
|
||||
void Register()
|
||||
void Register() override
|
||||
{
|
||||
OnEffectApply += AuraEffectApplyFn(spell_chapter5_light_of_dawn_aura_AuraScript::OnApply, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
|
||||
OnEffectRemove += AuraEffectRemoveFn(spell_chapter5_light_of_dawn_aura_AuraScript::OnRemove, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
AuraScript* GetAuraScript() const override
|
||||
{
|
||||
return new spell_chapter5_light_of_dawn_aura_AuraScript();
|
||||
}
|
||||
@@ -1214,13 +1214,13 @@ class spell_chapter5_rebuke : public SpellScriptLoader
|
||||
unitTarget->KnockbackFrom(2282.86f, -5263.45f, 40.0f, 8.0f);
|
||||
}
|
||||
|
||||
void Register()
|
||||
void Register() override
|
||||
{
|
||||
OnEffectLaunchTarget += SpellEffectFn(spell_chapter5_rebuke_SpellScript::HandleLeapBack, EFFECT_0, SPELL_EFFECT_LEAP_BACK);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
SpellScript* GetSpellScript() const override
|
||||
{
|
||||
return new spell_chapter5_rebuke_SpellScript();
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ class npc_valkyr_battle_maiden : public CreatureScript
|
||||
public:
|
||||
npc_valkyr_battle_maiden() : CreatureScript("npc_valkyr_battle_maiden") { }
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_valkyr_battle_maidenAI(creature);
|
||||
}
|
||||
@@ -41,7 +41,7 @@ public:
|
||||
float x, y, z;
|
||||
uint32 phase;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
me->setActive(true);
|
||||
me->SetVisible(false);
|
||||
@@ -58,11 +58,11 @@ public:
|
||||
me->SetPosition(x, y, z, 0.0f);
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (FlyBackTimer <= diff)
|
||||
{
|
||||
Player* player = NULL;
|
||||
Player* player = nullptr;
|
||||
if (me->IsSummon())
|
||||
if (Unit* summoner = me->ToTempSummon()->GetSummoner())
|
||||
player = summoner->ToPlayer();
|
||||
|
||||
@@ -48,7 +48,7 @@ class instance_scarlet_monastery : public InstanceMapScript
|
||||
public:
|
||||
instance_scarlet_monastery() : InstanceMapScript("instance_scarlet_monastery", 189) { }
|
||||
|
||||
InstanceScript* GetInstanceScript(InstanceMap* map) const
|
||||
InstanceScript* GetInstanceScript(InstanceMap* map) const override
|
||||
{
|
||||
return new instance_scarlet_monastery_InstanceMapScript(map);
|
||||
}
|
||||
@@ -185,12 +185,12 @@ public:
|
||||
{
|
||||
npc_scarlet_guardAI(Creature* creature) : SmartAI(creature) { }
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
SayAshbringer = false;
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
void MoveInLineOfSight(Unit* who) override
|
||||
{
|
||||
if (who && who->GetDistance2d(me) < 12.0f)
|
||||
{
|
||||
@@ -216,7 +216,7 @@ public:
|
||||
bool SayAshbringer = false;
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_scarlet_guardAI(creature);
|
||||
}
|
||||
@@ -363,7 +363,7 @@ public:
|
||||
me->SetSheath(SHEATH_STATE_UNARMED);
|
||||
me->SetStandState(UNIT_STAND_STATE_KNEEL);
|
||||
me->SetFacingToObject(player);
|
||||
me->MonsterYell("Bow down! Kneel before the Ashbringer! A new dawn approaches, brothers and sisters! Our message will be delivered to the filth of this world through the chosen one!", LANG_UNIVERSAL, player);
|
||||
me->MonsterYell(12389, LANG_UNIVERSAL, player);
|
||||
SayAshbringer = true;
|
||||
}
|
||||
|
||||
@@ -493,7 +493,7 @@ public:
|
||||
InstanceScript* instance;
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_mograineAI(creature);
|
||||
}
|
||||
@@ -635,7 +635,7 @@ public:
|
||||
EventMap events;
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new boss_high_inquisitor_whitemaneAI(creature);
|
||||
}
|
||||
|
||||
@@ -16,19 +16,15 @@ EndScriptData */
|
||||
#include "SpellAuraEffects.h"
|
||||
#include "zulaman.h"
|
||||
|
||||
#define YELL_AGGRO "Da shadow gonna fall on you... "
|
||||
#define SOUND_YELL_AGGRO 12041
|
||||
#define YELL_SPIRIT_BOLTS "Your soul gonna bleed!"
|
||||
#define SOUND_YELL_SPIRIT_BOLTS 12047
|
||||
#define YELL_DRAIN_POWER "Darkness comin\' for you"
|
||||
#define SOUND_YELL_DRAIN_POWER 12046
|
||||
#define YELL_KILL_ONE "Dis a nightmare ya don\' wake up from!"
|
||||
#define SOUND_YELL_KILL_ONE 12043
|
||||
#define YELL_KILL_TWO "Azzaga choogo zinn!"
|
||||
#define SOUND_YELL_KILL_TWO 12044
|
||||
#define YELL_DEATH "Dis not... da end of me..."
|
||||
#define SOUND_YELL_DEATH 12051
|
||||
|
||||
enum Says
|
||||
{
|
||||
SAY_AGGRO = 0,
|
||||
SAY_KILL_ONE,
|
||||
SAY_KILL_TWO,
|
||||
SAY_DRAIN_POWER,
|
||||
SAY_SPIRIT_BOLTS,
|
||||
SAY_DEATH
|
||||
};
|
||||
|
||||
enum Creatures
|
||||
{
|
||||
@@ -209,14 +205,14 @@ struct boss_hexlord_addAI : public ScriptedAI
|
||||
instance = creature->GetInstanceScript();
|
||||
}
|
||||
|
||||
void Reset() { }
|
||||
void Reset() override { }
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
void EnterCombat(Unit* /*who*/) override
|
||||
{
|
||||
DoZoneInCombat();
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 /*diff*/)
|
||||
void UpdateAI(uint32 /*diff*/) override
|
||||
{
|
||||
if (instance->GetData(DATA_HEXLORDEVENT) != IN_PROGRESS)
|
||||
{
|
||||
@@ -263,7 +259,7 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
|
||||
uint32 PlayerClass;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
instance->SetData(DATA_HEXLORDEVENT, NOT_STARTED);
|
||||
|
||||
@@ -280,13 +276,12 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
me->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
void EnterCombat(Unit* /*who*/) override
|
||||
{
|
||||
instance->SetData(DATA_HEXLORDEVENT, IN_PROGRESS);
|
||||
|
||||
DoZoneInCombat();
|
||||
me->MonsterYell(YELL_AGGRO, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_AGGRO);
|
||||
Talk(SAY_AGGRO);
|
||||
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
{
|
||||
@@ -301,27 +296,24 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
void KilledUnit(Unit* /*victim*/)
|
||||
void KilledUnit(Unit* /*victim*/) override
|
||||
{
|
||||
switch (urand(0, 1))
|
||||
{
|
||||
case 0:
|
||||
me->MonsterYell(YELL_KILL_ONE, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_KILL_ONE);
|
||||
Talk(SAY_KILL_ONE);
|
||||
break;
|
||||
case 1:
|
||||
me->MonsterYell(YELL_KILL_TWO, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_KILL_TWO);
|
||||
Talk(SAY_KILL_TWO);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void JustDied(Unit* /*killer*/)
|
||||
void JustDied(Unit* /*killer*/) override
|
||||
{
|
||||
instance->SetData(DATA_HEXLORDEVENT, DONE);
|
||||
|
||||
me->MonsterYell(YELL_DEATH, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_DEATH);
|
||||
Talk(SAY_DEATH);
|
||||
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
{
|
||||
@@ -366,7 +358,7 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -394,8 +386,7 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
if (DrainPower_Timer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_DRAIN_POWER, true);
|
||||
me->MonsterYell(YELL_DRAIN_POWER, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_DRAIN_POWER);
|
||||
Talk(SAY_DRAIN_POWER);
|
||||
DrainPower_Timer = urand(40000, 55000); // must cast in 60 sec, or buff/debuff will disappear
|
||||
} else DrainPower_Timer -= diff;
|
||||
|
||||
@@ -406,8 +397,7 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
else
|
||||
{
|
||||
DoCast(me, SPELL_SPIRIT_BOLTS, false);
|
||||
me->MonsterYell(YELL_SPIRIT_BOLTS, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_SPIRIT_BOLTS);
|
||||
Talk(SAY_SPIRIT_BOLTS);
|
||||
SpiritBolts_Timer = 40000;
|
||||
SiphonSoul_Timer = 10000; // ready to drain
|
||||
PlayerAbility_Timer = 99999;
|
||||
@@ -492,7 +482,7 @@ class boss_hexlord_malacrass : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_hex_lord_malacrassAI>(creature);
|
||||
}
|
||||
@@ -515,7 +505,7 @@ class boss_thurg : public CreatureScript
|
||||
uint32 bloodlust_timer;
|
||||
uint32 cleave_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
bloodlust_timer = 15000;
|
||||
cleave_timer = 10000;
|
||||
@@ -523,7 +513,7 @@ class boss_thurg : public CreatureScript
|
||||
boss_hexlord_addAI::Reset();
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -549,7 +539,7 @@ class boss_thurg : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_thurgAI>(creature);
|
||||
}
|
||||
@@ -572,7 +562,7 @@ class boss_alyson_antille : public CreatureScript
|
||||
uint32 flashheal_timer;
|
||||
uint32 dispelmagic_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
flashheal_timer = 2500;
|
||||
dispelmagic_timer = 10000;
|
||||
@@ -582,7 +572,7 @@ class boss_alyson_antille : public CreatureScript
|
||||
boss_hexlord_addAI::Reset();
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
void AttackStart(Unit* who) override
|
||||
{
|
||||
if (!who)
|
||||
return;
|
||||
@@ -597,7 +587,7 @@ class boss_alyson_antille : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -646,7 +636,7 @@ class boss_alyson_antille : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_alyson_antilleAI>(creature);
|
||||
}
|
||||
@@ -658,13 +648,13 @@ struct boss_gazakrothAI : public boss_hexlord_addAI
|
||||
|
||||
uint32 firebolt_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
firebolt_timer = 2000;
|
||||
boss_hexlord_addAI::Reset();
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
void AttackStart(Unit* who) override
|
||||
{
|
||||
if (!who)
|
||||
return;
|
||||
@@ -679,7 +669,7 @@ struct boss_gazakrothAI : public boss_hexlord_addAI
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -710,7 +700,7 @@ class boss_lord_raadan : public CreatureScript
|
||||
uint32 flamebreath_timer;
|
||||
uint32 thunderclap_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
flamebreath_timer = 8000;
|
||||
thunderclap_timer = 13000;
|
||||
@@ -718,7 +708,7 @@ class boss_lord_raadan : public CreatureScript
|
||||
boss_hexlord_addAI::Reset();
|
||||
|
||||
}
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -739,7 +729,7 @@ class boss_lord_raadan : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_lord_raadanAI>(creature);
|
||||
}
|
||||
@@ -760,12 +750,12 @@ class boss_darkheart : public CreatureScript
|
||||
|
||||
uint32 psychicwail_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
psychicwail_timer = 8000;
|
||||
boss_hexlord_addAI::Reset();
|
||||
}
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -780,7 +770,7 @@ class boss_darkheart : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_darkheartAI>(creature);
|
||||
}
|
||||
@@ -802,13 +792,13 @@ class boss_slither : public CreatureScript
|
||||
|
||||
uint32 venomspit_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
venomspit_timer = 5000;
|
||||
boss_hexlord_addAI::Reset();
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
void AttackStart(Unit* who) override
|
||||
{
|
||||
if (!who)
|
||||
return;
|
||||
@@ -823,7 +813,7 @@ class boss_slither : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -839,7 +829,7 @@ class boss_slither : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_slitherAI>(creature);
|
||||
}
|
||||
@@ -860,13 +850,13 @@ class boss_fenstalker : public CreatureScript
|
||||
|
||||
uint32 volatileinf_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
volatileinf_timer = 15000;
|
||||
boss_hexlord_addAI::Reset();
|
||||
|
||||
}
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -882,7 +872,7 @@ class boss_fenstalker : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_fenstalkerAI>(creature);
|
||||
}
|
||||
@@ -904,14 +894,14 @@ class boss_koragg : public CreatureScript
|
||||
uint32 coldstare_timer;
|
||||
uint32 mightyblow_timer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
coldstare_timer = 15000;
|
||||
mightyblow_timer = 10000;
|
||||
boss_hexlord_addAI::Reset();
|
||||
|
||||
}
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
@@ -932,7 +922,7 @@ class boss_koragg : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_koraggAI>(creature);
|
||||
}
|
||||
@@ -947,7 +937,7 @@ class spell_hexlord_unstable_affliction : public SpellScriptLoader
|
||||
{
|
||||
PrepareAuraScript(spell_hexlord_unstable_affliction_AuraScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spell*/)
|
||||
bool Validate(SpellInfo const* /*spell*/) override
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_WL_UNSTABLE_AFFL_DISPEL))
|
||||
return false;
|
||||
@@ -960,13 +950,13 @@ class spell_hexlord_unstable_affliction : public SpellScriptLoader
|
||||
caster->CastSpell(dispelInfo->GetDispeller(), SPELL_WL_UNSTABLE_AFFL_DISPEL, true, NULL, GetEffect(EFFECT_0));
|
||||
}
|
||||
|
||||
void Register()
|
||||
void Register() override
|
||||
{
|
||||
AfterDispel += AuraDispelFn(spell_hexlord_unstable_affliction_AuraScript::HandleDispel);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
AuraScript* GetAuraScript() const override
|
||||
{
|
||||
return new spell_hexlord_unstable_affliction_AuraScript();
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/*
|
||||
/*
|
||||
* Copyright (C) 2016+ AzerothCore <www.azerothcore.org>, released under GNU GPL v2 license: https://github.com/azerothcore/azerothcore-wotlk/blob/master/LICENSE-GPL2
|
||||
* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
@@ -48,41 +48,24 @@ float NalorakkWay[8][3] =
|
||||
{-80.072f, 1295.775f, 48.60f} // waypoint 4
|
||||
};
|
||||
|
||||
#define YELL_NALORAKK_WAVE1 "Get da move on, guards! It be killin' time!"
|
||||
#define SOUND_NALORAKK_WAVE1 12066
|
||||
#define YELL_NALORAKK_WAVE2 "Guards, go already! Who you more afraid of, dem... or me?"
|
||||
#define SOUND_NALORAKK_WAVE2 12067
|
||||
#define YELL_NALORAKK_WAVE3 "Ride now! Ride out dere and bring me back some heads!"
|
||||
#define SOUND_NALORAKK_WAVE3 12068
|
||||
#define YELL_NALORAKK_WAVE4 "I be losin' me patience! Go on: make dem wish dey was never born!"
|
||||
#define SOUND_NALORAKK_WAVE4 12069
|
||||
enum Talks
|
||||
{
|
||||
SAY_WAVE1 = 0,
|
||||
SAY_WAVE2,
|
||||
SAY_WAVE3,
|
||||
SAY_WAVE4,
|
||||
SAY_AGGRO,
|
||||
SAY_SURGE,
|
||||
SAY_SHIFTEDTOBEAR,
|
||||
SAY_SHIFTEDTOTROLL,
|
||||
SAY_BERSERK,
|
||||
SAY_KILL_ONE,
|
||||
SAY_KILL_TWO,
|
||||
SAY_DEATH,
|
||||
SAY_NALORAKK_EVENT1, // Unimplemented
|
||||
SAY_NALORAKK_EVENT2 // Unimplemented
|
||||
|
||||
//Unimplemented SoundIDs
|
||||
/*
|
||||
#define SOUND_NALORAKK_EVENT1 12078
|
||||
#define SOUND_NALORAKK_EVENT2 12079
|
||||
*/
|
||||
|
||||
//General defines
|
||||
#define YELL_AGGRO "You be dead soon enough!"
|
||||
#define SOUND_YELL_AGGRO 12070
|
||||
#define YELL_KILL_ONE "Mua-ha-ha! Now whatchoo got to say?"
|
||||
#define SOUND_YELL_KILL_ONE 12075
|
||||
#define YELL_KILL_TWO "Da Amani gonna rule again!"
|
||||
#define SOUND_YELL_KILL_TWO 12076
|
||||
#define YELL_DEATH "I... be waitin' on da udda side...."
|
||||
#define SOUND_YELL_DEATH 12077
|
||||
#define YELL_BERSERK "You had your chance, now it be too late!" //Never seen this being used, so just guessing from what I hear.
|
||||
#define SOUND_YELL_BERSERK 12074
|
||||
#define YELL_SURGE "I bring da pain!"
|
||||
#define SOUND_YELL_SURGE 12071
|
||||
|
||||
#define YELL_SHIFTEDTOTROLL "Make way for Nalorakk!"
|
||||
#define SOUND_YELL_TOTROLL 12073
|
||||
|
||||
|
||||
#define YELL_SHIFTEDTOBEAR "You call on da beast, you gonna get more dan you bargain for!"
|
||||
#define SOUND_YELL_TOBEAR 12072
|
||||
};
|
||||
|
||||
class boss_nalorakk : public CreatureScript
|
||||
{
|
||||
@@ -121,7 +104,7 @@ class boss_nalorakk : public CreatureScript
|
||||
uint32 MovePhase;
|
||||
uint32 waitTimer;
|
||||
|
||||
void Reset()
|
||||
void Reset() override
|
||||
{
|
||||
if (MoveEvent)
|
||||
{
|
||||
@@ -212,13 +195,13 @@ class boss_nalorakk : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
void AttackStart(Unit* who) override
|
||||
{
|
||||
if (!MoveEvent)
|
||||
ScriptedAI::AttackStart(who);
|
||||
}
|
||||
|
||||
void MoveInLineOfSight(Unit* who)
|
||||
void MoveInLineOfSight(Unit* who) override
|
||||
|
||||
{
|
||||
if (!MoveEvent)
|
||||
@@ -236,8 +219,7 @@ class boss_nalorakk : public CreatureScript
|
||||
case 0:
|
||||
if (me->IsWithinDistInMap(who, 50))
|
||||
{
|
||||
me->MonsterYell(YELL_NALORAKK_WAVE1, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_NALORAKK_WAVE1);
|
||||
Talk(SAY_WAVE1);
|
||||
|
||||
(*me).GetMotionMaster()->MovePoint(1, NalorakkWay[1][0], NalorakkWay[1][1], NalorakkWay[1][2]);
|
||||
MovePhase ++;
|
||||
@@ -249,8 +231,7 @@ class boss_nalorakk : public CreatureScript
|
||||
case 2:
|
||||
if (me->IsWithinDistInMap(who, 40))
|
||||
{
|
||||
me->MonsterYell(YELL_NALORAKK_WAVE2, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_NALORAKK_WAVE2);
|
||||
Talk(SAY_WAVE2);
|
||||
|
||||
(*me).GetMotionMaster()->MovePoint(3, NalorakkWay[3][0], NalorakkWay[3][1], NalorakkWay[3][2]);
|
||||
MovePhase ++;
|
||||
@@ -262,8 +243,7 @@ class boss_nalorakk : public CreatureScript
|
||||
case 5:
|
||||
if (me->IsWithinDistInMap(who, 40))
|
||||
{
|
||||
me->MonsterYell(YELL_NALORAKK_WAVE3, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_NALORAKK_WAVE3);
|
||||
Talk(SAY_WAVE3);
|
||||
|
||||
(*me).GetMotionMaster()->MovePoint(6, NalorakkWay[6][0], NalorakkWay[6][1], NalorakkWay[6][2]);
|
||||
MovePhase ++;
|
||||
@@ -277,8 +257,7 @@ class boss_nalorakk : public CreatureScript
|
||||
{
|
||||
SendAttacker(who);
|
||||
|
||||
me->MonsterYell(YELL_NALORAKK_WAVE4, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_NALORAKK_WAVE4);
|
||||
Talk(SAY_WAVE4);
|
||||
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
@@ -292,43 +271,39 @@ class boss_nalorakk : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
void EnterCombat(Unit* /*who*/) override
|
||||
{
|
||||
if (instance)
|
||||
instance->SetData(DATA_NALORAKKEVENT, IN_PROGRESS);
|
||||
|
||||
me->MonsterYell(YELL_AGGRO, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_AGGRO);
|
||||
Talk(SAY_AGGRO);
|
||||
DoZoneInCombat();
|
||||
}
|
||||
|
||||
void JustDied(Unit* /*killer*/)
|
||||
void JustDied(Unit* /*killer*/) override
|
||||
{
|
||||
ResetMobs();
|
||||
|
||||
if (instance)
|
||||
instance->SetData(DATA_NALORAKKEVENT, DONE);
|
||||
|
||||
me->MonsterYell(YELL_DEATH, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_DEATH);
|
||||
Talk(SAY_DEATH);
|
||||
}
|
||||
|
||||
void KilledUnit(Unit* /*victim*/)
|
||||
void KilledUnit(Unit* /*victim*/) override
|
||||
{
|
||||
switch (urand(0, 1))
|
||||
{
|
||||
case 0:
|
||||
me->MonsterYell(YELL_KILL_ONE, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_KILL_ONE);
|
||||
Talk(SAY_KILL_ONE);
|
||||
break;
|
||||
case 1:
|
||||
me->MonsterYell(YELL_KILL_TWO, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_KILL_TWO);
|
||||
Talk(SAY_KILL_TWO);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void MovementInform(uint32 type, uint32 id)
|
||||
void MovementInform(uint32 type, uint32 id) override
|
||||
{
|
||||
if (MoveEvent)
|
||||
{
|
||||
@@ -368,7 +343,7 @@ class boss_nalorakk : public CreatureScript
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff)
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
if (waitTimer && inMove)
|
||||
{
|
||||
@@ -386,8 +361,7 @@ class boss_nalorakk : public CreatureScript
|
||||
if (Berserk_Timer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_BERSERK, true);
|
||||
me->MonsterYell(YELL_BERSERK, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_BERSERK);
|
||||
Talk(SAY_BERSERK);
|
||||
Berserk_Timer = 600000;
|
||||
} else Berserk_Timer -= diff;
|
||||
|
||||
@@ -396,8 +370,7 @@ class boss_nalorakk : public CreatureScript
|
||||
if (inBearForm)
|
||||
{
|
||||
// me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 1, 5122);
|
||||
me->MonsterYell(YELL_SHIFTEDTOTROLL, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_TOTROLL);
|
||||
Talk(SAY_SHIFTEDTOTROLL);
|
||||
me->RemoveAurasDueToSpell(SPELL_BEARFORM);
|
||||
Surge_Timer = urand(15000, 20000);
|
||||
BrutalSwipe_Timer = urand(7000, 12000);
|
||||
@@ -408,8 +381,7 @@ class boss_nalorakk : public CreatureScript
|
||||
else
|
||||
{
|
||||
// me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 1, 0);
|
||||
me->MonsterYell(YELL_SHIFTEDTOBEAR, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_TOBEAR);
|
||||
Talk(SAY_SHIFTEDTOBEAR);
|
||||
DoCast(me, SPELL_BEARFORM, true);
|
||||
LaceratingSlash_Timer = 2000; // dur 18s
|
||||
RendFlesh_Timer = 3000; // dur 5s
|
||||
@@ -439,8 +411,7 @@ class boss_nalorakk : public CreatureScript
|
||||
|
||||
if (Surge_Timer <= diff)
|
||||
{
|
||||
me->MonsterYell(YELL_SURGE, LANG_UNIVERSAL, NULL);
|
||||
DoPlaySoundToSet(me, SOUND_YELL_SURGE);
|
||||
Talk(SAY_SURGE);
|
||||
Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 1, 45, true);
|
||||
if (target)
|
||||
DoCast(target, SPELL_SURGE);
|
||||
@@ -472,7 +443,7 @@ class boss_nalorakk : public CreatureScript
|
||||
}
|
||||
};
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return GetInstanceAI<boss_nalorakkAI>(creature);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user