diff options
| author | lee <leelf_00@126.com> | 2022-03-26 06:20:01 +0800 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2022-03-26 16:12:01 +0100 |
| commit | ad30c22902a23996f805f74851aef58935c56a6e (patch) | |
| tree | 92af96eeb5cab9f79d7e1dc0fa3ed48f22531660 /src/server/scripts/Kalimdor | |
| parent | 7c8a034d82b9eda30d1a3652c9802e101e0e8033 (diff) | |
Scripts/Misc: Load some texts from DB (#27867)
(cherry picked from commit e7c02d6a9025826fc9aa47787a175e7a7b520b6d)
Diffstat (limited to 'src/server/scripts/Kalimdor')
3 files changed, 59 insertions, 41 deletions
diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp index 83c84517ad8..891db86be55 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp @@ -35,15 +35,24 @@ EndContentData */ #include "Player.h" #include "ScriptedGossip.h" -#define GOSSIP_ITEM_BEGIN_ALLY "My companions and I are with you, Lady Proudmoore." -#define GOSSIP_ITEM_ANETHERON "We are ready for whatever Archimonde might send our way, Lady Proudmoore." - -#define GOSSIP_ITEM_BEGIN_HORDE "I am with you, Thrall." -#define GOSSIP_ITEM_AZGALOR "We have nothing to fear." - -#define GOSSIP_ITEM_RETREAT "We can't keep this up. Let's retreat!" +enum GOSSIPS +{ + GOSSIP_ITEM_BEGIN_ALLY_MID = 7552, // My companions and I are with you, Lady Proudmoore. + GOSSIP_ITEM_BEGIN_ALLY_OID = 0, + GOSSIP_ITEM_ANETHERON_MID = 7552, // We are ready for whatever Archimonde might send our way, Lady Proudmoore. + GOSSIP_ITEM_ANETHERON_OID = 1, + GOSSIP_ITEM_ALLY_RETREAT_MID = 7552, // Until we meet again, Lady Proudmoore. + GOSSIP_ITEM_ALLY_RETREAT_OID = 2, + GOSSIP_ITEM_BEGIN_HORDE_MID = 7581, // I am with you, Thrall. + GOSSIP_ITEM_BEGIN_HORDE_OID = 0, + GOSSIP_ITEM_AZGALOR_MID = 7581, // We have nothing to fear. + GOSSIP_ITEM_AZGALOR_OID = 1, + GOSSIP_ITEM_HORDE_RETREAT_MID = 7581, //Until we meet again, Thrall. + GOSSIP_ITEM_HORDE_RETREAT_OID = 2, + GOSSIP_ITEM_TYRANDE_MID = 7706, // I would be grateful for any aid you can provide, Priestess. + GOSSIP_ITEM_TYRANDE_OID = 0 +}; -#define GOSSIP_ITEM_TYRANDE "Aid us in defending Nordrassil" #define ITEM_TEAR_OF_GODDESS 24494 #define GOSSIP_ITEM_GM1 "[GM] Toggle Debug Timers" @@ -103,11 +112,11 @@ class npc_jaina_proudmoore : public CreatureScript uint32 RageEncounter = GetInstanceData(DATA_RAGEWINTERCHILLEVENT); uint32 AnetheronEncounter = GetInstanceData(DATA_ANETHERONEVENT); if (RageEncounter == NOT_STARTED) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_BEGIN_ALLY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, GOSSIP_ITEM_BEGIN_ALLY_MID, GOSSIP_ITEM_BEGIN_ALLY_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); else if (RageEncounter == DONE && AnetheronEncounter == NOT_STARTED) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_ANETHERON, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); + AddGossipItemFor(player, GOSSIP_ITEM_ANETHERON_MID, GOSSIP_ITEM_ANETHERON_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); else if (RageEncounter == DONE && AnetheronEncounter == DONE) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_RETREAT, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3); + AddGossipItemFor(player, GOSSIP_ITEM_ALLY_RETREAT_MID, GOSSIP_ITEM_ALLY_RETREAT_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3); if (player->IsGameMaster()) AddGossipItemFor(player, GossipOptionIcon::Trainer, GOSSIP_ITEM_GM1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF); @@ -179,11 +188,11 @@ class npc_thrall : public CreatureScript uint32 KazrogalEvent = GetInstanceData(DATA_KAZROGALEVENT); uint32 AzgalorEvent = GetInstanceData(DATA_AZGALOREVENT); if (KazrogalEvent == NOT_STARTED) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_BEGIN_HORDE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, GOSSIP_ITEM_BEGIN_HORDE_MID, GOSSIP_ITEM_BEGIN_HORDE_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); else if (KazrogalEvent == DONE && AzgalorEvent == NOT_STARTED) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_AZGALOR, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); + AddGossipItemFor(player, GOSSIP_ITEM_AZGALOR_MID, GOSSIP_ITEM_AZGALOR_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); else if (AzgalorEvent == DONE) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_RETREAT, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3); + AddGossipItemFor(player, GOSSIP_ITEM_HORDE_RETREAT_MID, GOSSIP_ITEM_HORDE_RETREAT_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3); } if (player->IsGameMaster()) @@ -234,7 +243,7 @@ class npc_tyrande_whisperwind : public CreatureScript // Only let them get item if Azgalor is dead. if (AzgalorEvent == DONE && !player->HasItemCount(ITEM_TEAR_OF_GODDESS)) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_TYRANDE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF); + AddGossipItemFor(player, GOSSIP_ITEM_TYRANDE_MID, GOSSIP_ITEM_TYRANDE_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF); SendGossipMenuFor(player, 907, me->GetGUID()); return true; } diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp index 8d225a3f713..69f7c093873 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp @@ -43,10 +43,11 @@ enum Erozion QUEST_ENTRY_DIVERSION = 10283, QUEST_ENTRY_ESCAPE = 10284, QUEST_ENTRY_RETURN = 10285, - ITEM_ENTRY_BOMBS = 25853 + ITEM_ENTRY_BOMBS = 25853, + GOSSIP_MENU_EROZION = 7769, + GOSSIP_OPTION_BOMB = 0 //I need a pack of Incendiary Bombs. }; -#define GOSSIP_HELLO_EROZION1 "I need a pack of Incendiary Bombs." -#define GOSSIP_HELLO_EROZION2 "[PH] Teleport please, i'm tired." +#define GOSSIP_HELLO_EROZION2 "[PH] Teleport please, i'm tired." //not in DB,maybe incorrect? /*###### ## npc_erozion @@ -88,7 +89,7 @@ public: player->PrepareQuestMenu(me->GetGUID()); if (instance->GetData(TYPE_BARREL_DIVERSION) != DONE && !player->HasItemCount(ITEM_ENTRY_BOMBS)) - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_HELLO_EROZION1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, GOSSIP_MENU_EROZION, GOSSIP_OPTION_BOMB, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); if (player->GetQuestStatus(QUEST_ENTRY_RETURN) == QUEST_STATUS_COMPLETE) AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_HELLO_EROZION2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); @@ -178,19 +179,18 @@ enum ThrallOldHillsbrad GOSSIP_ID_SKARLOC2 = 9579, //What do you mean by this? Is Taretha in danger? GOSSIP_ID_SKARLOC3 = 9580, GOSSIP_ID_TARREN = 9597, //tarren mill is beyond these trees - GOSSIP_ID_COMPLETE = 9578 //Thank you friends, I owe my freedom to you. Where is Taretha? I hoped to see her + GOSSIP_ID_COMPLETE = 9578, //Thank you friends, I owe my freedom to you. Where is Taretha? I hoped to see her + GOSSIP_ITEM_WALKING_MID = 7499, + GOSSIP_ITEM_DEFAULT_OP = 0, //We are ready to get you out of here, Thrall. Let's go! + GOSSIP_ITEM_TARREN_MID = 7840, //We're ready, Thrall. + GOSSIP_ITEM_SKARLOC1_MID = 7830, //Taretha cannot see you, Thrall. + GOSSIP_ITEM_SKARLOC2_MID = 7829 //The situation is rather complicated, Thrall. It would be best for you to head into the mountains now, before more of Blackmoore's men show up. We'll make sure Taretha is safe. }; #define SPEED_WALK (0.5f) #define SPEED_RUN (1.0f) #define SPEED_MOUNT (1.6f) -//gossip items -#define GOSSIP_ITEM_SKARLOC1 "Taretha cannot see you, Thrall." -#define GOSSIP_ITEM_SKARLOC2 "The situation is rather complicated, Thrall. It would be best for you to head into the mountains now, before more of Blackmoore's men show up. We'll make sure Taretha is safe." -#define GOSSIP_ITEM_TARREN "We're ready, Thrall." -#define GOSSIP_ITEM_WALKING "We are ready to get you out of here, Thrall. Let's go!" - class npc_thrall_old_hillsbrad : public CreatureScript { public: @@ -489,7 +489,7 @@ public: break; case GOSSIP_ACTION_INFO_DEF + 2: - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_SKARLOC2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 20); + AddGossipItemFor(player, GOSSIP_ITEM_SKARLOC2_MID, GOSSIP_ITEM_DEFAULT_OP, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 20); SendGossipMenuFor(player, GOSSIP_ID_SKARLOC2, me->GetGUID()); break; @@ -522,19 +522,19 @@ public: if (instance->GetData(TYPE_BARREL_DIVERSION) == DONE && !instance->GetData(TYPE_THRALL_EVENT)) { - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_WALKING, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, GOSSIP_ITEM_WALKING_MID, GOSSIP_ITEM_DEFAULT_OP, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); SendGossipMenuFor(player, GOSSIP_ID_START, me->GetGUID()); } if (instance->GetData(TYPE_THRALL_PART1) == DONE && !instance->GetData(TYPE_THRALL_PART2)) { - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_SKARLOC1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); + AddGossipItemFor(player, GOSSIP_ITEM_SKARLOC1_MID, GOSSIP_ITEM_DEFAULT_OP, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); SendGossipMenuFor(player, GOSSIP_ID_SKARLOC1, me->GetGUID()); } if (instance->GetData(TYPE_THRALL_PART2) == DONE && !instance->GetData(TYPE_THRALL_PART3)) { - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_TARREN, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3); + AddGossipItemFor(player, GOSSIP_ITEM_TARREN_MID, GOSSIP_ITEM_DEFAULT_OP, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3); SendGossipMenuFor(player, GOSSIP_ID_TARREN, me->GetGUID()); } return true; @@ -553,12 +553,13 @@ public: enum Taretha { GOSSIP_ID_EPOCH1 = 9610, //Thank you for helping Thrall escape, friends. Now I only hope - GOSSIP_ID_EPOCH2 = 9613 //Yes, friends. This man was no wizard of + GOSSIP_ID_EPOCH2 = 9613, //Yes, friends. This man was no wizard of + GOSSIP_ITEM_EPOCH1_MID = 7849, + GOSSIP_ITEM_EPOCH1_OID = 0, //Strange wizard? + GOSSIP_ITEM_EPOCH2_MID = 7852, + GOSSIP_ITEM_EPOCH2_OID = 0 //We'll get you out, Taretha. Don't worry. I doubt the wizard would wander too far away. }; -#define GOSSIP_ITEM_EPOCH1 "Strange wizard?" -#define GOSSIP_ITEM_EPOCH2 "We'll get you out. Taretha. Don't worry. I doubt the wizard would wander too far away." - class npc_taretha : public CreatureScript { public: @@ -601,7 +602,7 @@ public: if (action == GOSSIP_ACTION_INFO_DEF + 1) { - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_EPOCH2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); + AddGossipItemFor(player, GOSSIP_ITEM_EPOCH2_MID, GOSSIP_ITEM_EPOCH2_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); SendGossipMenuFor(player, GOSSIP_ID_EPOCH2, me->GetGUID()); } if (action == GOSSIP_ACTION_INFO_DEF + 2) @@ -625,7 +626,7 @@ public: { if (instance->GetData(TYPE_THRALL_PART3) == DONE && instance->GetData(TYPE_THRALL_PART4) == NOT_STARTED) { - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_ITEM_EPOCH1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, GOSSIP_ITEM_EPOCH1_MID, GOSSIP_ITEM_EPOCH1_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); SendGossipMenuFor(player, GOSSIP_ID_EPOCH1, me->GetGUID()); } return true; diff --git a/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp b/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp index ca60f60c607..96aedc468ac 100644 --- a/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp +++ b/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp @@ -51,10 +51,14 @@ enum blySays enum blySpells { SPELL_SHIELD_BASH = 11972, - SPELL_REVENGE = 12170 + SPELL_REVENGE = 12170, }; -#define GOSSIP_BLY "That's it! I'm tired of helping you out. It's time we settled things on the battlefield!" +enum blygossip +{ + GOSSIP_BLY_MID = 941, //That's it! I'm tired of helping you out. It's time we settled things on the battlefield! + GOSSIP_BLY_OID = 1 +}; class npc_sergeant_bly : public CreatureScript { @@ -177,7 +181,7 @@ public: { if (instance->GetData(EVENT_PYRAMID) == PYRAMID_KILLED_ALL_TROLLS) { - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_BLY, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, GOSSIP_BLY_MID, GOSSIP_BLY_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); SendGossipMenuFor(player, 1517, me->GetGUID()); } else @@ -260,7 +264,11 @@ enum weegliSays SAY_WEEGLI_OK_I_GO = 1 }; -#define GOSSIP_WEEGLI "Will you blow up that door now?" +enum weegligossip +{ + GOSSIP_WEEGLI_MID = 940, // Will you blow up that door now? + GOSSIP_WEEGLI_OID = 0 +}; class npc_weegli_blastfuse : public CreatureScript { @@ -369,7 +377,7 @@ public: switch (instance->GetData(EVENT_PYRAMID)) { case PYRAMID_KILLED_ALL_TROLLS: - AddGossipItemFor(player, GossipOptionIcon::None, GOSSIP_WEEGLI, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + AddGossipItemFor(player, GOSSIP_WEEGLI_MID, GOSSIP_WEEGLI_OID, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); SendGossipMenuFor(player, 1514, me->GetGUID()); //if event can proceed to end break; case PYRAMID_NOT_STARTED: |
