diff options
author | Gacko <gacko28@gmx.de> | 2012-11-23 16:25:59 +0100 |
---|---|---|
committer | Gacko <gacko28@gmx.de> | 2012-11-23 16:25:59 +0100 |
commit | 4065176897b43c34cbc652ff334d311d402577ea (patch) | |
tree | a6609872b725f3542775cda990a5b7a20e7b1ec5 /src | |
parent | 27619b2bd711d03b2b641af9fa6e5d4b8969d0fb (diff) |
Core/DB: Convert 14 more scripts to creature text
Diffstat (limited to 'src')
14 files changed, 224 insertions, 210 deletions
diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp index fdb6a5da320..af61c723ca3 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp @@ -22,8 +22,8 @@ enum Yells { YELL_AGGRO = 0, YELL_EVADE = 1, - YELL_RESPAWN1 = -1810010, // no creature_text - YELL_RESPAWN2 = -1810011, // no creature_text + //YELL_RESPAWN1 = -1810010, // Missing in database + //YELL_RESPAWN2 = -1810011, // Missing in database YELL_RANDOM = 2, YELL_SPELL = 3, }; @@ -64,12 +64,6 @@ public: Talk(YELL_AGGRO); } - void JustRespawned() - { - Reset(); - DoScriptText(RAND(YELL_RESPAWN1, YELL_RESPAWN2), me); - } - void UpdateAI(const uint32 diff) { if (!UpdateVictim()) diff --git a/src/server/scripts/EasternKingdoms/BlackrockDepths/blackrock_depths.cpp b/src/server/scripts/EasternKingdoms/BlackrockDepths/blackrock_depths.cpp index b5283900eb0..5b5787b2ab8 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockDepths/blackrock_depths.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockDepths/blackrock_depths.cpp @@ -101,12 +101,12 @@ public: // npc_grimstone enum GrimstoneTexts { - SCRIPT_TEXT1 = -1230003, - SCRIPT_TEXT2 = -1230004, - SCRIPT_TEXT3 = -1230005, - SCRIPT_TEXT4 = -1230006, - SCRIPT_TEXT5 = -1230007, - SCRIPT_TEXT6 = -1230008 + SAY_TEXT1 = 0, + SAY_TEXT2 = 1, + SAY_TEXT3 = 2, + SAY_TEXT4 = 3, + SAY_TEXT5 = 4, + SAY_TEXT6 = 5 }; //TODO: implement quest part of event (different end boss) @@ -186,12 +186,12 @@ public: switch (waypointId) { case 0: - DoScriptText(SCRIPT_TEXT1, me);//2 + Talk(SAY_TEXT1); CanWalk = false; Event_Timer = 5000; break; case 1: - DoScriptText(SCRIPT_TEXT2, me);//4 + Talk(SAY_TEXT2); CanWalk = false; Event_Timer = 5000; break; @@ -199,10 +199,10 @@ public: CanWalk = false; break; case 3: - DoScriptText(SCRIPT_TEXT3, me);//5 + Talk(SAY_TEXT3); break; case 4: - DoScriptText(SCRIPT_TEXT4, me);//6 + Talk(SAY_TEXT4); CanWalk = false; Event_Timer = 5000; break; @@ -272,7 +272,7 @@ public: switch (EventPhase) { case 0: - DoScriptText(SCRIPT_TEXT5, me);//1 + Talk(SAY_TEXT5); HandleGameObject(DATA_ARENA4, false); Start(false, false); CanWalk = true; @@ -307,7 +307,7 @@ public: case 7: me->SetVisible(true); HandleGameObject(DATA_ARENA1, false); - DoScriptText(SCRIPT_TEXT6, me);//4 + Talk(SAY_TEXT6); CanWalk = true; Event_Timer = 0; break; @@ -1178,7 +1178,7 @@ public: // npc_rocknot enum RocknotSays { - SAY_GOT_BEER = -1230000 + SAY_GOT_BEER = 0 }; enum RocknotSpells @@ -1215,7 +1215,7 @@ public: //keep track of amount in instance script, returns SPECIAL if amount ok and event in progress if (instance->GetData(TYPE_BAR) == SPECIAL) { - DoScriptText(SAY_GOT_BEER, creature); + creature->AI()->Talk(SAY_GOT_BEER); creature->CastSpell(creature, SPELL_DRUNKEN_RAGE, false); if (npc_escortAI* escortAI = CAST_AI(npc_rocknot::npc_rocknotAI, creature->AI())) diff --git a/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp b/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp index 204fa3177e7..bad4d8735b7 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp @@ -22,8 +22,8 @@ enum Yells { - SAY_AGGRO = -1230001, - SAY_SLAY = -1230002 + SAY_AGGRO = 0, + SAY_SLAY = 1 }; enum Spells @@ -63,13 +63,13 @@ public: void EnterCombat(Unit* /*who*/) { - DoScriptText(SAY_AGGRO, me); + Talk(SAY_AGGRO); me->CallForHelp(VISIBLE_RANGE); } void KilledUnit(Unit* /*victim*/) { - DoScriptText(SAY_SLAY, me); + Talk(SAY_SLAY); } void JustDied(Unit* /*killer*/) diff --git a/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_grizzle.cpp b/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_grizzle.cpp index 40f8b2507e3..2aab7739d8d 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_grizzle.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockDepths/boss_grizzle.cpp @@ -19,10 +19,11 @@ #include "ScriptMgr.h" #include "ScriptedCreature.h" -enum Spells +enum Grizzle { - SPELL_GROUNDTREMOR = 6524, - SPELL_FRENZY = 28371 + SPELL_GROUNDTREMOR = 6524, + SPELL_FRENZY = 28371, + EMOTE_FRENZY_KILL = 0 }; class boss_grizzle : public CreatureScript @@ -69,7 +70,7 @@ public: if (Frenzy_Timer <= diff) { DoCast(me, SPELL_FRENZY); - DoScriptText(EMOTE_GENERIC_FRENZY_KILL, me); + Talk(EMOTE_FRENZY_KILL); Frenzy_Timer = 15000; } else Frenzy_Timer -= diff; diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp index eec520f04e2..22a26fd4389 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp @@ -29,45 +29,55 @@ EndScriptData */ #include "WorldPacket.h" #include "Opcodes.h" -#define SAY_AGGRO -1585023 //This yell should be done when the room is cleared. For now, set it as a movelineofsight yell. -#define SAY_PHOENIX -1585024 -#define SAY_FLAMESTRIKE -1585025 -#define SAY_GRAVITY_LAPSE -1585026 -#define SAY_TIRED -1585027 -#define SAY_RECAST_GRAVITY -1585028 -#define SAY_DEATH -1585029 +enum Says +{ + SAY_AGGRO = 0, //This yell should be done when the room is cleared. For now, set it as a movelineofsight yell. + SAY_PHOENIX = 1, + SAY_FLAMESTRIKE = 2, + SAY_GRAVITY_LAPSE = 3, + SAY_TIRED = 4, + SAY_RECAST_GRAVITY = 5, + SAY_DEATH = 6 +}; -/*** Spells ***/ -// Phase 1 spells -#define SPELL_FIREBALL_NORMAL 44189 // Deals 2700-3300 damage at current target -#define SPELL_FIREBALL_HEROIC 46164 // 4950-6050 +enum Spells +{ + // Phase 1 spells + SPELL_FIREBALL_NORMAL = 44189, // Deals 2700-3300 damage at current target + SPELL_FIREBALL_HEROIC = 46164, // 4950-6050 -#define SPELL_PHOENIX 44194 // Summons a phoenix (Doesn't work?) -#define SPELL_PHOENIX_BURN 44197 // A spell Phoenix uses to damage everything around -#define SPELL_REBIRTH_DMG 44196 // DMG if a Phoenix rebirth happen + SPELL_PHOENIX = 44194, // Summons a phoenix (Doesn't work?) + SPELL_PHOENIX_BURN = 44197, // A spell Phoenix uses to damage everything around + SPELL_REBIRTH_DMG = 44196, // DMG if a Phoenix rebirth happen -#define SPELL_FLAMESTRIKE1_NORMAL 44190 // Damage part -#define SPELL_FLAMESTRIKE1_HEROIC 46163 // Heroic damage part -#define SPELL_FLAMESTRIKE2 44191 // Flamestrike indicator before the damage -#define SPELL_FLAMESTRIKE3 44192 // Summons the trigger + animation (projectile) + SPELL_FLAMESTRIKE1_NORMAL = 44190, // Damage part + SPELL_FLAMESTRIKE1_HEROIC = 46163, // Heroic damage part + SPELL_FLAMESTRIKE2 = 44191, // Flamestrike indicator before the damage + SPELL_FLAMESTRIKE3 = 44192, // Summons the trigger + animation (projectile) -#define SPELL_SHOCK_BARRIER 46165 // Heroic only; 10k damage shield, followed by Pyroblast -#define SPELL_PYROBLAST 36819 // Heroic only; 45-55k fire damage + SPELL_SHOCK_BARRIER = 46165, // Heroic only; 10k damage shield, followed by Pyroblast + SPELL_PYROBLAST = 36819, // Heroic only; 45-55k fire damage // Phase 2 spells -#define SPELL_GRAVITY_LAPSE_INITIAL 44224 // Cast at the beginning of every Gravity Lapse -#define SPELL_GRAVITY_LAPSE_CHANNEL 44251 // Channeled; blue beam animation to every enemy in range -#define SPELL_TELEPORT_CENTER 44218 // Should teleport people to the center. Requires DB entry in spell_target_position. -#define SPELL_GRAVITY_LAPSE_FLY 44227 // Hastens flyspeed and allows flying for 1 minute. For some reason removes 44226. -#define SPELL_GRAVITY_LAPSE_DOT 44226 // Knocks up in the air and applies a 300 DPS DoT. -#define SPELL_ARCANE_SPHERE_PASSIVE 44263 // Passive auras on Arcane Spheres -#define SPELL_POWER_FEEDBACK 44233 // Stuns him, making him take 50% more damage for 10 seconds. Cast after Gravity Lapse - -/*** Creatures ***/ -#define CREATURE_PHOENIX 24674 -#define CREATURE_PHOENIX_EGG 24675 -#define CREATURE_ARCANE_SPHERE 24708 + SPELL_GRAVITY_LAPSE_INITIAL = 44224, // Cast at the beginning of every Gravity Lapse + SPELL_GRAVITY_LAPSE_CHANNEL = 44251, // Channeled; blue beam animation to every enemy in range + SPELL_TELEPORT_CENTER = 44218, // Should teleport people to the center. Requires DB entry in spell_target_position. + SPELL_GRAVITY_LAPSE_FLY = 44227, // Hastens flyspeed and allows flying for 1 minute. For some reason removes 44226. + SPELL_GRAVITY_LAPSE_DOT = 44226, // Knocks up in the air and applies a 300 DPS DoT. + SPELL_ARCANE_SPHERE_PASSIVE = 44263, // Passive auras on Arcane Spheres + SPELL_POWER_FEEDBACK = 44233 // Stuns him, making him take 50% more damage for 10 seconds. Cast after Gravity Lapse +}; + + + +enum Creatures +{ + CREATURE_PHOENIX = 24674, + CREATURE_PHOENIX_EGG = 24675, + CREATURE_ARCANE_SPHERE = 24708 +}; + /** Locations **/ float KaelLocations[3][2]= @@ -146,7 +156,7 @@ public: void JustDied(Unit* /*killer*/) { - DoScriptText(SAY_DEATH, me); + Talk(SAY_DEATH); if (!instance) return; @@ -176,7 +186,7 @@ public: { if (!HasTaunted && me->IsWithinDistInMap(who, 40.0f)) { - DoScriptText(SAY_AGGRO, me); + Talk(SAY_AGGRO); HasTaunted = true; } @@ -315,7 +325,7 @@ public: Phoenix->AI()->AttackStart(target); } - DoScriptText(SAY_PHOENIX, me); + Talk(SAY_PHOENIX); PhoenixTimer = 60000; } else PhoenixTimer -= diff; @@ -327,7 +337,7 @@ public: me->InterruptSpell(CURRENT_CHANNELED_SPELL); me->InterruptSpell(CURRENT_GENERIC_SPELL); DoCast(target, SPELL_FLAMESTRIKE3, true); - DoScriptText(SAY_FLAMESTRIKE, me); + Talk(SAY_FLAMESTRIKE); } FlameStrikeTimer = urand(15000, 25000); } else FlameStrikeTimer -= diff; @@ -357,14 +367,14 @@ public: case 0: if (FirstGravityLapse) // Different yells at 50%, and at every following Gravity Lapse { - DoScriptText(SAY_GRAVITY_LAPSE, me); + Talk(SAY_GRAVITY_LAPSE); FirstGravityLapse = false; if (instance) instance->SetData(DATA_KAELTHAS_STATUES, 1); } else - DoScriptText(SAY_RECAST_GRAVITY, me); + Talk(SAY_RECAST_GRAVITY); DoCast(me, SPELL_GRAVITY_LAPSE_INITIAL); GravityLapseTimer = 2000 + diff;// Don't interrupt the visual spell @@ -407,7 +417,7 @@ public: case 4: me->InterruptNonMeleeSpells(false); - DoScriptText(SAY_TIRED, me); + Talk(SAY_TIRED); DoCast(me, SPELL_POWER_FEEDBACK); RemoveGravityLapse(); GravityLapseTimer = 10000; diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp index 2af417381a5..b2cf2336024 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp @@ -34,25 +34,25 @@ struct Speech static Speech LackeyDeath[]= { - {-1585013}, - {-1585014}, - {-1585015}, - {-1585016}, + {1}, + {2}, + {3}, + {4}, }; static Speech PlayerDeath[]= { - {-1585017}, - {-1585018}, - {-1585019}, - {-1585020}, - {-1585021}, + {5}, + {6}, + {7}, + {8}, + {9}, }; enum eEnums { - SAY_AGGRO = -1585012, - SAY_DEATH = -1585022, + SAY_AGGRO = 0, + SAY_DEATH = 10, SPELL_DISPEL_MAGIC = 27609, SPELL_FLASH_HEAL = 17843, @@ -144,7 +144,7 @@ public: void EnterCombat(Unit* who) { - DoScriptText(SAY_AGGRO, me); + Talk(SAY_AGGRO); for (uint8 i = 0; i < MAX_ACTIVE_LACKEY; ++i) { @@ -216,7 +216,7 @@ public: if (victim->GetTypeId() != TYPEID_PLAYER) return; - DoScriptText(PlayerDeath[PlayersKilled].id, me); + Talk(PlayerDeath[PlayersKilled].id); if (PlayersKilled < 4) ++PlayersKilled; @@ -224,7 +224,7 @@ public: void JustDied(Unit* /*killer*/) { - DoScriptText(SAY_DEATH, me); + Talk(SAY_DEATH); if (!instance) return; @@ -415,7 +415,7 @@ struct boss_priestess_lackey_commonAI : public ScriptedAI return; //should delrissa really yell if dead? - DoScriptText(LackeyDeath[uiLackeyDeathCount].id, pDelrissa); + pDelrissa->AI()->Talk(LackeyDeath[uiLackeyDeathCount].id); instance->SetData(DATA_DELRISSA_DEATH_COUNT, SPECIAL); diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp index 7b79c18239e..4d9bd1f2192 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp @@ -27,30 +27,37 @@ EndScriptData */ #include "ScriptedCreature.h" #include "magisters_terrace.h" -#define SAY_AGGRO -1585000 -#define SAY_ENERGY -1585001 -#define SAY_EMPOWERED -1585002 -#define SAY_KILL_1 -1585003 -#define SAY_KILL_2 -1585004 -#define SAY_DEATH -1585005 -#define EMOTE_CRYSTAL -1585006 - -//Crystal effect spells -#define SPELL_FEL_CRYSTAL_COSMETIC 44374 -#define SPELL_FEL_CRYSTAL_DUMMY 44329 -#define SPELL_FEL_CRYSTAL_VISUAL 44355 -#define SPELL_MANA_RAGE 44320 // This spell triggers 44321, which changes scale and regens mana Requires an entry in spell_script_target +enum Says +{ + SAY_AGGRO = 0, + SAY_ENERGY = 1, + SAY_EMPOWERED = 2, + SAY_KILL = 3, + SAY_DEATH = 4, + EMOTE_CRYSTAL = 5 +}; -//Selin's spells -#define SPELL_DRAIN_LIFE 44294 -#define SPELL_FEL_EXPLOSION 44314 +enum Spells +{ + //Crystal effect spells + SPELL_FEL_CRYSTAL_COSMETIC = 44374, + SPELL_FEL_CRYSTAL_DUMMY = 44329, + SPELL_FEL_CRYSTAL_VISUAL = 44355, + SPELL_MANA_RAGE = 44320, // This spell triggers 44321, which changes scale and regens mana Requires an entry in spell_script_target -#define SPELL_DRAIN_MANA 46153 // Heroic only + //Selin's spells + SPELL_DRAIN_LIFE = 44294, + SPELL_FEL_EXPLOSION = 44314, -#define CRYSTALS_NUMBER 5 -#define DATA_CRYSTALS 6 + SPELL_DRAIN_MANA = 46153 // Heroic only +}; -#define CREATURE_FEL_CRYSTAL 24722 +enum Misc +{ + CRYSTALS_NUMBER = 5, + DATA_CRYSTALS = 6, + CREATURE_FEL_CRYSTAL = 24722 +}; class boss_selin_fireheart : public CreatureScript { @@ -161,8 +168,8 @@ public: } if (CrystalChosen) { - DoScriptText(SAY_ENERGY, me); - DoScriptText(EMOTE_CRYSTAL, me); + Talk(SAY_ENERGY); + Talk(EMOTE_CRYSTAL); CrystalChosen->CastSpell(CrystalChosen, SPELL_FEL_CRYSTAL_COSMETIC, true); @@ -192,14 +199,14 @@ public: void EnterCombat(Unit* /*who*/) { - DoScriptText(SAY_AGGRO, me); + Talk(SAY_AGGRO); if (instance) instance->SetData(DATA_SELIN_EVENT, IN_PROGRESS); } void KilledUnit(Unit* /*victim*/) { - DoScriptText(RAND(SAY_KILL_1, SAY_KILL_2), me); + Talk(SAY_KILL); } void MovementInform(uint32 type, uint32 id) @@ -226,7 +233,7 @@ public: void JustDied(Unit* /*killer*/) { - DoScriptText(SAY_DEATH, me); + Talk(SAY_DEATH); if (!instance) return; @@ -293,7 +300,7 @@ public: IsDraining = false; DrainingCrystal = false; - DoScriptText(SAY_EMPOWERED, me); + Talk(SAY_EMPOWERED); Unit* CrystalChosen = Unit::GetUnit(*me, CrystalGUID); if (CrystalChosen && CrystalChosen->isAlive()) diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp index 34682683ee3..31821623878 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp @@ -29,11 +29,11 @@ EndScriptData */ enum eEnums { - SAY_AGGRO = -1585007, - SAY_ENERGY = -1585008, - SAY_OVERLOAD = -1585009, - SAY_KILL = -1585010, - EMOTE_DISCHARGE_ENERGY = -1585011, + SAY_AGGRO = 0, + SAY_ENERGY = 1, + SAY_OVERLOAD = 2, + SAY_KILL = 3, + EMOTE_DISCHARGE_ENERGY = 4, //is this text for real? //#define SAY_DEATH "What...happen...ed." @@ -99,7 +99,7 @@ public: void KilledUnit(Unit* /*victim*/) { - DoScriptText(SAY_KILL, me); + Talk(SAY_KILL); } void JustDied(Unit* /*killer*/) @@ -110,7 +110,7 @@ public: void EnterCombat(Unit* /*who*/) { - DoScriptText(SAY_AGGRO, me); + Talk(SAY_AGGRO); if (instance) instance->SetData(DATA_VEXALLUS_EVENT, IN_PROGRESS); @@ -144,8 +144,8 @@ public: else ++IntervalHealthAmount; - DoScriptText(SAY_ENERGY, me); - DoScriptText(EMOTE_DISCHARGE_ENERGY, me); + Talk(SAY_ENERGY); + Talk(EMOTE_DISCHARGE_ENERGY); if (IsHeroic()) { diff --git a/src/server/scripts/EasternKingdoms/MoltenCore/boss_golemagg.cpp b/src/server/scripts/EasternKingdoms/MoltenCore/boss_golemagg.cpp index fa99078cedb..5e5cc0ffab8 100644 --- a/src/server/scripts/EasternKingdoms/MoltenCore/boss_golemagg.cpp +++ b/src/server/scripts/EasternKingdoms/MoltenCore/boss_golemagg.cpp @@ -30,7 +30,7 @@ EndScriptData */ enum Texts { - EMOTE_LOWHP = -1409002, + EMOTE_LOWHP = 0, }; enum Spells @@ -149,7 +149,7 @@ class mob_core_rager : public CreatureScript if (pGolemagg->isAlive()) { me->AddAura(SPELL_GOLEMAGG_TRUST, me); - DoScriptText(EMOTE_LOWHP, me); + Talk(EMOTE_LOWHP); me->SetFullHealth(); } } diff --git a/src/server/scripts/EasternKingdoms/MoltenCore/boss_ragnaros.cpp b/src/server/scripts/EasternKingdoms/MoltenCore/boss_ragnaros.cpp index 9d48d04cf07..edd8905ff4a 100644 --- a/src/server/scripts/EasternKingdoms/MoltenCore/boss_ragnaros.cpp +++ b/src/server/scripts/EasternKingdoms/MoltenCore/boss_ragnaros.cpp @@ -29,17 +29,17 @@ EndScriptData */ enum Texts { - SAY_REINFORCEMENTS1 = -1409013, - SAY_REINFORCEMENTS2 = -1409014, - SAY_HAND = -1409015, - SAY_WRATH = -1409016, - SAY_KILL = -1409017, - SAY_MAGMABURST = -1409018, - SAY_SUMMON_MAJ = -1409008, - SAY_ARRIVAL1_RAG = -1409009, - SAY_ARRIVAL2_MAJ = -1409010, - SAY_ARRIVAL3_RAG = -1409011, - SAY_ARRIVAL5_RAG = -1409012, + SAY_SUMMON_MAJ = 0, + SAY_ARRIVAL1_RAG = 1, + SAY_ARRIVAL2_MAJ = 2, + SAY_ARRIVAL3_RAG = 3, + SAY_ARRIVAL5_RAG = 4, + SAY_REINFORCEMENTS1 = 5, + SAY_REINFORCEMENTS2 = 6, + SAY_HAND = 7, + SAY_WRATH = 8, + SAY_KILL = 9, + SAY_MAGMABURST = 10 }; enum Spells @@ -112,7 +112,7 @@ class boss_ragnaros : public CreatureScript void KilledUnit(Unit* /*victim*/) { if (urand(0, 99) < 25) - DoScriptText(SAY_KILL, me); + Talk(SAY_KILL); } void UpdateAI(const uint32 diff) @@ -137,16 +137,16 @@ class boss_ragnaros : public CreatureScript switch (eventId) { case EVENT_INTRO_1: - DoScriptText(SAY_ARRIVAL1_RAG, me); + Talk(SAY_ARRIVAL1_RAG); break; case EVENT_INTRO_2: - DoScriptText(SAY_ARRIVAL3_RAG, me); + Talk(SAY_ARRIVAL3_RAG); break; case EVENT_INTRO_3: me->HandleEmoteCommand(EMOTE_ONESHOT_ATTACK1H); break; case EVENT_INTRO_4: - DoScriptText(SAY_ARRIVAL5_RAG, me); + Talk(SAY_ARRIVAL5_RAG); if (instance) if (Creature* executus = Unit::GetCreature(*me, instance->GetData64(BOSS_MAJORDOMO_EXECUTUS))) me->Kill(executus); @@ -205,13 +205,13 @@ class boss_ragnaros : public CreatureScript case EVENT_WRATH_OF_RAGNAROS: DoCastVictim(SPELL_WRATH_OF_RAGNAROS); if (urand(0, 1)) - DoScriptText(SAY_WRATH, me); + Talk(SAY_WRATH); events.ScheduleEvent(EVENT_WRATH_OF_RAGNAROS, 25000); break; case EVENT_HAND_OF_RAGNAROS: DoCast(me, SPELL_HAND_OF_RAGNAROS); if (urand(0, 1)) - DoScriptText(SAY_HAND, me); + Talk(SAY_HAND); events.ScheduleEvent(EVENT_HAND_OF_RAGNAROS, 20000); break; case EVENT_LAVA_BURST: @@ -229,7 +229,7 @@ class boss_ragnaros : public CreatureScript if (!_hasYelledMagmaBurst) { //Say our dialog - DoScriptText(SAY_MAGMABURST, me); + Talk(SAY_MAGMABURST); _hasYelledMagmaBurst = true; } } @@ -256,7 +256,7 @@ class boss_ragnaros : public CreatureScript if (!_hasSubmergedOnce) { - DoScriptText(SAY_REINFORCEMENTS1, me); + Talk(SAY_REINFORCEMENTS1); // summon 8 elementals for (uint8 i = 0; i < 8; ++i) @@ -272,7 +272,7 @@ class boss_ragnaros : public CreatureScript } else { - DoScriptText(SAY_REINFORCEMENTS2, me); + Talk(SAY_REINFORCEMENTS2); for (uint8 i = 0; i < 8; ++i) if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0)) diff --git a/src/server/scripts/EasternKingdoms/ghostlands.cpp b/src/server/scripts/EasternKingdoms/ghostlands.cpp index 5d97735ab5d..ddd3b0f423a 100644 --- a/src/server/scripts/EasternKingdoms/ghostlands.cpp +++ b/src/server/scripts/EasternKingdoms/ghostlands.cpp @@ -111,18 +111,18 @@ public: enum eEnums { - SAY_START = -1000140, - SAY_PROGRESS1 = -1000141, - SAY_PROGRESS2 = -1000142, - SAY_PROGRESS3 = -1000143, - SAY_END1 = -1000144, - SAY_END2 = -1000145, - SAY_CAPTAIN_ANSWER = -1000146, + SAY_START = 0, + SAY_PROGRESS1 = 1, + SAY_PROGRESS2 = 2, + SAY_PROGRESS3 = 3, + SAY_END1 = 4, + SAY_END2 = 5, + SAY_CAPTAIN_ANSWER = 0, QUEST_ESCAPE_FROM_THE_CATACOMBS = 9212, - GO_CAGE = 181152, - NPC_CAPTAIN_HELIOS = 16220, - FACTION_SMOON_E = 1603, + GO_CAGE = 181152, + NPC_CAPTAIN_HELIOS = 16220, + FACTION_SMOON_E = 1603 }; class npc_ranger_lilatha : public CreatureScript @@ -146,18 +146,18 @@ public: me->SetUInt32Value(UNIT_FIELD_BYTES_1, 0); if (GameObject* Cage = me->FindNearestGameObject(GO_CAGE, 20)) Cage->SetGoState(GO_STATE_ACTIVE); - DoScriptText(SAY_START, me, player); + Talk(SAY_START, player->GetGUID()); break; case 5: - DoScriptText(SAY_PROGRESS1, me, player); + Talk(SAY_PROGRESS1, player->GetGUID()); break; case 11: - DoScriptText(SAY_PROGRESS2, me, player); + Talk(SAY_PROGRESS2, player->GetGUID()); me->SetOrientation(4.762841f); break; case 18: { - DoScriptText(SAY_PROGRESS3, me, player); + Talk(SAY_PROGRESS3, player->GetGUID()); Creature* Summ1 = me->SummonCreature(16342, 7627.083984f, -7532.538086f, 152.128616f, 1.082733f, TEMPSUMMON_DEAD_DESPAWN, 0); Creature* Summ2 = me->SummonCreature(16343, 7620.432129f, -7532.550293f, 152.454865f, 0.827478f, TEMPSUMMON_DEAD_DESPAWN, 0); if (Summ1 && Summ2) @@ -180,14 +180,14 @@ public: break; case 32: me->SetOrientation(2.978281f); - DoScriptText(SAY_END1, me, player); + Talk(SAY_END1, player->GetGUID()); break; case 33: me->SetOrientation(5.858011f); - DoScriptText(SAY_END2, me, player); - Unit* CaptainHelios = me->FindNearestCreature(NPC_CAPTAIN_HELIOS, 50); + Talk(SAY_END2, player->GetGUID()); + Creature* CaptainHelios = me->FindNearestCreature(NPC_CAPTAIN_HELIOS, 50); if (CaptainHelios) - DoScriptText(SAY_CAPTAIN_ANSWER, CaptainHelios, player); + CaptainHelios->AI()->Talk(SAY_CAPTAIN_ANSWER, player->GetGUID()); break; } } diff --git a/src/server/scripts/EasternKingdoms/silvermoon_city.cpp b/src/server/scripts/EasternKingdoms/silvermoon_city.cpp index 28af25d39de..d8e9a9ae49a 100644 --- a/src/server/scripts/EasternKingdoms/silvermoon_city.cpp +++ b/src/server/scripts/EasternKingdoms/silvermoon_city.cpp @@ -37,7 +37,7 @@ EndContentData */ #######*/ enum eStillbladeData { - SAY_HEAL = -1000193, + SAY_HEAL = 0, QUEST_REDEEMING_THE_DEAD = 9685, SPELL_SHIMMERING_VESSEL = 31225, @@ -98,7 +98,7 @@ public: me->SetStandState(UNIT_STAND_STATE_STAND); me->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 0); //me->RemoveAllAuras(); - DoScriptText(SAY_HEAL, me); + Talk(SAY_HEAL); spellHit = true; } } diff --git a/src/server/scripts/EasternKingdoms/stormwind_city.cpp b/src/server/scripts/EasternKingdoms/stormwind_city.cpp index 188f2c77fa1..188b3dcd2b1 100644 --- a/src/server/scripts/EasternKingdoms/stormwind_city.cpp +++ b/src/server/scripts/EasternKingdoms/stormwind_city.cpp @@ -206,13 +206,13 @@ public: enum eLordGregorLescovar { - SAY_LESCOVAR_2 = -1000457, - SAY_GUARD_2 = -1000458, - SAY_LESCOVAR_3 = -1000459, - SAY_MARZON_1 = -1000460, - SAY_LESCOVAR_4 = -1000461, - SAY_TYRION_2 = -1000462, - SAY_MARZON_2 = -1000463, + SAY_GUARD_2 = 0, + SAY_LESCOVAR_2 = 0, + SAY_LESCOVAR_3 = 1, + SAY_LESCOVAR_4 = 2, + SAY_MARZON_1 = 0, + SAY_MARZON_2 = 1, + SAY_TYRION_2 = 0, NPC_STORMWIND_ROYAL = 1756, NPC_MARZON_BLADE = 1755, @@ -277,7 +277,7 @@ public: { case 14: SetEscortPaused(true); - DoScriptText(SAY_LESCOVAR_2, me); + Talk(SAY_LESCOVAR_2); uiTimer = 3000; uiPhase = 1; break; @@ -318,7 +318,7 @@ public: { case 1: if (Creature* pGuard = me->FindNearestCreature(NPC_STORMWIND_ROYAL, 8.0f, true)) - DoScriptText(SAY_GUARD_2, pGuard); + pGuard->AI()->Talk(SAY_GUARD_2); uiTimer = 3000; uiPhase = 2; break; @@ -333,18 +333,18 @@ public: uiPhase = 0; break; case 4: - DoScriptText(SAY_LESCOVAR_3, me); + Talk(SAY_LESCOVAR_3); uiTimer = 0; uiPhase = 0; break; case 5: if (Creature* pMarzon = Unit::GetCreature(*me, MarzonGUID)) - DoScriptText(SAY_MARZON_1, pMarzon); + pMarzon->AI()->Talk(SAY_MARZON_1); uiTimer = 3000; uiPhase = 6; break; case 6: - DoScriptText(SAY_LESCOVAR_4, me); + Talk(SAY_LESCOVAR_4); if (Player* player = GetPlayerForEscort()) player->AreaExploredOrEventHappens(QUEST_THE_ATTACK); uiTimer = 2000; @@ -352,7 +352,7 @@ public: break; case 7: if (Creature* pTyrion = me->FindNearestCreature(NPC_TYRION, 20.0f, true)) - DoScriptText(SAY_TYRION_2, pTyrion); + pTyrion->AI()->Talk(SAY_TYRION_2); if (Creature* pMarzon = Unit::GetCreature(*me, MarzonGUID)) pMarzon->setFaction(14); me->setFaction(14); @@ -400,7 +400,7 @@ public: void EnterCombat(Unit* who) { - DoScriptText(SAY_MARZON_2, me); + Talk(SAY_MARZON_2); if (me->isSummon()) { @@ -464,14 +464,14 @@ public: enum eTyrionSpybot { - SAY_QUEST_ACCEPT_ATTACK = -1000499, - SAY_TYRION_1 = -1000450, - SAY_SPYBOT_1 = -1000451, - SAY_GUARD_1 = -1000452, - SAY_SPYBOT_2 = -1000453, - SAY_SPYBOT_3 = -1000454, - SAY_LESCOVAR_1 = -1000455, - SAY_SPYBOT_4 = -1000456, + SAY_QUEST_ACCEPT_ATTACK = 0, + SAY_SPYBOT_1 = 1, + SAY_SPYBOT_2 = 2, + SAY_SPYBOT_3 = 3, + SAY_SPYBOT_4 = 4, + SAY_TYRION_1 = 0, + SAY_GUARD_1 = 0, + SAY_LESCOVAR_1 = 0, NPC_PRIESTESS_TYRIONA = 7779, NPC_LORD_GREGOR_LESCOVAR = 1754, @@ -511,13 +511,13 @@ public: break; case 5: SetEscortPaused(true); - DoScriptText(SAY_SPYBOT_1, me); + Talk(SAY_SPYBOT_1); uiTimer = 2000; uiPhase = 5; break; case 17: SetEscortPaused(true); - DoScriptText(SAY_SPYBOT_3, me); + Talk(SAY_SPYBOT_3); uiTimer = 3000; uiPhase = 8; break; @@ -533,13 +533,13 @@ public: switch (uiPhase) { case 1: - DoScriptText(SAY_QUEST_ACCEPT_ATTACK, me); + Talk(SAY_QUEST_ACCEPT_ATTACK); uiTimer = 3000; uiPhase = 2; break; case 2: if (Creature* pTyrion = me->FindNearestCreature(NPC_TYRION, 10.0f)) - DoScriptText(SAY_TYRION_1, pTyrion); + pTyrion->AI()->Talk(SAY_TYRION_1); uiTimer = 3000; uiPhase = 3; break; @@ -555,12 +555,12 @@ public: break; case 5: if (Creature* pGuard = me->FindNearestCreature(NPC_STORMWIND_ROYAL, 10.0f, true)) - DoScriptText(SAY_GUARD_1, pGuard); + pGuard->AI()->Talk(SAY_GUARD_1); uiTimer = 3000; uiPhase = 6; break; case 6: - DoScriptText(SAY_SPYBOT_2, me); + Talk(SAY_SPYBOT_2); uiTimer = 3000; uiPhase = 7; break; @@ -571,12 +571,12 @@ public: break; case 8: if (Creature* pLescovar = me->FindNearestCreature(NPC_LORD_GREGOR_LESCOVAR, 10.0f)) - DoScriptText(SAY_LESCOVAR_1, pLescovar); + pLescovar->AI()->Talk(SAY_LESCOVAR_1); uiTimer = 3000; uiPhase = 9; break; case 9: - DoScriptText(SAY_SPYBOT_4, me); + Talk(SAY_SPYBOT_4); uiTimer = 3000; uiPhase = 10; break; diff --git a/src/server/scripts/EasternKingdoms/westfall.cpp b/src/server/scripts/EasternKingdoms/westfall.cpp index c6cf1b4361c..16ba171928c 100644 --- a/src/server/scripts/EasternKingdoms/westfall.cpp +++ b/src/server/scripts/EasternKingdoms/westfall.cpp @@ -39,11 +39,11 @@ EndContentData */ enum eEnums { - SAY_DS_START = -1000293, - SAY_DS_DOWN_1 = -1000294, - SAY_DS_DOWN_2 = -1000295, - SAY_DS_DOWN_3 = -1000296, - SAY_DS_PROLOGUE = -1000297, + SAY_DS_START = 0, + SAY_DS_DOWN_1 = 1, + SAY_DS_DOWN_2 = 2, + SAY_DS_DOWN_3 = 3, + SAY_DS_PROLOGUE = 4, SPELL_SHOOT = 6660, QUEST_TOME_VALOR = 1651, @@ -60,7 +60,7 @@ public: { if (quest->GetQuestId() == QUEST_TOME_VALOR) { - DoScriptText(SAY_DS_START, creature); + creature->AI()->Talk(SAY_DS_START); if (npc_escortAI* pEscortAI = CAST_AI(npc_daphne_stilwell::npc_daphne_stilwellAI, creature->AI())) pEscortAI->Start(true, true, player->GetGUID()); @@ -88,13 +88,13 @@ public: switch (uiWPHolder) { case 7: - DoScriptText(SAY_DS_DOWN_1, me); + Talk(SAY_DS_DOWN_1); break; case 8: - DoScriptText(SAY_DS_DOWN_2, me); + Talk(SAY_DS_DOWN_2); break; case 9: - DoScriptText(SAY_DS_DOWN_3, me); + Talk(SAY_DS_DOWN_3); break; } } @@ -143,7 +143,7 @@ public: SetRun(false); break; case 11: - DoScriptText(SAY_DS_PROLOGUE, me); + Talk(SAY_DS_PROLOGUE); break; case 13: SetEquipmentSlots(true); @@ -197,12 +197,14 @@ public: /*###### ## npc_defias_traitor ######*/ +enum DefiasSays +{ + SAY_START = 0, + SAY_PROGRESS = 1, + SAY_END = 2, + SAY_AGGRO = 3 +}; -#define SAY_START -1000101 -#define SAY_PROGRESS -1000102 -#define SAY_END -1000103 -#define SAY_AGGRO_1 -1000104 -#define SAY_AGGRO_2 -1000105 #define QUEST_DEFIAS_BROTHERHOOD 155 @@ -218,7 +220,7 @@ public: if (npc_escortAI* pEscortAI = CAST_AI(npc_defias_traitor::npc_defias_traitorAI, creature->AI())) pEscortAI->Start(true, true, player->GetGUID()); - DoScriptText(SAY_START, creature, player); + creature->AI()->Talk(SAY_START, player->GetGUID()); } return true; @@ -245,10 +247,10 @@ public: SetRun(false); break; case 36: - DoScriptText(SAY_PROGRESS, me, player); + Talk(SAY_PROGRESS, player->GetGUID()); break; case 44: - DoScriptText(SAY_END, me, player); + Talk(SAY_END, player->GetGUID()); player->GroupEventHappens(QUEST_DEFIAS_BROTHERHOOD, me); break; } @@ -256,7 +258,7 @@ public: void EnterCombat(Unit* who) { - DoScriptText(RAND(SAY_AGGRO_1, SAY_AGGRO_2), me, who); + Talk(SAY_AGGRO, who->GetGUID()); } void Reset() {} |