From 04cfcf523db6e2517c3a26a4ea36dbd24c2aab8b Mon Sep 17 00:00:00 2001 From: Nyeriah Date: Sat, 30 Aug 2014 17:35:04 -0300 Subject: Scripts/Auchindoun: Update Talon King Ikiss' script to EventMaps Codestyle Missing include --- sql/updates/world/2014_08_30_04_world_spell_script_names.sql | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 sql/updates/world/2014_08_30_04_world_spell_script_names.sql (limited to 'sql') diff --git a/sql/updates/world/2014_08_30_04_world_spell_script_names.sql b/sql/updates/world/2014_08_30_04_world_spell_script_names.sql new file mode 100644 index 00000000000..128364bf4e7 --- /dev/null +++ b/sql/updates/world/2014_08_30_04_world_spell_script_names.sql @@ -0,0 +1,3 @@ +DELETE FROM `spell_script_names` WHERE `spell_id` = 38194; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(38194, 'spell_talon_king_ikiss_blink'); -- cgit v1.2.3 From 681cf8f27c341a8fadbadf1851b55b7b8a7e524a Mon Sep 17 00:00:00 2001 From: joschiwald Date: Sun, 31 Aug 2014 20:33:46 +0200 Subject: Core/Scripts: rename files, remove whitespace and some other small changes after recent pull requests --- .../2014_08_30_04_world_spell_script_names.sql | 3 - .../2014_08_31_02_world_spell_script_names.sql | 3 + .../UtgardeKeep/boss_skarvald_dalronn.cpp | 67 +++---- .../SethekkHalls/boss_tailonking_ikiss.cpp | 219 --------------------- .../SethekkHalls/boss_talon_king_ikiss.cpp | 211 ++++++++++++++++++++ src/server/scripts/Outland/CMakeLists.txt | 2 +- 6 files changed, 245 insertions(+), 260 deletions(-) delete mode 100644 sql/updates/world/2014_08_30_04_world_spell_script_names.sql create mode 100644 sql/updates/world/2014_08_31_02_world_spell_script_names.sql delete mode 100644 src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_tailonking_ikiss.cpp create mode 100644 src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp (limited to 'sql') diff --git a/sql/updates/world/2014_08_30_04_world_spell_script_names.sql b/sql/updates/world/2014_08_30_04_world_spell_script_names.sql deleted file mode 100644 index 128364bf4e7..00000000000 --- a/sql/updates/world/2014_08_30_04_world_spell_script_names.sql +++ /dev/null @@ -1,3 +0,0 @@ -DELETE FROM `spell_script_names` WHERE `spell_id` = 38194; -INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES -(38194, 'spell_talon_king_ikiss_blink'); diff --git a/sql/updates/world/2014_08_31_02_world_spell_script_names.sql b/sql/updates/world/2014_08_31_02_world_spell_script_names.sql new file mode 100644 index 00000000000..128364bf4e7 --- /dev/null +++ b/sql/updates/world/2014_08_31_02_world_spell_script_names.sql @@ -0,0 +1,3 @@ +DELETE FROM `spell_script_names` WHERE `spell_id` = 38194; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(38194, 'spell_talon_king_ikiss_blink'); diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp index 539f1c4abfb..c6a91e3ff33 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp @@ -44,6 +44,7 @@ enum Spells SPELL_STONE_STRIKE = 48583, SPELL_ENRAGE = 48193, SPELL_SUMMON_SKARVALD_GHOST = 48613, + // Spells of Dalronn and his Ghost SPELL_SHADOW_BOLT = 43649, SPELL_SUMMON_SKELETONS = 52611, @@ -76,31 +77,30 @@ enum Actions class SkarvaldChargePredicate { - public: - SkarvaldChargePredicate(Unit* unit) : me(unit) { } + public: + SkarvaldChargePredicate(Unit* unit) : _me(unit) { } - bool operator() (WorldObject* object) const - { - return object->GetDistance2d(me) >= 5.0f && object->GetDistance2d(me) <= 30.0f; - } + bool operator() (WorldObject* target) const + { + return target->GetDistance2d(_me) >= 5.0f && target->GetDistance2d(_me) <= 30.0f; + } private: - Unit* me; + Unit* _me; }; struct generic_boss_controllerAI : public BossAI { - generic_boss_controllerAI(Creature* creature) : BossAI(creature, DATA_SKARVALD_DALRONN) - { + generic_boss_controllerAI(Creature* creature) : BossAI(creature, DATA_SKARVALD_DALRONN) + { OtherBossData = 0; - IsInGhostForm = false; + IsInGhostForm = me->GetEntry() == NPC_SKARVALD_GHOST || me->GetEntry() == NPC_DALRONN_GHOST; } void Reset() override { - if (me->GetEntry() == NPC_SKARVALD_GHOST || me->GetEntry() == NPC_DALRONN_GHOST) + if (IsInGhostForm) { - IsInGhostForm = true; // Call this here since ghosts aren't set in combat as they spawn. DoZoneInCombat(me, 50.0f); } @@ -160,7 +160,7 @@ struct generic_boss_controllerAI : public BossAI if (!IsInGhostForm && who->GetTypeId() == TYPEID_PLAYER) Talk(SAY_KILL); } - + protected: uint32 OtherBossData; bool IsInGhostForm; @@ -173,26 +173,27 @@ class boss_skarvald_the_constructor : public CreatureScript struct boss_skarvald_the_constructorAI : public generic_boss_controllerAI { - boss_skarvald_the_constructorAI(Creature* creature) : generic_boss_controllerAI(creature) - { + boss_skarvald_the_constructorAI(Creature* creature) : generic_boss_controllerAI(creature) + { + OtherBossData = DATA_DALRONN; Enraged = false; } void Reset() override { - OtherBossData = DATA_DALRONN; Enraged = false; generic_boss_controllerAI::Reset(); } void EnterCombat(Unit* who) override { + generic_boss_controllerAI::EnterCombat(who); + if (!IsInGhostForm) Talk(SAY_AGGRO); events.ScheduleEvent(EVENT_SKARVALD_CHARGE, 5000); events.ScheduleEvent(EVENT_STONE_STRIKE, 10000); - generic_boss_controllerAI::EnterCombat(who); } void ExecuteEvent(uint32 eventId) override @@ -239,26 +240,23 @@ class boss_dalronn_the_controller : public CreatureScript struct boss_dalronn_the_controllerAI : public generic_boss_controllerAI { - boss_dalronn_the_controllerAI(Creature* creature) : generic_boss_controllerAI(creature) { } - - void Reset() override + boss_dalronn_the_controllerAI(Creature* creature) : generic_boss_controllerAI(creature) { OtherBossData = DATA_SKARVALD; - generic_boss_controllerAI::Reset(); } void EnterCombat(Unit* who) override { + generic_boss_controllerAI::EnterCombat(who); + events.ScheduleEvent(EVENT_SHADOW_BOLT, 1000); events.ScheduleEvent(EVENT_DEBILITATE, 5000); - - if (!IsInGhostForm) + + if (!IsInGhostForm) events.ScheduleEvent(EVENT_DELAYED_AGGRO_SAY, 5000); - - if (IsHeroic()) + + if (IsHeroic()) events.ScheduleEvent(EVENT_SUMMON_SKELETONS, 10000); - - generic_boss_controllerAI::EnterCombat(who); } void ExecuteEvent(uint32 eventId) override @@ -266,22 +264,17 @@ class boss_dalronn_the_controller : public CreatureScript switch (eventId) { case EVENT_SHADOW_BOLT: - if (!me->IsNonMeleeSpellCast(false)) - if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 0.0f, true)) - DoCast(target, SPELL_SHADOW_BOLT); + if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 45.0f, true)) + DoCast(target, SPELL_SHADOW_BOLT); events.ScheduleEvent(EVENT_SHADOW_BOLT, 2100); //give a 100ms pause to try cast other spells break; case EVENT_DEBILITATE: - if (!me->IsNonMeleeSpellCast(false)) - { - if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 0.0f, true)) - DoCast(target, SPELL_DEBILITATE); - } + if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 50.0f, true)) + DoCast(target, SPELL_DEBILITATE); events.ScheduleEvent(EVENT_DEBILITATE, urand(5000, 10000)); break; case EVENT_SUMMON_SKELETONS: - if (!me->IsNonMeleeSpellCast(false)) - DoCast(SPELL_SUMMON_SKELETONS); + DoCast(me, SPELL_SUMMON_SKELETONS); events.ScheduleEvent(EVENT_SUMMON_SKELETONS, urand(10000, 30000)); break; case EVENT_DELAYED_AGGRO_SAY: diff --git a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_tailonking_ikiss.cpp b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_tailonking_ikiss.cpp deleted file mode 100644 index 1776cccb6cc..00000000000 --- a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_tailonking_ikiss.cpp +++ /dev/null @@ -1,219 +0,0 @@ -/* - * Copyright (C) 2008-2014 TrinityCore - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 2 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see . - */ - -#include "ScriptMgr.h" -#include "ScriptedCreature.h" -#include "SpellScript.h" -#include "sethekk_halls.h" - -enum Says -{ - SAY_INTRO = 0, - SAY_AGGRO = 1, - SAY_SLAY = 2, - SAY_DEATH = 3, - EMOTE_ARCANE_EXPLOSION = 4 -}; - -enum Spells -{ - SPELL_BLINK = 38194, - SPELL_BLINK_TELEPORT = 38203, - SPELL_MANA_SHIELD = 38151, - SPELL_ARCANE_BUBBLE = 9438, - SPELL_SLOW = 35032, - SPELL_POLYMORPH = 38245, - SPELL_ARCANE_VOLLEY = 35059, - SPELL_ARCANE_EXPLOSION = 38197, -}; - -enum Events -{ - EVENT_POLYMORPH = 1, - EVENT_BLINK, - EVENT_SLOW, - EVENT_ARCANE_VOLLEY, - EVENT_ARCANE_EXPLOSION -}; - -class boss_talon_king_ikiss : public CreatureScript -{ -public: - boss_talon_king_ikiss() : CreatureScript("boss_talon_king_ikiss") { } - - struct boss_talon_king_ikissAI : public BossAI - { - boss_talon_king_ikissAI(Creature* creature) : BossAI(creature, DATA_TALON_KING_IKISS) - { - Intro = false; - ManaShield = false; - } - - void Reset() override - { - _Reset(); - Intro = false; - ManaShield = false; - } - - void MoveInLineOfSight(Unit* who) override - { - if (!me->GetVictim() && me->CanCreatureAttack(who)) - { - if (!Intro && me->IsWithinDistInMap(who, 100)) - { - Intro = true; - Talk(SAY_INTRO); - } - - if (!me->CanFly() && me->GetDistanceZ(who) > CREATURE_Z_ATTACK_RANGE) - return; - - float attackRadius = me->GetAttackDistance(who); - if (me->IsWithinDistInMap(who, attackRadius) && me->IsWithinLOSInMap(who)) - AttackStart(who); - } - } - - void EnterCombat(Unit* /*who*/) override - { - _EnterCombat(); - Talk(SAY_AGGRO); - events.ScheduleEvent(EVENT_ARCANE_VOLLEY, 5000); - events.ScheduleEvent(EVENT_POLYMORPH, 8000); - events.ScheduleEvent(EVENT_BLINK, 35000); - if (IsHeroic()) - events.ScheduleEvent(EVENT_SLOW, urand(15000, 30000)); - } - - void ExecuteEvent(uint32 eventId) override - { - switch (eventId) - { - case EVENT_POLYMORPH: - // Second top aggro in normal, random target in heroic. - if (IsHeroic()) - DoCast(SelectTarget(SELECT_TARGET_RANDOM, 0), SPELL_POLYMORPH); - else - DoCast(SelectTarget(SELECT_TARGET_TOPAGGRO, 1), SPELL_POLYMORPH); - events.ScheduleEvent(EVENT_POLYMORPH, urand(15000, 17500)); - break; - case EVENT_ARCANE_VOLLEY: - DoCast(me, SPELL_ARCANE_VOLLEY); - events.ScheduleEvent(EVENT_ARCANE_VOLLEY, urand(7000, 12000)); - break; - case EVENT_SLOW: - DoCast(me, SPELL_SLOW); - events.ScheduleEvent(EVENT_SLOW, urand(15000, 40000)); - break; - case EVENT_BLINK: - if (me->IsNonMeleeSpellCast(false)) - me->InterruptNonMeleeSpells(false); - Talk(EMOTE_ARCANE_EXPLOSION); - DoCastAOE(SPELL_BLINK); - events.ScheduleEvent(EVENT_BLINK, urand(35000, 40000)); - events.ScheduleEvent(EVENT_ARCANE_EXPLOSION, 1000); - break; - case EVENT_ARCANE_EXPLOSION: - DoCast(me, SPELL_ARCANE_EXPLOSION); - DoCast(me, SPELL_ARCANE_BUBBLE, true); - break; - default: - break; - } - } - - void DamageTaken(Unit* /*who*/, uint32& damage) override - { - if (!ManaShield && me->HealthBelowPctDamaged(20, damage)) - { - DoCast(me, SPELL_MANA_SHIELD); - ManaShield = true; - } - } - - void JustDied(Unit* /*killer*/) override - { - _JustDied(); - Talk(SAY_DEATH); - } - - void KilledUnit(Unit* who) override - { - if (who->GetTypeId() == TYPEID_PLAYER) - Talk(SAY_SLAY); - } - - private: - bool ManaShield; - bool Intro; - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetSethekkHallsAI(creature); - } -}; - -// 38194 - Blink -class spell_talon_king_ikiss_blink : public SpellScriptLoader -{ - public: - spell_talon_king_ikiss_blink() : SpellScriptLoader("spell_talon_king_ikiss_blink") { } - - class spell_talon_king_ikiss_blink_SpellScript : public SpellScript - { - PrepareSpellScript(spell_talon_king_ikiss_blink_SpellScript); - - bool Validate(SpellInfo const* /*spellInfo*/) override - { - if (!sSpellMgr->GetSpellInfo(SPELL_BLINK)) - return false; - return true; - } - - void FilterTargets(std::list& targets) - { - uint8 maxSize = 1; - if (targets.size() > maxSize) - Trinity::Containers::RandomResizeList(targets, maxSize); - } - - void HandleDummyHitTarget(SpellEffIndex effIndex) - { - PreventHitDefaultEffect(effIndex); - GetHitUnit()->CastSpell(GetCaster(), SPELL_BLINK_TELEPORT, true); - } - - void Register() override - { - OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_talon_king_ikiss_blink_SpellScript::FilterTargets, EFFECT_0, TARGET_UNIT_SRC_AREA_ENEMY); - OnEffectHitTarget += SpellEffectFn(spell_talon_king_ikiss_blink_SpellScript::HandleDummyHitTarget, EFFECT_0, SPELL_EFFECT_DUMMY); - } - }; - - SpellScript* GetSpellScript() const override - { - return new spell_talon_king_ikiss_blink_SpellScript(); - } -}; - -void AddSC_boss_talon_king_ikiss() -{ - new boss_talon_king_ikiss(); - new spell_talon_king_ikiss_blink(); -} diff --git a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp new file mode 100644 index 00000000000..22914ca9094 --- /dev/null +++ b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp @@ -0,0 +1,211 @@ +/* + * Copyright (C) 2008-2014 TrinityCore + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, or (at your + * option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . + */ + +#include "ScriptMgr.h" +#include "ScriptedCreature.h" +#include "SpellScript.h" +#include "sethekk_halls.h" + +enum Says +{ + SAY_INTRO = 0, + SAY_AGGRO = 1, + SAY_SLAY = 2, + SAY_DEATH = 3, + EMOTE_ARCANE_EXPLOSION = 4 +}; + +enum Spells +{ + SPELL_BLINK = 38194, + SPELL_BLINK_TELEPORT = 38203, + SPELL_MANA_SHIELD = 38151, + SPELL_ARCANE_BUBBLE = 9438, + SPELL_SLOW = 35032, + SPELL_POLYMORPH = 38245, + SPELL_ARCANE_VOLLEY = 35059, + SPELL_ARCANE_EXPLOSION = 38197, +}; + +enum Events +{ + EVENT_POLYMORPH = 1, + EVENT_BLINK, + EVENT_SLOW, + EVENT_ARCANE_VOLLEY, + EVENT_ARCANE_EXPLOSION +}; + +class boss_talon_king_ikiss : public CreatureScript +{ +public: + boss_talon_king_ikiss() : CreatureScript("boss_talon_king_ikiss") { } + + struct boss_talon_king_ikissAI : public BossAI + { + boss_talon_king_ikissAI(Creature* creature) : BossAI(creature, DATA_TALON_KING_IKISS) + { + Intro = false; + ManaShield = false; + } + + void Reset() override + { + _Reset(); + Intro = false; + ManaShield = false; + } + + void MoveInLineOfSight(Unit* who) override + { + if (!Intro && who->GetTypeId() == TYPEID_PLAYER && me->IsWithinDistInMap(who, 100.0f)) + { + Intro = true; + Talk(SAY_INTRO); + } + + BossAI::MoveInLineOfSight(who); + } + + void EnterCombat(Unit* /*who*/) override + { + _EnterCombat(); + Talk(SAY_AGGRO); + events.ScheduleEvent(EVENT_ARCANE_VOLLEY, 5000); + events.ScheduleEvent(EVENT_POLYMORPH, 8000); + events.ScheduleEvent(EVENT_BLINK, 35000); + if (IsHeroic()) + events.ScheduleEvent(EVENT_SLOW, urand(15000, 30000)); + } + + void ExecuteEvent(uint32 eventId) override + { + switch (eventId) + { + case EVENT_POLYMORPH: + // Second top aggro in normal, random target in heroic. + if (IsHeroic()) + DoCast(SelectTarget(SELECT_TARGET_RANDOM, 0), SPELL_POLYMORPH); + else + DoCast(SelectTarget(SELECT_TARGET_TOPAGGRO, 1), SPELL_POLYMORPH); + events.ScheduleEvent(EVENT_POLYMORPH, urand(15000, 17500)); + break; + case EVENT_ARCANE_VOLLEY: + DoCast(me, SPELL_ARCANE_VOLLEY); + events.ScheduleEvent(EVENT_ARCANE_VOLLEY, urand(7000, 12000)); + break; + case EVENT_SLOW: + DoCast(me, SPELL_SLOW); + events.ScheduleEvent(EVENT_SLOW, urand(15000, 40000)); + break; + case EVENT_BLINK: + if (me->IsNonMeleeSpellCast(false)) + me->InterruptNonMeleeSpells(false); + Talk(EMOTE_ARCANE_EXPLOSION); + DoCastAOE(SPELL_BLINK); + events.ScheduleEvent(EVENT_BLINK, urand(35000, 40000)); + events.ScheduleEvent(EVENT_ARCANE_EXPLOSION, 1000); + break; + case EVENT_ARCANE_EXPLOSION: + DoCast(me, SPELL_ARCANE_EXPLOSION); + DoCast(me, SPELL_ARCANE_BUBBLE, true); + break; + default: + break; + } + } + + void DamageTaken(Unit* /*who*/, uint32& damage) override + { + if (!ManaShield && me->HealthBelowPctDamaged(20, damage)) + { + DoCast(me, SPELL_MANA_SHIELD); + ManaShield = true; + } + } + + void JustDied(Unit* /*killer*/) override + { + _JustDied(); + Talk(SAY_DEATH); + } + + void KilledUnit(Unit* who) override + { + if (who->GetTypeId() == TYPEID_PLAYER) + Talk(SAY_SLAY); + } + + private: + bool ManaShield; + bool Intro; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetSethekkHallsAI(creature); + } +}; + +// 38194 - Blink +class spell_talon_king_ikiss_blink : public SpellScriptLoader +{ + public: + spell_talon_king_ikiss_blink() : SpellScriptLoader("spell_talon_king_ikiss_blink") { } + + class spell_talon_king_ikiss_blink_SpellScript : public SpellScript + { + PrepareSpellScript(spell_talon_king_ikiss_blink_SpellScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_BLINK_TELEPORT)) + return false; + return true; + } + + void FilterTargets(std::list& targets) + { + WorldObject* target = Trinity::Containers::SelectRandomContainerElement(targets); + targets.clear(); + targets.push_back(target); + } + + void HandleDummyHitTarget(SpellEffIndex effIndex) + { + PreventHitDefaultEffect(effIndex); + GetHitUnit()->CastSpell(GetCaster(), SPELL_BLINK_TELEPORT, true); + } + + void Register() override + { + OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_talon_king_ikiss_blink_SpellScript::FilterTargets, EFFECT_0, TARGET_UNIT_SRC_AREA_ENEMY); + OnEffectHitTarget += SpellEffectFn(spell_talon_king_ikiss_blink_SpellScript::HandleDummyHitTarget, EFFECT_0, SPELL_EFFECT_DUMMY); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_talon_king_ikiss_blink_SpellScript(); + } +}; + +void AddSC_boss_talon_king_ikiss() +{ + new boss_talon_king_ikiss(); + new spell_talon_king_ikiss_blink(); +} diff --git a/src/server/scripts/Outland/CMakeLists.txt b/src/server/scripts/Outland/CMakeLists.txt index 0c69a236ef8..ffc9b514abf 100644 --- a/src/server/scripts/Outland/CMakeLists.txt +++ b/src/server/scripts/Outland/CMakeLists.txt @@ -88,7 +88,7 @@ set(scripts_STAT_SRCS Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp Outland/Auchindoun/ManaTombs/mana_tombs.h Outland/Auchindoun/SethekkHalls/boss_darkweaver_syth.cpp - Outland/Auchindoun/SethekkHalls/boss_tailonking_ikiss.cpp + Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp Outland/Auchindoun/SethekkHalls/boss_anzu.cpp Outland/Auchindoun/SethekkHalls/instance_sethekk_halls.cpp Outland/Auchindoun/SethekkHalls/sethekk_halls.h -- cgit v1.2.3 From fe9c376214f8c27b875f841216ad59cbef70e44d Mon Sep 17 00:00:00 2001 From: Dr-J Date: Mon, 1 Sep 2014 03:19:30 +0100 Subject: DB/Misc Greatmother Geyah Now as have sniffed all the gossip menu ids for this moving script for Greatmother Geyah to db, and the current script started not working correctly sometime ago ie failing to display npc_text (only options) * Adds all gossip options to db * SAI to complete both quests from gossip * Missing npc_texts --- sql/updates/world/2014_09_01_00_world_misc.sql | 56 ++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 sql/updates/world/2014_09_01_00_world_misc.sql (limited to 'sql') diff --git a/sql/updates/world/2014_09_01_00_world_misc.sql b/sql/updates/world/2014_09_01_00_world_misc.sql new file mode 100644 index 00000000000..7a415588f0f --- /dev/null +++ b/sql/updates/world/2014_09_01_00_world_misc.sql @@ -0,0 +1,56 @@ +DELETE FROM `gossip_menu` WHERE `entry` IN(7768,7767,7766,7765,7764,7763,7762,7974,7979,7978,7977,7976); +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(7768, 9507), -- 18141 +(7767, 9508), -- 18141 +(7766, 9509), -- 18141 +(7765, 9510), -- 18141 +(7764, 9511), -- 18141 +(7763, 9512), -- 18141 +(7762, 9513), -- 18141 +(7768, 9819), -- 18141 +(7974, 9821), -- 18141 +(7979, 9822), -- 18141 +(7978, 9823), -- 18141 +(7977, 9824), -- 18141 +(7976, 9825); -- 18141 + +DELETE FROM `gossip_menu_option` WHERE `menu_id` IN(7768,7767,7766,7765,7764,7763,7762,7974,7979,7978,7977,7976); +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +-- A Visit with the Greatmother +(7768, 0, 0, 'Hello, Greatmother. Garrosh told me that you wanted to speak with me.', 15770, 1, 1, 7767, 0, 0, 0, '', 0), +(7767, 0, 0, 'You raised all of the orcs here, Greatmother?', 15772, 1, 1, 7766, 0, 0, 0, '', 0), +(7766, 0, 0, 'Do you believe that?', 15774, 1, 1, 7765, 0, 0, 0, '', 0), +(7765, 0, 0, 'What can be done? I have tried many different things. I have done my best to help the people of Nagrand. Each time I have approached Garrosh, he has dismissed me.', 15776, 1, 1, 7764, 0, 0, 0, '', 0), +(7764, 0, 0, 'Left? How can you choose to leave?', 15778, 1, 1, 7763, 0, 0, 0, '', 0), +(7763, 0, 0, 'What is this duty?', 15780, 1, 1, 7762, 0, 0, 0, '', 0), +(7762, 0, 0, 'Is there anything I can do for you, Greatmother?', 15782, 1, 1, 0, 0, 0, 0, '', 0), +-- There is no hope +(7768, 1, 0, 'Garrosh is beyond redemption, Greatmother. I fear that in helping the Mag\'har, I have convinced Garrosh that he is unfit to lead.', 16845, 1, 1, 7974, 0, 0, 0, '', 0), +(7974, 0, 0, 'I have done all that I could, Greatmother. I thank you for your kind words.', 16849, 1, 1, 7979, 0, 0, 0, '', 0), +(7979, 0, 0, 'Greatmother, you are the mother of Durotan?', 16851, 1, 1, 7978, 0, 0, 0, '', 0), +(7978, 0, 0, 'Greatmother, I never had the honor. Durotan died long before my time, but his heroics are known to all on my world. The orcs of Azeroth reside in a place known as Durotar, named after your son. And... ', 16853, 1, 1, 7977, 0, 0, 0, '', 0), +(7977, 0, 0, 'It is my warchief, Greatmother. The leader of my people. From my world. He... He is the son of Durotan. He is your grandchild.', 16855, 1, 1, 7976, 0, 0, 0, '', 0), +(7976, 0, 0, 'I will return to Azeroth at once, Greatmother.', 16857, 1, 1, 0, 0, 0, 0, '', 0); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN(14,15) AND `SourceGroup`=7768; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 7768, 0, 0, 0, 9, 0, 10044, 0, 0, 0, 0, 0, '', 'Greatmother Geyah - Show gossip option only if player has A Visit With the Greatmother taken'), +(15, 7768, 1, 0, 0, 9, 0, 10172, 0, 0, 0, 0, 0, '', 'Greatmother Geyah - Show gossip option only if player has There is no hope taken'), +(14, 7768, 9819, 0, 0, 9, 0, 10172, 0, 0, 0, 0, 0, '', 'Greatmother Geyah - Show npc text only if player has There is no hope taken'), +(14, 7768, 9507, 0, 0, 9, 0, 10172, 0, 0, 1, 0, 0, '', 'Greatmother Geyah - Show npc text only if player does not have There is no hope taken'); + +DELETE FROM `npc_text` WHERE `ID` IN(9819,9821,9822,9823,9824,9825); +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, `prob0`, `em0_0`, `em0_1`, `em0_2`, `em0_3`, `em0_4`, `em0_5`, `text1_0`, `text1_1`, `BroadcastTextID1`, `lang1`, `prob1`, `em1_0`, `em1_1`, `em1_2`, `em1_3`, `em1_4`, `em1_5`, `text2_0`, `text2_1`, `BroadcastTextID2`, `lang2`, `prob2`, `em2_0`, `em2_1`, `em2_2`, `em2_3`, `em2_4`, `em2_5`, `text3_0`, `text3_1`, `BroadcastTextID3`, `lang3`, `prob3`, `em3_0`, `em3_1`, `em3_2`, `em3_3`, `em3_4`, `em3_5`, `text4_0`, `text4_1`, `BroadcastTextID4`, `lang4`, `prob4`, `em4_0`, `em4_1`, `em4_2`, `em4_3`, `em4_4`, `em4_5`, `text5_0`, `text5_1`, `BroadcastTextID5`, `lang5`, `prob5`, `em5_0`, `em5_1`, `em5_2`, `em5_3`, `em5_4`, `em5_5`, `text6_0`, `text6_1`, `BroadcastTextID6`, `lang6`, `prob6`, `em6_0`, `em6_1`, `em6_2`, `em6_3`, `em6_4`, `em6_5`, `text7_0`, `text7_1`, `BroadcastTextID7`, `lang7`, `prob7`, `em7_0`, `em7_1`, `em7_2`, `em7_3`, `em7_4`, `em7_5`, `VerifiedBuild`) VALUES +(9819, '', "What did Garrosh tell you, $n?", 16844, 0, 1, 1, 1, 1, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), +(9821, '', "$B$BI can no longer fight the spirits, $n. My time has long since passed. Once again, I must thank you for all that you have done. While Garrosh may be unmovable, many of my people have been lifted by your accomplishments. They are now willing to fight for our rights as a united clan.", 16848, 0, 1, 1, 1, 1, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), +(9822, '', "$B$BYou remind me of my son, $n.$B$BHe was an immovable mountain: A pillar of strength and honor.$B$B$B$BHe sacrificed himself so that we could survive. So that generations of orcs after him could be born into a world without the blood curse... Without Gul'dan and his dark Horde...$B$B$B$BOh Durotan, how I wish you could be here. Your people so desperately need you...", 16850, 0, 1, 1, 1, 1, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), +(9823, '', "$B$BDid you know my son?", 16852, 0, 1, 1, 1, 1, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), +(9824, '', "$B$BYes...", 16854, 0, 1, 1, 1, 1, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), +(9825, '', "$B$BI... I... Durotan survived to have a child? The child Draka told me of before they left... It was their greatest fear... To raise a child in this world. On the other side of that gate was their only hope. I dared not tell Durotan, but secretly, I begged the spirits to watch over them - to protect their child and to give them strength.$B$BI... I must see my grandchild. I must see him. Please, I am too weak. You must tell him. Before I leave this world...", 16856, 0, 1, 1, 1, 1, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + +UPDATE `creature_template` SET `AIName`= 'SmartAI',`ScriptName`= '' WHERE `entry` =18141; +DELETE FROM `smart_scripts` WHERE `entryorguid` =18141; +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 +(18141, 0, 0, 2, 62, 0, 100, 0, 7762, 0, 0, 0, 15, 10044, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greatmother Geyah - On Gossip Option Select - Complete Quest (A Visit With the Greatmother)'), +(18141, 0, 1, 2, 62, 0, 100, 0, 7976, 0, 0, 0, 15, 10172, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greatmother Geyah - On Gossip Option Select - Complete Quest (There is no hope)'), +(18141, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greatmother Geyah - On Gossip Option Select - Close Gossip'); -- cgit v1.2.3