diff options
| -rw-r--r-- | sql/updates/world/2013_12_22_01_world_misc.sql | 21 | ||||
| -rw-r--r-- | src/server/scripts/Northrend/zone_wintergrasp.cpp | 36 | ||||
| -rw-r--r-- | src/server/scripts/World/npc_taxi.cpp | 20 |
3 files changed, 59 insertions, 18 deletions
diff --git a/sql/updates/world/2013_12_22_01_world_misc.sql b/sql/updates/world/2013_12_22_01_world_misc.sql new file mode 100644 index 00000000000..2acc4754157 --- /dev/null +++ b/sql/updates/world/2013_12_22_01_world_misc.sql @@ -0,0 +1,21 @@ +-- Kara Thricestar SAI +SET @ENTRY := 26602; +UPDATE `creature_template` SET `AIName`='SmartAI', ScriptName= '' WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,1,4,0,100,0,0,0,0,0,12,9526,4,4,0,0,0,1,0,0,0,0,0,0,0,"Kara Thricestar - On Aggro - Summon Enraged Gryphon"), +(@ENTRY,0,1,2,61,0,100,0,0,0,0,0,12,9526,4,4,0,0,0,1,0,0,0,0,0,0,0,"Kara Thricestar - On Aggro - Summon Enraged Gryphon"), +(@ENTRY,0,2,0,61,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kara Thricestar - On Aggro - Say Line 0"), +(@ENTRY,0,3,0,62,0,100,0,9683,1,0,0,11,51446,0,0,0,0,0,7,0,0,0,0,0,0,0,"Kara Thricestar - On gossip Option select - Cast Fizzcrank Airstrip to Dens of Dying Taxi"); +-- Add Gossip Options +DELETE FROM `gossip_menu_option` WHERE `menu_id` IN (9683); +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`option_id`,`npc_option_npcflag`,`action_menu_id`) VALUES +(9683,1,0, 'Kara, I need to be flown out the Dens of Dying to find Bixie.',1,1,0); +-- Add Conditions +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=9683 AND `SourceEntry`=1; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15,9683,1,0,0,28,0,11692,0,0,0,0,0, '', 'Gossip Option - Show Option if Player has completed quest 11692'); + +-- Update Wintergrasp Battle-Mage cpp to remove SmartAI +UPDATE `creature_template` SET `AIName`='' WHERE `entry` IN (32169,32170,35596,35597,35598,35599,35600,35601,35602,35603,35611,35612); +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (32169,32170,35596,35597,35598,35599,35600,35601,35602,35603,35611,35612) AND `source_type`=0; diff --git a/src/server/scripts/Northrend/zone_wintergrasp.cpp b/src/server/scripts/Northrend/zone_wintergrasp.cpp index a27ce0324ff..311b18524b2 100644 --- a/src/server/scripts/Northrend/zone_wintergrasp.cpp +++ b/src/server/scripts/Northrend/zone_wintergrasp.cpp @@ -237,11 +237,47 @@ class npc_wg_spirit_guide : public CreatureScript } }; +enum WGQueue +{ + SPELL_FROST_ARMOR = 12544 +}; + class npc_wg_queue : public CreatureScript { public: npc_wg_queue() : CreatureScript("npc_wg_queue") { } + struct npc_wg_queueAI : public ScriptedAI + { + npc_wg_queueAI(Creature* creature) : ScriptedAI(creature) { } + + uint32 FrostArmor_Timer; + + void Reset() OVERRIDE + { + FrostArmor_Timer = 0; + } + + void EnterCombat(Unit* /*who*/) OVERRIDE { } + + void UpdateAI(uint32 diff) OVERRIDE + { + if (FrostArmor_Timer <= diff) + { + DoCast(me, SPELL_FROST_ARMOR); + FrostArmor_Timer = 180000; + } + else FrostArmor_Timer -= diff; + + DoMeleeAttackIfReady(); + } + }; + + CreatureAI* GetAI(Creature* creature) const OVERRIDE + { + return new npc_wg_queueAI(creature); + } + bool OnGossipHello(Player* player, Creature* creature) OVERRIDE { if (creature->IsQuestGiver()) diff --git a/src/server/scripts/World/npc_taxi.cpp b/src/server/scripts/World/npc_taxi.cpp index bf742d606f2..08be2595c0e 100644 --- a/src/server/scripts/World/npc_taxi.cpp +++ b/src/server/scripts/World/npc_taxi.cpp @@ -54,8 +54,6 @@ EndScriptData #define GOSSIP_TORASTRASZA1 "I would like to see Lord Of Afrasastrasz, in the middle of the temple." #define GOSSIP_TORASTRASZA2 "Yes, Please. I would like to return to the ground floor of the temple." #define GOSSIP_CRIMSONWING "<Ride the gryphons to Survey Alcaz Island>" -#define GOSSIP_THRICESTAR1 "Do you think I could take a ride on one of those flying machines?" -#define GOSSIP_THRICESTAR2 "Kara, I need to be flown out the Dens of Dying to find Bixie." #define GOSSIP_WILLIAMKEILAR1 "Take me to Northpass Tower." #define GOSSIP_WILLIAMKEILAR2 "Take me to Eastwall Tower." #define GOSSIP_WILLIAMKEILAR3 "Take me to Crown Guard Tower." @@ -163,13 +161,6 @@ public: if (player->GetQuestStatus(11142) == QUEST_STATUS_INCOMPLETE) player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_CRIMSONWING, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+25); break; - case 26602: - if (creature->IsTaxi()) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_TAXI, GOSSIP_THRICESTAR1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 26); - - if (player->GetQuestStatus(11692) == QUEST_STATUS_COMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_THRICESTAR2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 27); - break; case 17209: player->SetTaxiCheater(true); player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_WILLIAMKEILAR1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 28); @@ -299,21 +290,14 @@ public: player->CastSpell(player, 42295, true); break; case GOSSIP_ACTION_INFO_DEF + 26: - player->GetSession()->SendTaxiMenu(creature); - break; - case GOSSIP_ACTION_INFO_DEF + 27: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 51446, false); - break; - case GOSSIP_ACTION_INFO_DEF + 28: player->CLOSE_GOSSIP_MENU(); player->ActivateTaxiPathTo(494); break; - case GOSSIP_ACTION_INFO_DEF + 29: + case GOSSIP_ACTION_INFO_DEF + 27: player->CLOSE_GOSSIP_MENU(); player->ActivateTaxiPathTo(495); break; - case GOSSIP_ACTION_INFO_DEF + 30: + case GOSSIP_ACTION_INFO_DEF + 28: player->CLOSE_GOSSIP_MENU(); player->ActivateTaxiPathTo(496); break; |
