From 21cb6fbf4fffdcb5eeda27fe31e544168220d4c8 Mon Sep 17 00:00:00 2001 From: IntelligentQuantum Date: Fri, 8 Nov 2024 18:00:55 +0330 Subject: [PATCH 001/105] fix(Scripts/MagisterTerrace): Kael'thas' Arcane Spheres & Phoenix should despawn (#20481) * Fix(Core/Scripts): Kael'thas' Arcane Spheres & Phoenix * it's better xD --- .../EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp index d81b298cd229ea..24fc0c42adb55e 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp @@ -119,6 +119,7 @@ struct boss_felblood_kaelthas : public ScriptedAI void JustDied(Unit*) override { instance->SetBossState(DATA_KAELTHAS, DONE); + summons.DespawnAll(); if (GameObject* orb = instance->GetGameObject(DATA_ESCAPE_ORB)) { From 8569edb706dc591c53cdf1733dd2879f1098ab40 Mon Sep 17 00:00:00 2001 From: avarishd <46330494+avarishd@users.noreply.github.com> Date: Fri, 8 Nov 2024 16:58:16 +0200 Subject: [PATCH 002/105] fix(DB/SAI): Arzeth the Merciless not moving on respawn (#20442) --- .../updates/pending_db_world/rev_1730802205082380900.sql | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1730802205082380900.sql diff --git a/data/sql/updates/pending_db_world/rev_1730802205082380900.sql b/data/sql/updates/pending_db_world/rev_1730802205082380900.sql new file mode 100644 index 00000000000000..a8bb7db3a51cfc --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730802205082380900.sql @@ -0,0 +1,6 @@ +-- Arzeth the Merciless +UPDATE `creature` SET `position_x`=-659.412, `position_y`=4799.82, `position_z`=49.0951 WHERE `guid` = 69051 AND `id1` = 19354; + +DELETE FROM `smart_scripts` WHERE `source_type` = 0 AND `entryorguid` = 19354 AND `id` = 7; +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(19354, 0, 7, 0, 11, 0, 100, 0, 0, 0, 0, 0, 0, 0, 232, 690510, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Arzeth the Merciless - On Respawn - Start Path '); From b2e6aef6ba03ce17ad5429349aeec8301b7130a5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 8 Nov 2024 14:59:09 +0000 Subject: [PATCH 003/105] chore(DB): import pending files Referenced commit(s): 8569edb706dc591c53cdf1733dd2879f1098ab40 --- .../rev_1730802205082380900.sql => db_world/2024_11_08_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1730802205082380900.sql => db_world/2024_11_08_00.sql} (95%) diff --git a/data/sql/updates/pending_db_world/rev_1730802205082380900.sql b/data/sql/updates/db_world/2024_11_08_00.sql similarity index 95% rename from data/sql/updates/pending_db_world/rev_1730802205082380900.sql rename to data/sql/updates/db_world/2024_11_08_00.sql index a8bb7db3a51cfc..2a055bb704f60a 100644 --- a/data/sql/updates/pending_db_world/rev_1730802205082380900.sql +++ b/data/sql/updates/db_world/2024_11_08_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_07_06 -> 2024_11_08_00 -- Arzeth the Merciless UPDATE `creature` SET `position_x`=-659.412, `position_y`=4799.82, `position_z`=49.0951 WHERE `guid` = 69051 AND `id1` = 19354; From d6840664c79db735c95412fc5215420326a13fc5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francesco=20Borz=C3=AC?= Date: Fri, 8 Nov 2024 22:20:50 +0100 Subject: [PATCH 004/105] refactor(src/tools): remove unused imports (#20487) --- src/tools/map_extractor/dbcfile.cpp | 1 - src/tools/map_extractor/dbcfile.h | 1 - src/tools/map_extractor/mpq_libmpq04.h | 1 - src/tools/mmaps_generator/IntermediateValues.h | 2 -- src/tools/mmaps_generator/MapBuilder.cpp | 1 - src/tools/mmaps_generator/MapBuilder.h | 2 -- src/tools/mmaps_generator/PathCommon.h | 1 - src/tools/mmaps_generator/TerrainBuilder.cpp | 1 + src/tools/mmaps_generator/TerrainBuilder.h | 1 - src/tools/vmap4_extractor/adtfile.cpp | 1 - src/tools/vmap4_extractor/dbcfile.cpp | 1 - src/tools/vmap4_extractor/dbcfile.h | 1 - src/tools/vmap4_extractor/gameobject_extract.cpp | 1 - src/tools/vmap4_extractor/model.h | 1 - src/tools/vmap4_extractor/mpq_libmpq04.h | 1 - src/tools/vmap4_extractor/wdtfile.h | 1 - src/tools/vmap4_extractor/wmo.cpp | 1 - 17 files changed, 1 insertion(+), 18 deletions(-) diff --git a/src/tools/map_extractor/dbcfile.cpp b/src/tools/map_extractor/dbcfile.cpp index b349dfc756dc98..589511666d8341 100644 --- a/src/tools/map_extractor/dbcfile.cpp +++ b/src/tools/map_extractor/dbcfile.cpp @@ -20,7 +20,6 @@ #include "dbcfile.h" #include "mpq_libmpq04.h" -#include DBCFile::DBCFile(std::string filename): filename(std::move(filename)), recordSize(0), recordCount(0), fieldCount(0), stringSize(0), data(nullptr), stringTable(nullptr) diff --git a/src/tools/map_extractor/dbcfile.h b/src/tools/map_extractor/dbcfile.h index b8158811b3d515..5fd5365938969a 100644 --- a/src/tools/map_extractor/dbcfile.h +++ b/src/tools/map_extractor/dbcfile.h @@ -19,7 +19,6 @@ #define DBCFILE_H #include #include -#include // cppcheck-suppress ctuOneDefinitionRuleViolation class DBCFile diff --git a/src/tools/map_extractor/mpq_libmpq04.h b/src/tools/map_extractor/mpq_libmpq04.h index c7483e25bc29c0..dece851e9e50df 100644 --- a/src/tools/map_extractor/mpq_libmpq04.h +++ b/src/tools/map_extractor/mpq_libmpq04.h @@ -20,7 +20,6 @@ #include "libmpq/mpq.h" #include "loadlib/loadlib.h" -#include #include #include #include diff --git a/src/tools/mmaps_generator/IntermediateValues.h b/src/tools/mmaps_generator/IntermediateValues.h index 85d127a9e11cfc..971cf9000a265c 100644 --- a/src/tools/mmaps_generator/IntermediateValues.h +++ b/src/tools/mmaps_generator/IntermediateValues.h @@ -18,8 +18,6 @@ #ifndef _INTERMEDIATE_VALUES_H #define _INTERMEDIATE_VALUES_H -#include "DetourNavMesh.h" -#include "PathCommon.h" #include "Recast.h" #include "TerrainBuilder.h" diff --git a/src/tools/mmaps_generator/MapBuilder.cpp b/src/tools/mmaps_generator/MapBuilder.cpp index aa35cee056e080..407cdb103c83b5 100644 --- a/src/tools/mmaps_generator/MapBuilder.cpp +++ b/src/tools/mmaps_generator/MapBuilder.cpp @@ -22,7 +22,6 @@ #include "ModelInstance.h" #include "PathCommon.h" #include "StringFormat.h" -#include "VMapFactory.h" #include "VMapMgr2.h" #include #include diff --git a/src/tools/mmaps_generator/MapBuilder.h b/src/tools/mmaps_generator/MapBuilder.h index 59b865e047e804..19ef1ef59f6935 100644 --- a/src/tools/mmaps_generator/MapBuilder.h +++ b/src/tools/mmaps_generator/MapBuilder.h @@ -20,12 +20,10 @@ #include #include -#include #include #include #include -#include "IntermediateValues.h" #include "Optional.h" #include "TerrainBuilder.h" diff --git a/src/tools/mmaps_generator/PathCommon.h b/src/tools/mmaps_generator/PathCommon.h index 8e15a8cf3e94d6..866dffb6889309 100644 --- a/src/tools/mmaps_generator/PathCommon.h +++ b/src/tools/mmaps_generator/PathCommon.h @@ -18,7 +18,6 @@ #ifndef _MMAP_COMMON_H #define _MMAP_COMMON_H -#include "Common.h" #include #include diff --git a/src/tools/mmaps_generator/TerrainBuilder.cpp b/src/tools/mmaps_generator/TerrainBuilder.cpp index 0e394488ce7957..2faee49d940167 100644 --- a/src/tools/mmaps_generator/TerrainBuilder.cpp +++ b/src/tools/mmaps_generator/TerrainBuilder.cpp @@ -23,6 +23,7 @@ #include "PathCommon.h" #include "VMapMgr2.h" #include +#include // ****************************************** // Map file format defines diff --git a/src/tools/mmaps_generator/TerrainBuilder.h b/src/tools/mmaps_generator/TerrainBuilder.h index 2c0a00af49ed04..23cdbc47109374 100644 --- a/src/tools/mmaps_generator/TerrainBuilder.h +++ b/src/tools/mmaps_generator/TerrainBuilder.h @@ -18,7 +18,6 @@ #ifndef _MMAP_TERRAIN_BUILDER_H #define _MMAP_TERRAIN_BUILDER_H -#include "PathCommon.h" #include "WorldModel.h" #include "G3D/Array.h" diff --git a/src/tools/vmap4_extractor/adtfile.cpp b/src/tools/vmap4_extractor/adtfile.cpp index 5af0937ed10536..6db292bc867b48 100644 --- a/src/tools/vmap4_extractor/adtfile.cpp +++ b/src/tools/vmap4_extractor/adtfile.cpp @@ -17,7 +17,6 @@ #include "adtfile.h" #include "vmapexport.h" -#include #include #ifdef WIN32 diff --git a/src/tools/vmap4_extractor/dbcfile.cpp b/src/tools/vmap4_extractor/dbcfile.cpp index 61e0993acdeef8..3e6351b14163e0 100644 --- a/src/tools/vmap4_extractor/dbcfile.cpp +++ b/src/tools/vmap4_extractor/dbcfile.cpp @@ -21,7 +21,6 @@ #undef max #include -#include DBCFile::DBCFile(std::string filename): filename(std::move(filename)), recordSize(0), recordCount(0), fieldCount(0), stringSize(0), data(nullptr), stringTable(nullptr) diff --git a/src/tools/vmap4_extractor/dbcfile.h b/src/tools/vmap4_extractor/dbcfile.h index adde0b2ae158f1..ad7a4bb703b72b 100644 --- a/src/tools/vmap4_extractor/dbcfile.h +++ b/src/tools/vmap4_extractor/dbcfile.h @@ -20,7 +20,6 @@ #include #include -#include class DBCFile { diff --git a/src/tools/vmap4_extractor/gameobject_extract.cpp b/src/tools/vmap4_extractor/gameobject_extract.cpp index 0bcc9c2da039ff..fd7160e7836bac 100644 --- a/src/tools/vmap4_extractor/gameobject_extract.cpp +++ b/src/tools/vmap4_extractor/gameobject_extract.cpp @@ -19,7 +19,6 @@ #include "dbcfile.h" #include "model.h" #include "vmapexport.h" -#include #include bool ExtractSingleModel(std::string& fname) diff --git a/src/tools/vmap4_extractor/model.h b/src/tools/vmap4_extractor/model.h index 6b4e3e0c8a6c57..021d1dedbaee92 100644 --- a/src/tools/vmap4_extractor/model.h +++ b/src/tools/vmap4_extractor/model.h @@ -21,7 +21,6 @@ #include "loadlib/loadlib.h" #include "modelheaders.h" #include "vec3d.h" -#include class MPQFile; struct WMODoodadData; diff --git a/src/tools/vmap4_extractor/mpq_libmpq04.h b/src/tools/vmap4_extractor/mpq_libmpq04.h index 1cceb1faf14a2e..5b6c81ce3b7f5a 100644 --- a/src/tools/vmap4_extractor/mpq_libmpq04.h +++ b/src/tools/vmap4_extractor/mpq_libmpq04.h @@ -20,7 +20,6 @@ #include "libmpq/mpq.h" #include "loadlib/loadlib.h" -#include #include #include #include diff --git a/src/tools/vmap4_extractor/wdtfile.h b/src/tools/vmap4_extractor/wdtfile.h index 1ff934ca430507..e2a6a61dfea628 100644 --- a/src/tools/vmap4_extractor/wdtfile.h +++ b/src/tools/vmap4_extractor/wdtfile.h @@ -20,7 +20,6 @@ #include "mpq_libmpq04.h" #include "wmo.h" -#include #include class ADTFile; diff --git a/src/tools/vmap4_extractor/wmo.cpp b/src/tools/vmap4_extractor/wmo.cpp index af34818c7ac674..c0d6c0bbe7be2a 100644 --- a/src/tools/vmap4_extractor/wmo.cpp +++ b/src/tools/vmap4_extractor/wmo.cpp @@ -23,7 +23,6 @@ #include #include #include -#include #undef min #undef max #include "mpq_libmpq04.h" From 138a2ca9740c602c21eb6a64df2dff103a90db3a Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Fri, 8 Nov 2024 21:05:30 -0300 Subject: [PATCH 005/105] refactor(Scripts/ZA): Update Zul'jin (#20456) --- .../rev_1730866003318081300.sql | 10 + .../game/Spells/SpellInfoCorrections.cpp | 6 + .../EasternKingdoms/ZulAman/boss_zuljin.cpp | 681 +++++++----------- .../ZulAman/instance_zulaman.cpp | 32 +- .../scripts/EasternKingdoms/ZulAman/zulaman.h | 2 +- 5 files changed, 272 insertions(+), 459 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1730866003318081300.sql diff --git a/data/sql/updates/pending_db_world/rev_1730866003318081300.sql b/data/sql/updates/pending_db_world/rev_1730866003318081300.sql new file mode 100644 index 00000000000000..f8d580e95a02e7 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730866003318081300.sql @@ -0,0 +1,10 @@ +-- +DELETE FROM `spell_script_names` WHERE `spell_id` = 43149; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(43149, 'spell_claw_rage_aura'); + +UPDATE `creature_template` SET `unit_flags` = `unit_flags` |2 WHERE `entry` IN (23878, 23880, 23877, 23879); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 13 AND `SourceEntry` = 42542; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 42542, 0, 0, 31, 0, 3, 23863, 0, 0, 0, 0, '', 'Cosmetic - Zul\'Aman Spirit Drain can only target Zul\'jin'); diff --git a/src/server/game/Spells/SpellInfoCorrections.cpp b/src/server/game/Spells/SpellInfoCorrections.cpp index a0fd2ce8c8b7d7..6863984ceaf3b8 100644 --- a/src/server/game/Spells/SpellInfoCorrections.cpp +++ b/src/server/game/Spells/SpellInfoCorrections.cpp @@ -4856,6 +4856,12 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->AttributesEx3 |= SPELL_ATTR3_SUPPRESS_CASTER_PROCS; }); + // Claw Rage + ApplySpellFix({ 43149 }, [](SpellInfo* spellInfo) + { + spellInfo->Effects[EFFECT_0].TriggerSpell = 0; + }); + // Black Qiraji Battle Tank ApplySpellFix({ 26655, 26656 }, [](SpellInfo* spellInfo) { diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp index a13bc3448a36fc..c7a9cd3d68fa02 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp @@ -22,22 +22,25 @@ SD%Complete: 85% EndScriptData */ #include "CreatureScript.h" +#include "Player.h" #include "ScriptedCreature.h" #include "SpellInfo.h" +#include "SpellScript.h" +#include "SpellScriptLoader.h" #include "zulaman.h" enum Says { - YELL_INTRO = 0, - YELL_AGGRO = 1, - YELL_TRANSFORM_TO_BEAR = 2, - YELL_TRANSFORM_TO_EAGLE = 3, - YELL_TRANSFORM_TO_LYNX = 4, - YELL_TRANSFORM_TO_DRAGONHAWK = 5, - YELL_FIRE_BREATH = 6, - YELL_BERSERK = 7, - YELL_KILL = 8, - YELL_DEATH = 9 + SAY_INTRO = 0, + SAY_AGGRO = 1, + SAY_TRANSFORM_TO_BEAR = 2, + SAY_TRANSFORM_TO_EAGLE = 3, + SAY_TRANSFORM_TO_LYNX = 4, + SAY_TRANSFORM_TO_DRAGONHAWK = 5, + SAY_FIRE_BREATH = 6, + SAY_BERSERK = 7, + SAY_KILL = 8, + SAY_DEATH = 9 }; enum Spells @@ -57,8 +60,8 @@ enum Spells SPELL_CYCLONE_VISUAL = 43119, // trigger 43147 visual SPELL_CYCLONE_PASSIVE = 43120, // trigger 43121 (4y aoe) every second // Lynx Form - SPELL_CLAW_RAGE_HASTE = 42583, - SPELL_CLAW_RAGE_TRIGGER = 43149, + SPELL_CLAW_RAGE_CHARGE = 42583, + SPELL_CLAW_RAGE_AURA = 43149, SPELL_CLAW_RAGE_DAMAGE = 43150, SPELL_LYNX_RUSH_HASTE = 43152, SPELL_LYNX_RUSH_DAMAGE = 43153, @@ -70,7 +73,7 @@ enum Spells SPELL_PILLAR_TRIGGER = 43218, // trigger 43217 // Cosmetic SPELL_SPIRIT_AURA = 42466, - SPELL_SIPHON_SOUL = 43501, + SPELL_SPIRIT_DRAIN = 42542, // Transforms: SPELL_SHAPE_OF_THE_BEAR = 42594, // 15% dmg SPELL_SHAPE_OF_THE_EAGLE = 42606, @@ -89,517 +92,325 @@ enum Phase PHASE_TROLL = 4 }; -//coords for going for changing form -#define CENTER_X 120.148811f -#define CENTER_Y 703.713684f -#define CENTER_Z 45.111477f +enum Misc +{ + GUID_CHARGE_TARGET = 0, + GROUP_LYNX = 1, + POINT_CENTER = 0 +}; + +enum CreatureEntries +{ + NPC_SPIRIT_BEAR = 23878, + NPC_SPIRIT_EAGLE = 23880, + NPC_SPIRIT_LYNX_ZJ = 23877, + NPC_SPIRIT_DRAGONHAWK = 23879 +}; + +const Position CenterPosition = { 120.148811f, 703.713684f, 45.111477f }; struct SpiritInfoStruct { uint32 entry; - float x, y, z, orient; + Position pos; }; static SpiritInfoStruct SpiritInfo[4] = { - {23878, 147.87f, 706.51f, 45.11f, 3.04f}, - {23880, 88.95f, 705.49f, 45.11f, 6.11f}, - {23877, 137.23f, 725.98f, 45.11f, 3.71f}, - {23879, 104.29f, 726.43f, 45.11f, 5.43f} + { NPC_SPIRIT_LYNX_ZJ, { 147.87f, 706.51f, 45.11f, 3.04f } }, + { NPC_SPIRIT_DRAGONHAWK, { 88.95f, 705.49f, 45.11f, 6.11f } }, + { NPC_SPIRIT_BEAR, { 137.23f, 725.98f, 45.11f, 3.71f } }, + { NPC_SPIRIT_EAGLE, { 104.29f, 726.43f, 45.11f, 5.43f } } }; struct TransformStruct { uint8 text; - uint32 spell, unaura; + uint32 spell; + uint32 unaura; + uint32 spiritEntry; }; static TransformStruct Transform[4] = { - {YELL_TRANSFORM_TO_BEAR, SPELL_SHAPE_OF_THE_BEAR, SPELL_WHIRLWIND}, - {YELL_TRANSFORM_TO_EAGLE, SPELL_SHAPE_OF_THE_EAGLE, SPELL_SHAPE_OF_THE_BEAR}, - {YELL_TRANSFORM_TO_LYNX, SPELL_SHAPE_OF_THE_LYNX, SPELL_SHAPE_OF_THE_EAGLE}, - {YELL_TRANSFORM_TO_DRAGONHAWK, SPELL_SHAPE_OF_THE_DRAGONHAWK, SPELL_SHAPE_OF_THE_LYNX} + { SAY_TRANSFORM_TO_BEAR, SPELL_SHAPE_OF_THE_BEAR, SPELL_WHIRLWIND, NPC_SPIRIT_BEAR }, + { SAY_TRANSFORM_TO_EAGLE, SPELL_SHAPE_OF_THE_EAGLE, SPELL_SHAPE_OF_THE_BEAR, NPC_SPIRIT_EAGLE }, + { SAY_TRANSFORM_TO_LYNX, SPELL_SHAPE_OF_THE_LYNX, SPELL_SHAPE_OF_THE_EAGLE, NPC_SPIRIT_LYNX_ZJ }, + { SAY_TRANSFORM_TO_DRAGONHAWK, SPELL_SHAPE_OF_THE_DRAGONHAWK, SPELL_SHAPE_OF_THE_LYNX, NPC_SPIRIT_DRAGONHAWK } }; -class boss_zuljin : public CreatureScript +struct boss_zuljin : public BossAI { -public: - boss_zuljin() - : CreatureScript("boss_zuljin") + boss_zuljin(Creature* creature) : BossAI(creature, DATA_ZULJIN) { } + + void Reset() override { + _Reset(); + me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 33975); + me->SetCombatMovement(true); + me->m_Events.KillAllEvents(false); + _nextPhase = 0; } - struct boss_zuljinAI : public ScriptedAI + void JustEngagedWith(Unit* /*who*/) override { - boss_zuljinAI(Creature* creature) : ScriptedAI(creature), Summons(me) - { - instance = creature->GetInstanceScript(); - } - InstanceScript* instance; - - ObjectGuid SpiritGUID[4]; - ObjectGuid ClawTargetGUID; - ObjectGuid TankGUID; - - uint32 Phase; - uint32 health_20; - - uint32 Intro_Timer; - uint32 Berserk_Timer; - - uint32 Whirlwind_Timer; - uint32 Grievous_Throw_Timer; - - uint32 Creeping_Paralysis_Timer; - uint32 Overpower_Timer; - - uint32 Claw_Rage_Timer; - uint32 Lynx_Rush_Timer; - uint32 Claw_Counter; - uint32 Claw_Loop_Timer; - - uint32 Flame_Whirl_Timer; - uint32 Flame_Breath_Timer; - uint32 Pillar_Of_Fire_Timer; - - SummonList Summons; + _JustEngagedWith(); + DoZoneInCombat(); - void Reset() override - { - Phase = 0; + Talk(SAY_INTRO); + SpawnAdds(); - health_20 = me->CountPctFromMaxHealth(20); + Talk(SAY_AGGRO, 37s); - Intro_Timer = 37000; - Berserk_Timer = 600000; + // Phase 1: Default (troll) + ScheduleTimedEvent(7s, [&] { + DoCastAOE(SPELL_WHIRLWIND); + }, 15s, 20s); - Whirlwind_Timer = 7000; - Grievous_Throw_Timer = 8000; + ScheduleTimedEvent(8s, [&] { + DoCastRandomTarget(SPELL_GRIEVOUS_THROW, 0, 100.0f); + }, 10s); - Creeping_Paralysis_Timer = 7000; - Overpower_Timer = 0; + me->m_Events.AddEventAtOffset([&]() { + DoCastSelf(SPELL_BERSERK, true); + Talk(SAY_BERSERK); + }, 10min); - Claw_Rage_Timer = 5000; - Lynx_Rush_Timer = 14000; - Claw_Loop_Timer = 0; - Claw_Counter = 0; + // Phase 2: Bear Form. + ScheduleHealthCheckEvent({ 80 }, [&] { + EnterPhase(PHASE_BEAR); + ScheduleTimedEvent(7s, [&] { + DoCastAOE(SPELL_CREEPING_PARALYSIS); + }, 20s); - Flame_Whirl_Timer = 5000; - Flame_Breath_Timer = 6000; - Pillar_Of_Fire_Timer = 7000; + ScheduleTimedEvent(1s, [&] { + if (!me->HasSpellCooldown(SPELL_OVERPOWER)) + { + if (me->GetVictim() && me->GetComboPoints()) + DoCastVictim(SPELL_OVERPOWER); + } + }, 1s); + }); + + // Phase 3: Eagle Form. + ScheduleHealthCheckEvent({ 60 }, [&] { + EnterPhase(PHASE_EAGLE); + }); + + // Phase 4: Lynx Form. + ScheduleHealthCheckEvent({ 40 }, [&] { + EnterPhase(PHASE_LYNX); + me->RemoveAurasDueToSpell(SPELL_ENERGY_STORM); + instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_ENERGY_STORM); + summons.DespawnEntry(CREATURE_FEATHER_VORTEX); + me->ResumeChasingVictim(); + + ScheduleTimedEvent(5s, [&] { + DoCastRandomTarget(SPELL_CLAW_RAGE_CHARGE); + }, 15s, 20s); + + ScheduleTimedEvent(14s, [&] { + DoCastSelf(SPELL_LYNX_RUSH_HASTE); + + for (int8 count = 0; count <= 8; ++count) + { + me->m_Events.AddEventAtOffset([&] { + DoCastRandomTarget(SPELL_LYNX_RUSH_DAMAGE); + }, Seconds(1 * count), Seconds(1 * count), GROUP_LYNX); + } - ClawTargetGUID.Clear(); - TankGUID.Clear(); + }, 15s, 20s); + }); - Summons.DespawnAll(); + // Phase 5: Dragonhawk Form. + ScheduleHealthCheckEvent({ 20 }, [&] { + me->m_Events.CancelEventGroup(GROUP_LYNX); + EnterPhase(PHASE_DRAGONHAWK); - me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 33975); - //me->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, 218172674); - //me->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE); - } + ScheduleTimedEvent(5s, [&] { + DoCastSelf(SPELL_FLAME_WHIRL); + }, 12s); - void JustEngagedWith(Unit* /*who*/) override - { - DoZoneInCombat(); + ScheduleTimedEvent(6s, [&] { + DoCastRandomTarget(SPELL_SUMMON_PILLAR); + }, 10s); - Talk(YELL_INTRO); - SpawnAdds(); - EnterPhase(0); - } + ScheduleTimedEvent(7s, [&] { + DoCastAOE(SPELL_FLAME_BREATH); + }, 10s); + }); + } - void KilledUnit(Unit* /*victim*/) override + void SpellHitTarget(Unit* target, SpellInfo const* spellInfo) override + { + if (spellInfo->Id == SPELL_CLAW_RAGE_CHARGE && target != me) { - if (Intro_Timer) - return; - - Talk(YELL_KILL); + DoCastSelf(SPELL_CLAW_RAGE_AURA); + _chargeTargetGUID = target->GetGUID(); } + } - void JustDied(Unit* /*killer*/) override - { - instance->SetData(DATA_ZULJIN, DONE); + void KilledUnit(Unit* /*victim*/) override + { + Talk(SAY_KILL); + } - Talk(YELL_DEATH); - Summons.DespawnEntry(CREATURE_COLUMN_OF_FIRE); + ObjectGuid GetGUID(int32 index) const override + { + if (index == GUID_CHARGE_TARGET) + return _chargeTargetGUID; - if (Unit* Temp = ObjectAccessor::GetUnit(*me, SpiritGUID[3])) - Temp->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_DEAD); - } + return ObjectGuid::Empty; + } - void AttackStart(Unit* who) override - { - if (Phase == 2) - AttackStartNoMove(who); - else - ScriptedAI::AttackStart(who); - } + void JustDied(Unit* /*killer*/) override + { + instance->SetBossState(DATA_ZULJIN, DONE); + Talk(SAY_DEATH); + summons.DespawnEntry(CREATURE_COLUMN_OF_FIRE); + } - void DoMeleeAttackIfReady() + void SpawnAdds() + { + for (auto const& spiritInfo : SpiritInfo) { - if (!me->IsNonMeleeSpellCast(false)) + if (Creature* creature = me->SummonCreature(spiritInfo.entry, spiritInfo.pos, TEMPSUMMON_DEAD_DESPAWN, 0)) { - if (me->isAttackReady() && me->IsWithinMeleeRange(me->GetVictim())) - { - if (Phase == 1 && !Overpower_Timer) - { - uint32 health = me->GetVictim()->GetHealth(); - me->AttackerStateUpdate(me->GetVictim()); - if (me->GetVictim() && health == me->GetVictim()->GetHealth()) - { - DoCastVictim(SPELL_OVERPOWER, false); - Overpower_Timer = 5000; - } - } - else me->AttackerStateUpdate(me->GetVictim()); - me->resetAttackTimer(); - } + creature->m_Events.AddEventAtOffset([creature] { + creature->CastSpell(creature, SPELL_SPIRIT_AURA); + }, 1s); } } + } - void SpawnAdds() + void MovementInform(uint32 type, uint32 id) override + { + if (type == POINT_MOTION_TYPE && id == POINT_CENTER) { - for (uint8 i = 0; i < 4; ++i) + if (Creature* spirit = summons.GetCreatureWithEntry(Transform[_nextPhase].spiritEntry)) { - Creature* creature = me->SummonCreature(SpiritInfo[i].entry, SpiritInfo[i].x, SpiritInfo[i].y, SpiritInfo[i].z, SpiritInfo[i].orient, TEMPSUMMON_DEAD_DESPAWN, 0); - if (creature) - { - creature->CastSpell(creature, SPELL_SPIRIT_AURA, true); - creature->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - creature->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - SpiritGUID[i] = creature->GetGUID(); - } + spirit->CastSpell(me, SPELL_SPIRIT_DRAIN, false); + me->SetFacingToObject(spirit); } - } - void DespawnAdds() - { - for (uint8 i = 0; i < 4; ++i) - { - if (SpiritGUID[i]) + if (_nextPhase) + if (Creature* spirit = summons.GetCreatureWithEntry(Transform[_nextPhase - 1].spiritEntry)) { - if (Unit* temp = ObjectAccessor::GetUnit(*me, SpiritGUID[i])) - { - temp->SetVisible(false); - temp->setDeathState(DeathState::Dead); - } + spirit->CastStop(); + spirit->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_DEAD); } - SpiritGUID[i].Clear(); - } - } - void JustSummoned(Creature* summon) override - { - Summons.Summon(summon); - } + Talk(Transform[_nextPhase].text); - void SummonedCreatureDespawn(Creature* summon) override - { - Summons.Despawn(summon); - } + me->m_Events.AddEventAtOffset([&] { + me->SetReactState(REACT_AGGRESSIVE); + DoCastSelf(Transform[_nextPhase].spell); - void EnterPhase(uint32 NextPhase) - { - switch (NextPhase) - { - case 0: - break; - case 1: - case 2: - case 3: - case 4: - me->NearTeleportTo(CENTER_X, CENTER_Y, CENTER_Z, me->GetOrientation()); - DoResetThreatList(); - me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0); - me->RemoveAurasDueToSpell(Transform[Phase].unaura); - DoCast(me, Transform[Phase].spell); - Talk(Transform[Phase].text); - if (Phase > 0) - { - if (Unit* Temp = ObjectAccessor::GetUnit(*me, SpiritGUID[Phase - 1])) - Temp->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_DEAD); - } - if (Unit* Temp = ObjectAccessor::GetUnit(*me, SpiritGUID[NextPhase - 1])) - Temp->CastSpell(me, SPELL_SIPHON_SOUL, false); // should m cast on temp - if (NextPhase == 2) + if (_nextPhase == PHASE_EAGLE) + { + me->SetCombatMovement(false); + DoCastSelf(SPELL_ENERGY_STORM, true); // enemy aura + for (uint8 i = 0; i < 4; ++i) { - me->GetMotionMaster()->Clear(); - DoCast(me, SPELL_ENERGY_STORM, true); // enemy aura - for (uint8 i = 0; i < 4; ++i) + if (Creature* vortex = DoSpawnCreature(CREATURE_FEATHER_VORTEX, 0, 0, 0, 0, TEMPSUMMON_CORPSE_DESPAWN, 0)) { - Creature* Vortex = DoSpawnCreature(CREATURE_FEATHER_VORTEX, 0, 0, 0, 0, TEMPSUMMON_CORPSE_DESPAWN, 0); - if (Vortex) - { - Vortex->CastSpell(Vortex, SPELL_CYCLONE_PASSIVE, true); - Vortex->CastSpell(Vortex, SPELL_CYCLONE_VISUAL, true); - Vortex->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - Vortex->SetSpeed(MOVE_RUN, 1.0f); - Vortex->AI()->AttackStart(SelectTarget(SelectTargetMethod::Random, 0)); - DoZoneInCombat(Vortex); - } + vortex->CastSpell(vortex, SPELL_CYCLONE_PASSIVE, true); + vortex->CastSpell(vortex, SPELL_CYCLONE_VISUAL, true); + vortex->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + vortex->SetSpeed(MOVE_RUN, 1.0f); + DoZoneInCombat(vortex); } } - else - AttackStart(me->GetVictim()); - if (NextPhase == 3) - { - me->RemoveAurasDueToSpell(SPELL_ENERGY_STORM); - Summons.DespawnEntry(CREATURE_FEATHER_VORTEX); - me->GetMotionMaster()->MoveChase(me->GetVictim()); - } - break; - default: - break; - } - Phase = NextPhase; + } + else + { + me->SetCombatMovement(true); + me->ResumeChasingVictim(); + } + }, 2s); } + } - void UpdateAI(uint32 diff) override - { - if (!TankGUID) - { - if (!UpdateVictim()) - return; - - if (me->GetHealth() < health_20 * (4 - Phase)) - EnterPhase(Phase + 1); - } - - if (Berserk_Timer <= diff) - { - DoCast(me, SPELL_BERSERK, true); - Talk(YELL_BERSERK); - Berserk_Timer = 60000; - } - else Berserk_Timer -= diff; - - switch (Phase) - { - case 0: - if (Intro_Timer) - { - if (Intro_Timer <= diff) - { - Talk(YELL_AGGRO); - Intro_Timer = 0; - } - else Intro_Timer -= diff; - } - - if (Whirlwind_Timer <= diff) - { - DoCast(me, SPELL_WHIRLWIND); - Whirlwind_Timer = urand(15000, 20000); - } - else Whirlwind_Timer -= diff; - - if (Grievous_Throw_Timer <= diff) - { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 100, true)) - DoCast(target, SPELL_GRIEVOUS_THROW, false); - Grievous_Throw_Timer = 10000; - } - else Grievous_Throw_Timer -= diff; - break; - - case 1: - if (Creeping_Paralysis_Timer <= diff) - { - DoCast(me, SPELL_CREEPING_PARALYSIS); - Creeping_Paralysis_Timer = 20000; - } - else Creeping_Paralysis_Timer -= diff; + void EnterPhase(uint32 NextPhase) + { + scheduler.CancelAll(); + me->SetReactState(REACT_PASSIVE); + DoStopAttack(); + me->GetMotionMaster()->Clear(); + DoResetThreatList(); - if (Overpower_Timer <= diff) - { - // implemented in DoMeleeAttackIfReady() - Overpower_Timer = 0; - } - else Overpower_Timer -= diff; - break; + me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0); + me->RemoveAurasDueToSpell(Transform[NextPhase].unaura); - case 2: - return; + me->m_Events.AddEventAtOffset([&] { + me->GetMotionMaster()->MovePoint(POINT_CENTER, CenterPosition); + }, 1s); - case 3: - if (Claw_Rage_Timer <= diff) - { - if (!TankGUID) - { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - { - TankGUID = me->GetVictim()->GetGUID(); - me->SetSpeed(MOVE_RUN, 5.0f); - AttackStart(target); // change victim - Claw_Rage_Timer = 0; - Claw_Loop_Timer = 500; - Claw_Counter = 0; - } - } - else if (!Claw_Rage_Timer) // do not do this when Lynx_Rush - { - if (Claw_Loop_Timer <= diff) - { - Unit* target = me->GetVictim(); - if (!target || !target->isTargetableForAttack()) target = ObjectAccessor::GetUnit(*me, TankGUID); - if (!target || !target->isTargetableForAttack()) target = SelectTarget(SelectTargetMethod::Random, 0); - if (target) - { - AttackStart(target); - if (me->IsWithinMeleeRange(target)) - { - DoCast(target, SPELL_CLAW_RAGE_DAMAGE, true); - ++Claw_Counter; - if (Claw_Counter == 12) - { - Claw_Rage_Timer = urand(15000, 20000); - me->SetSpeed(MOVE_RUN, 1.2f); - AttackStart(ObjectAccessor::GetUnit(*me, TankGUID)); - TankGUID.Clear(); - return; - } - else - Claw_Loop_Timer = 500; - } - } - else - { - EnterEvadeMode(); // if (target) - return; - } - } - else Claw_Loop_Timer -= diff; - } //if (TankGUID) - } - else Claw_Rage_Timer -= diff; + _nextPhase = NextPhase; + } - if (Lynx_Rush_Timer <= diff) - { - if (!TankGUID) - { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - { - TankGUID = me->GetVictim()->GetGUID(); - me->SetSpeed(MOVE_RUN, 5.0f); - AttackStart(target); // change victim - Lynx_Rush_Timer = 0; - Claw_Counter = 0; - } - } - else if (!Lynx_Rush_Timer) - { - Unit* target = me->GetVictim(); - if (!target || !target->isTargetableForAttack()) - { - target = SelectTarget(SelectTargetMethod::Random, 0); - AttackStart(target); - } - if (target) - { - if (me->IsWithinMeleeRange(target)) - { - DoCast(target, SPELL_LYNX_RUSH_DAMAGE, true); - ++Claw_Counter; - if (Claw_Counter == 9) - { - Lynx_Rush_Timer = urand(15000, 20000); - me->SetSpeed(MOVE_RUN, 1.2f); - AttackStart(ObjectAccessor::GetUnit(*me, TankGUID)); - TankGUID.Clear(); - } - else - AttackStart(SelectTarget(SelectTargetMethod::Random, 0)); - } - } - else - { - EnterEvadeMode(); // if (target) - return; - } - } //if (TankGUID) - } - else Lynx_Rush_Timer -= diff; + private: + ObjectGuid _chargeTargetGUID; + uint8 _nextPhase; +}; - break; - case 4: - if (Flame_Whirl_Timer <= diff) - { - DoCast(me, SPELL_FLAME_WHIRL); - Flame_Whirl_Timer = 12000; - } - Flame_Whirl_Timer -= diff; +struct npc_zuljin_vortex : public ScriptedAI +{ + npc_zuljin_vortex(Creature* creature) : ScriptedAI(creature) { } - if (Pillar_Of_Fire_Timer <= diff) - { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - DoCast(target, SPELL_SUMMON_PILLAR); - Pillar_Of_Fire_Timer = 10000; - } - else Pillar_Of_Fire_Timer -= diff; + void Reset() override { } - if (Flame_Breath_Timer <= diff) - { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - me->SetInFront(target); - DoCast(me, SPELL_FLAME_BREATH); - Flame_Breath_Timer = 10000; - } - else Flame_Breath_Timer -= diff; - break; + void JustEngagedWith(Unit* /*target*/) override { } - default: - break; - } - - if (!TankGUID) - DoMeleeAttackIfReady(); - } - }; + void SpellHit(Unit* caster, SpellInfo const* spell) override + { + if (spell->Id == SPELL_ZAP_INFORM) + DoCast(caster, SPELL_ZAP_DAMAGE, true); + } - CreatureAI* GetAI(Creature* creature) const override + void UpdateAI(uint32 /*diff*/) override { - return GetZulAmanAI(creature); + //if the vortex reach the target, it change his target to another player + if (me->IsWithinMeleeRange(me->GetVictim())) + AttackStart(SelectTarget(SelectTargetMethod::Random, 0)); } }; -class npc_zuljin_vortex : public CreatureScript +// 43149 - Claw Rage +class spell_claw_rage_aura : public AuraScript { -public: - npc_zuljin_vortex() - : CreatureScript("npc_zuljin_vortex") + PrepareAuraScript(spell_claw_rage_aura); + + bool Validate(SpellInfo const* /*spellInfo*/) override { + return ValidateSpellInfo({ SPELL_CLAW_RAGE_DAMAGE }); } - struct npc_zuljin_vortexAI : public ScriptedAI + void OnPeriodic(AuraEffect const* /*aurEff*/) { - npc_zuljin_vortexAI(Creature* creature) : ScriptedAI(creature) { } - - void Reset() override { } - - void JustEngagedWith(Unit* /*target*/) override { } - - void SpellHit(Unit* caster, SpellInfo const* spell) override - { - if (spell->Id == SPELL_ZAP_INFORM) - DoCast(caster, SPELL_ZAP_DAMAGE, true); - } - - void UpdateAI(uint32 /*diff*/) override + if (Creature* caster = GetCaster()->ToCreature()) { - //if the vortex reach the target, it change his target to another player - if (me->IsWithinMeleeRange(me->GetVictim())) - AttackStart(SelectTarget(SelectTargetMethod::Random, 0)); + if (Player* target = ObjectAccessor::GetPlayer(*caster, caster->AI()->GetGUID(GUID_CHARGE_TARGET))) + { + if (target->isTargetableForAttack(true, caster)) + GetCaster()->CastSpell(target, SPELL_CLAW_RAGE_DAMAGE); + else + GetCaster()->RemoveAurasDueToSpell(SPELL_CLAW_RAGE_AURA); + } + else + GetCaster()->RemoveAurasDueToSpell(SPELL_CLAW_RAGE_AURA); } - }; + } - CreatureAI* GetAI(Creature* creature) const override + void Register() override { - return GetZulAmanAI(creature); + OnEffectPeriodic += AuraEffectPeriodicFn(spell_claw_rage_aura::OnPeriodic, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); } }; void AddSC_boss_zuljin() { - new boss_zuljin(); - new npc_zuljin_vortex(); + RegisterZulAmanCreatureAI(boss_zuljin); + RegisterZulAmanCreatureAI(npc_zuljin_vortex); + RegisterSpellScript(spell_claw_rage_aura); } diff --git a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp index f8847e74ad9440..ec3cd93ea69a65 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp @@ -54,6 +54,12 @@ static SHostageInfo HostageInfo[] = Position const HarrisonJonesLoc = {120.687f, 1674.0f, 42.0217f, 1.59044f}; +DoorData const doorData[] = +{ + { GO_ZULJIN_FIREWALL, DATA_ZULJIN, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END +}; + ObjectData const creatureData[] = { { NPC_SPIRIT_LYNX, DATA_SPIRIT_LYNX }, @@ -93,7 +99,6 @@ class instance_zulaman : public InstanceMapScript ObjectGuid ZulJinGateGUID; ObjectGuid MassiveGateGUID; ObjectGuid AkilzonDoorGUID; - ObjectGuid ZulJinDoorGUID; ObjectGuid HalazziDoorGUID; uint32 QuestTimer; @@ -111,6 +116,7 @@ class instance_zulaman : public InstanceMapScript memset(&m_auiEncounter, 0, sizeof(m_auiEncounter)); SetBossNumber(MAX_ENCOUNTER); LoadBossBoundaries(boundaries); + LoadDoorData(doorData); QuestTimer = 0; QuestMinute = 0; @@ -123,15 +129,6 @@ class instance_zulaman : public InstanceMapScript m_auiEncounter[DATA_GONGEVENT] = NOT_STARTED; } - bool IsEncounterInProgress() const override - { - for (uint8 i = 0; i < MAX_ENCOUNTER; ++i) - if (m_auiEncounter[i] == IN_PROGRESS) - return true; - - return false; - } - void OnPlayerEnter(Player* /*player*/) override { if (!HarrisonJonesGUID) @@ -145,11 +142,6 @@ class instance_zulaman : public InstanceMapScript case NPC_HARRISON_JONES: HarrisonJonesGUID = creature->GetGUID(); break; - case NPC_JANALAI: - case NPC_ZULJIN: - case NPC_HEXLORD: - case NPC_HALAZZI: - case NPC_NALORAKK: default: break; } @@ -175,9 +167,6 @@ class instance_zulaman : public InstanceMapScript case GO_DOOR_AKILZON: AkilzonDoorGUID = go->GetGUID(); break; - case GO_DOOR_ZULJIN: - ZulJinDoorGUID = go->GetGUID(); - break; case GO_HARKORS_SATCHEL: HarkorsSatchelGUID = go->GetGUID(); @@ -198,6 +187,8 @@ class instance_zulaman : public InstanceMapScript break; } CheckInstanceStatus(); + + InstanceScript::OnGameObjectCreate(go); } void SummonHostage(uint8 num) @@ -320,11 +311,6 @@ class instance_zulaman : public InstanceMapScript CheckInstanceStatus(); SaveToDB(); break; - case DATA_ZULJIN: - m_auiEncounter[DATA_ZULJIN] = data; - HandleGameObject(ZulJinDoorGUID, data != IN_PROGRESS); - SaveToDB(); - break; case DATA_CHESTLOOTED: ++ChestLooted; SaveToDB(); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h index a6f0d9ee916bae..a15512712582d4 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h @@ -61,7 +61,7 @@ enum GameobjectIds GO_GATE_HEXLORD = 186305, GO_MASSIVE_GATE = 186728, GO_DOOR_AKILZON = 186858, - GO_DOOR_ZULJIN = 186859, + GO_ZULJIN_FIREWALL = 186859, GO_HARKORS_SATCHEL = 187021, GO_TANZARS_TRUNK = 186648, GO_ASHLIS_BAG = 186672, From 9cdb42df9defe76defce58def5b3c30bde4d7f1b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 9 Nov 2024 00:06:27 +0000 Subject: [PATCH 006/105] chore(DB): import pending files Referenced commit(s): 138a2ca9740c602c21eb6a64df2dff103a90db3a --- .../rev_1730866003318081300.sql => db_world/2024_11_09_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1730866003318081300.sql => db_world/2024_11_09_00.sql} (94%) diff --git a/data/sql/updates/pending_db_world/rev_1730866003318081300.sql b/data/sql/updates/db_world/2024_11_09_00.sql similarity index 94% rename from data/sql/updates/pending_db_world/rev_1730866003318081300.sql rename to data/sql/updates/db_world/2024_11_09_00.sql index f8d580e95a02e7..48ef2031c36739 100644 --- a/data/sql/updates/pending_db_world/rev_1730866003318081300.sql +++ b/data/sql/updates/db_world/2024_11_09_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_08_00 -> 2024_11_09_00 -- DELETE FROM `spell_script_names` WHERE `spell_id` = 43149; INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES From f13bc5d7f77cef42aee6067f94d217496c6f37c7 Mon Sep 17 00:00:00 2001 From: IntelligentQuantum Date: Sat, 9 Nov 2024 15:30:43 +0330 Subject: [PATCH 007/105] fix(DB/Creature): Magma Elemental interrupt (#20458) Fix(Sql/Creature_template): Magma Elemental interrupt --- data/sql/updates/pending_db_world/rev_1730874923490368506.sql | 1 + 1 file changed, 1 insertion(+) create mode 100644 data/sql/updates/pending_db_world/rev_1730874923490368506.sql diff --git a/data/sql/updates/pending_db_world/rev_1730874923490368506.sql b/data/sql/updates/pending_db_world/rev_1730874923490368506.sql new file mode 100644 index 00000000000000..ea3f1d0c2a1c32 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730874923490368506.sql @@ -0,0 +1 @@ +UPDATE `creature_template` SET `mechanic_immune_mask` = `mechanic_immune_mask` & ~(33554432 | 67108864) WHERE `entry` = 5855; From 80a9af02d697a1d88db0ee9b75d6a09649fa146c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 9 Nov 2024 12:01:34 +0000 Subject: [PATCH 008/105] chore(DB): import pending files Referenced commit(s): f13bc5d7f77cef42aee6067f94d217496c6f37c7 --- .../rev_1730874923490368506.sql => db_world/2024_11_09_01.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1730874923490368506.sql => db_world/2024_11_09_01.sql} (74%) diff --git a/data/sql/updates/pending_db_world/rev_1730874923490368506.sql b/data/sql/updates/db_world/2024_11_09_01.sql similarity index 74% rename from data/sql/updates/pending_db_world/rev_1730874923490368506.sql rename to data/sql/updates/db_world/2024_11_09_01.sql index ea3f1d0c2a1c32..3b42236604b147 100644 --- a/data/sql/updates/pending_db_world/rev_1730874923490368506.sql +++ b/data/sql/updates/db_world/2024_11_09_01.sql @@ -1 +1,2 @@ +-- DB update 2024_11_09_00 -> 2024_11_09_01 UPDATE `creature_template` SET `mechanic_immune_mask` = `mechanic_immune_mask` & ~(33554432 | 67108864) WHERE `entry` = 5855; From 82d43ee52a2d13031b89bf5f963808850718f962 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 9 Nov 2024 19:18:14 -0300 Subject: [PATCH 009/105] fix(Scripts/ZulAman): Move Harrison Jones spawn to DB (#20491) Co-authored-by: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> --- .../rev_1731165151168533600.sql | 4 ++++ .../ZulAman/instance_zulaman.cpp | 20 ------------------- 2 files changed, 4 insertions(+), 20 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731165151168533600.sql diff --git a/data/sql/updates/pending_db_world/rev_1731165151168533600.sql b/data/sql/updates/pending_db_world/rev_1731165151168533600.sql new file mode 100644 index 00000000000000..30174cb66dde53 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731165151168533600.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `creature` WHERE `guid` = 320 AND `id1` = 24358; +INSERT INTO `creature` (`guid`, `id1`, `id2`, `id3`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `ScriptName`, `VerifiedBuild`, `CreateObject`, `Comment`) VALUES +(320, 24358, 0, 0, 568, 0, 0, 1, 1, 0, 121.36404, 1674.9835, 42.10491, 1.553343057632446289, 608400, 0, 0, 4890, 0, 2, 1, 0, 0, 'npc_harrison_jones', 50375, 2, NULL); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp index ec3cd93ea69a65..250f7b57613184 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp @@ -93,7 +93,6 @@ class instance_zulaman : public InstanceMapScript ObjectGuid AshlisBagGUID; ObjectGuid KrazsPackageGUID; ObjectGuid StrangeGongGUID; - ObjectGuid HarrisonJonesGUID; ObjectGuid HexLordGateGUID; ObjectGuid ZulJinGateGUID; @@ -129,25 +128,6 @@ class instance_zulaman : public InstanceMapScript m_auiEncounter[DATA_GONGEVENT] = NOT_STARTED; } - void OnPlayerEnter(Player* /*player*/) override - { - if (!HarrisonJonesGUID) - instance->SummonCreature(NPC_HARRISON_JONES, HarrisonJonesLoc); - } - - void OnCreatureCreate(Creature* creature) override - { - switch (creature->GetEntry()) - { - case NPC_HARRISON_JONES: - HarrisonJonesGUID = creature->GetGUID(); - break; - default: - break; - } - InstanceScript::OnCreatureCreate(creature); - } - void OnGameObjectCreate(GameObject* go) override { switch (go->GetEntry()) From 99f77341a8b893cec511a7eb05144efcaf4ede3c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 9 Nov 2024 22:19:07 +0000 Subject: [PATCH 010/105] chore(DB): import pending files Referenced commit(s): 82d43ee52a2d13031b89bf5f963808850718f962 --- .../rev_1731165151168533600.sql => db_world/2024_11_09_02.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731165151168533600.sql => db_world/2024_11_09_02.sql} (93%) diff --git a/data/sql/updates/pending_db_world/rev_1731165151168533600.sql b/data/sql/updates/db_world/2024_11_09_02.sql similarity index 93% rename from data/sql/updates/pending_db_world/rev_1731165151168533600.sql rename to data/sql/updates/db_world/2024_11_09_02.sql index 30174cb66dde53..f806d43d630ac9 100644 --- a/data/sql/updates/pending_db_world/rev_1731165151168533600.sql +++ b/data/sql/updates/db_world/2024_11_09_02.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_09_01 -> 2024_11_09_02 -- DELETE FROM `creature` WHERE `guid` = 320 AND `id1` = 24358; INSERT INTO `creature` (`guid`, `id1`, `id2`, `id3`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `ScriptName`, `VerifiedBuild`, `CreateObject`, `Comment`) VALUES From 7b8fadaa0cea9a74732980910f1e06cedac4ade0 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sat, 9 Nov 2024 20:11:56 -0300 Subject: [PATCH 011/105] refactor(Scripts/ZulAman): Move Jan'alai Fire Bomb to SAI (#20496) --- .../pending_db_world/rev_1731192427658198900.sql | 7 +++++++ .../scripts/EasternKingdoms/ZulAman/boss_janalai.cpp | 12 ------------ 2 files changed, 7 insertions(+), 12 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731192427658198900.sql diff --git a/data/sql/updates/pending_db_world/rev_1731192427658198900.sql b/data/sql/updates/pending_db_world/rev_1731192427658198900.sql new file mode 100644 index 00000000000000..81e680e8f4266c --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731192427658198900.sql @@ -0,0 +1,7 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 23920; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 23920); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(23920, 0, 0, 0, 25, 0, 100, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Fire Bomb (Zul\'Aman)- On Reset - Set Reactstate Passive'), +(23920, 0, 1, 0, 8, 0, 100, 0, 42628, 0, 0, 0, 0, 0, 11, 42629, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Fire Bomb (Zul\'Aman) - On Spellhit \'Fire Bomb\' - Cast \'Fire Bomb\''); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp index bb7fae9a4e0c9d..0fd4a8334b7b3c 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp @@ -333,17 +333,6 @@ struct boss_janalai : public BossAI bool _isFlameBreathing; }; -struct npc_janalai_firebomb : public NullCreatureAI -{ - npc_janalai_firebomb(Creature* creature) : NullCreatureAI(creature) { } - - void SpellHit(Unit* /*caster*/, SpellInfo const* spell) override - { - if (spell->Id == SPELL_FIRE_BOMB_THROW) - DoCastSelf(SPELL_FIRE_BOMB_DUMMY, true); - } -}; - struct npc_janalai_hatcher : public ScriptedAI { npc_janalai_hatcher(Creature* creature) : ScriptedAI(creature) @@ -484,7 +473,6 @@ struct npc_janalai_egg : public NullCreatureAI void AddSC_boss_janalai() { RegisterZulAmanCreatureAI(boss_janalai); - RegisterZulAmanCreatureAI(npc_janalai_firebomb); RegisterZulAmanCreatureAI(npc_janalai_hatcher); RegisterZulAmanCreatureAI(npc_janalai_hatchling); RegisterZulAmanCreatureAI(npc_janalai_egg); From 7f9695b7a6609e0d3a9131f9ab1440d4140326bb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 9 Nov 2024 23:16:23 +0000 Subject: [PATCH 012/105] chore(DB): import pending files Referenced commit(s): 7b8fadaa0cea9a74732980910f1e06cedac4ade0 --- .../rev_1731192427658198900.sql => db_world/2024_11_09_03.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731192427658198900.sql => db_world/2024_11_09_03.sql} (95%) diff --git a/data/sql/updates/pending_db_world/rev_1731192427658198900.sql b/data/sql/updates/db_world/2024_11_09_03.sql similarity index 95% rename from data/sql/updates/pending_db_world/rev_1731192427658198900.sql rename to data/sql/updates/db_world/2024_11_09_03.sql index 81e680e8f4266c..79096096207ebe 100644 --- a/data/sql/updates/pending_db_world/rev_1731192427658198900.sql +++ b/data/sql/updates/db_world/2024_11_09_03.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_09_02 -> 2024_11_09_03 -- UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 23920; From d73ebe2e383d28167e32e03f16080f6cdffb6eaf Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 04:54:01 -0300 Subject: [PATCH 013/105] fix(Core/SAI): Don't try to reposition Rooted inhabit type creatures (#20504) --- src/server/game/AI/SmartScripts/SmartScript.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index ac6bebeca7be29..553a5b82d9f861 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -696,6 +696,10 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u if (isWithinLOSInMap && isWithinMeleeRange && isRangedAttack && isTargetRooted && canCastSpell && !me->IsVehicle()) { failedSpellCast = true; // Mark spellcast as failed so we can retry it later + + if (me->IsRooted()) // Rooted inhabit type, never move/reposition + continue; + float minDistance = std::max(meleeRange, spellMinRange) - distanceToTarget + NOMINAL_MELEE_RANGE; CAST_AI(SmartAI, me->AI())->MoveAway(std::min(minDistance, spellMaxRange)); continue; @@ -705,12 +709,20 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u if (distanceToTarget > spellMaxRange && isWithinLOSInMap) { failedSpellCast = true; + + if (me->IsRooted()) // Rooted inhabit type, never move/reposition + continue; + CAST_AI(SmartAI, me->AI())->SetCombatMove(true, std::max(spellMaxRange - NOMINAL_MELEE_RANGE, 0.0f)); continue; } else if (distanceToTarget < spellMinRange || !(isWithinLOSInMap || isSpellIgnoreLOS)) { failedSpellCast = true; + + if (me->IsRooted()) // Rooted inhabit type, never move/reposition + continue; + CAST_AI(SmartAI, me->AI())->SetCombatMove(true); continue; } From 8904a1330479f3f5c141d239c888a92f9ec0e7b9 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 08:41:26 -0300 Subject: [PATCH 014/105] =?UTF-8?q?fix(Scripts/ZulAman):=20Fix=20Sacrifice?= =?UTF-8?q?=20timers=20not=20updating=20after=20latest=20=E2=80=A6=20(#204?= =?UTF-8?q?90)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ZulAman/instance_zulaman.cpp | 318 ++----- .../EasternKingdoms/ZulAman/zulaman.cpp | 821 ++++++------------ .../scripts/EasternKingdoms/ZulAman/zulaman.h | 34 +- 3 files changed, 398 insertions(+), 775 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp index 250f7b57613184..3ed70672089b82 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp @@ -15,13 +15,6 @@ * with this program. If not, see . */ -/* ScriptData -SDName: instance_zulaman -SD%Complete: 80 -SDComment: -SDCategory: Zul'Aman -EndScriptData */ - #include "InstanceMapScript.h" #include "InstanceScript.h" #include "Player.h" @@ -41,34 +34,40 @@ enum Misc struct SHostageInfo { uint32 npc, go; // FIXME go Not used - float x, y, z, o; + Position pos; }; static SHostageInfo HostageInfo[] = { - {23790, 186648, -57, 1343, 40.77f, 3.2f}, // bear - {23999, 187021, 400, 1414, 74.36f, 3.3f}, // eagle - {24001, 186672, -35, 1134, 18.71f, 1.9f}, // dragonhawk - {24024, 186667, 413, 1117, 6.32f, 3.1f} // lynx + {23790, 186648, { -57.0f, 1343.0f, 40.77f, 3.2f } }, // bear + {23999, 187021, { 400.0f, 1414.0f, 74.36f, 3.3f } }, // eagle + {24001, 186672, { -35.0f, 1134.0f, 18.71f, 1.9f } }, // dragonhawk + {24024, 186667, { 413.0f, 1117.0f, 6.32f, 3.1f } } // lynx }; Position const HarrisonJonesLoc = {120.687f, 1674.0f, 42.0217f, 1.59044f}; DoorData const doorData[] = { - { GO_ZULJIN_FIREWALL, DATA_ZULJIN, DOOR_TYPE_ROOM }, - { 0, 0, DOOR_TYPE_ROOM } // END + { GO_ZULJIN_FIREWALL, DATA_ZULJIN, DOOR_TYPE_ROOM }, + { GO_DOOR_HALAZZI, DATA_HALAZZI, DOOR_TYPE_ROOM }, + { GO_DOOR_AKILZON, DATA_AKILZON, DOOR_TYPE_ROOM }, + { GO_GATE_ZULJIN, DATA_HEXLORD, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; ObjectData const creatureData[] = { - { NPC_SPIRIT_LYNX, DATA_SPIRIT_LYNX }, - { 0, 0 } + { NPC_SPIRIT_LYNX, DATA_SPIRIT_LYNX }, + { 0, 0 } }; ObjectData const gameObjectData[] = { - { 0, 0 } + { GO_STRANGE_GONG, DATA_STRANGE_GONG }, + { GO_MASSIVE_GATE, DATA_MASSIVE_GATE }, + { GO_GATE_HEXLORD, DATA_HEXLORD_GATE }, + { 0, 0 } }; BossBoundaryData const boundaries = @@ -79,304 +78,163 @@ BossBoundaryData const boundaries = class instance_zulaman : public InstanceMapScript { public: - instance_zulaman() - : InstanceMapScript("instance_zulaman", 568) - { - } + instance_zulaman() : InstanceMapScript("instance_zulaman", 568) { } struct instance_zulaman_InstanceMapScript : public InstanceScript { instance_zulaman_InstanceMapScript(Map* map) : InstanceScript(map) {} - ObjectGuid HarkorsSatchelGUID; - ObjectGuid TanzarsTrunkGUID; - ObjectGuid AshlisBagGUID; - ObjectGuid KrazsPackageGUID; - ObjectGuid StrangeGongGUID; - - ObjectGuid HexLordGateGUID; - ObjectGuid ZulJinGateGUID; - ObjectGuid MassiveGateGUID; - ObjectGuid AkilzonDoorGUID; - ObjectGuid HalazziDoorGUID; - - uint32 QuestTimer; - uint16 BossKilled; - uint16 QuestMinute; - uint16 ChestLooted; - - uint32 m_auiEncounter[MAX_ENCOUNTER]; - uint32 RandVendor[RAND_VENDOR]; - void Initialize() override { SetHeaders(DataHeader); - LoadObjectData(creatureData, gameObjectData); - memset(&m_auiEncounter, 0, sizeof(m_auiEncounter)); SetBossNumber(MAX_ENCOUNTER); + SetPersistentDataCount(PersistentDataCount); + LoadObjectData(creatureData, gameObjectData); LoadBossBoundaries(boundaries); LoadDoorData(doorData); - QuestTimer = 0; - QuestMinute = 0; - BossKilled = 0; - ChestLooted = 0; - for (uint8 i = 0; i < RAND_VENDOR; ++i) RandVendor[i] = NOT_STARTED; + } - m_auiEncounter[DATA_GONGEVENT] = NOT_STARTED; + void OnPlayerEnter(Player* /*player*/) override + { + if (!scheduler.IsGroupScheduled(GROUP_TIMED_RUN)) + DoAction(ACTION_START_TIMED_RUN); } void OnGameObjectCreate(GameObject* go) override { - switch (go->GetEntry()) - { - case GO_DOOR_HALAZZI: - HalazziDoorGUID = go->GetGUID(); - break; - case GO_GATE_ZULJIN: - ZulJinGateGUID = go->GetGUID(); - break; - case GO_GATE_HEXLORD: - HexLordGateGUID = go->GetGUID(); - break; - case GO_MASSIVE_GATE: - MassiveGateGUID = go->GetGUID(); - break; - case GO_DOOR_AKILZON: - AkilzonDoorGUID = go->GetGUID(); - break; - - case GO_HARKORS_SATCHEL: - HarkorsSatchelGUID = go->GetGUID(); - break; - case GO_TANZARS_TRUNK: - TanzarsTrunkGUID = go->GetGUID(); - break; - case GO_ASHLIS_BAG: - AshlisBagGUID = go->GetGUID(); - break; - case GO_KRAZS_PACKAGE: - KrazsPackageGUID = go->GetGUID(); - break; - case GO_STRANGE_GONG: - StrangeGongGUID = go->GetGUID(); - break; - default: - break; - } - CheckInstanceStatus(); + if (go->GetEntry() == GO_GATE_HEXLORD) + CheckInstanceStatus(); InstanceScript::OnGameObjectCreate(go); } void SummonHostage(uint8 num) { - if (!QuestMinute) + if (!GetPersistentData(DATA_TIMED_RUN)) return; - Map::PlayerList const& PlayerList = instance->GetPlayers(); - if (PlayerList.IsEmpty()) - return; + instance->SummonCreature(HostageInfo[num].npc, HostageInfo[num].pos); + } - Map::PlayerList::const_iterator i = PlayerList.begin(); - if (Player* i_pl = i->GetSource()) + void DoAction(int32 actionId) override + { + if (actionId == ACTION_START_TIMED_RUN) { - if (Unit* Hostage = i_pl->SummonCreature(HostageInfo[num].npc, HostageInfo[num].x, HostageInfo[num].y, HostageInfo[num].z, HostageInfo[num].o, TEMPSUMMON_DEAD_DESPAWN, 0)) + if (uint32 timer = GetPersistentData(DATA_TIMED_RUN)) { - Hostage->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - Hostage->SetNpcFlag(UNIT_NPC_FLAG_GOSSIP); + DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 1); + DoUpdateWorldState(WORLDSTATE_TIME_TO_SACRIFICE, timer); } + + scheduler.Schedule(1min, GROUP_TIMED_RUN, [this](TaskContext context) + { + if (uint32 timer = GetPersistentData(DATA_TIMED_RUN)) + { + --timer; + DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 1); + DoUpdateWorldState(WORLDSTATE_TIME_TO_SACRIFICE, timer); + StorePersistentData(DATA_TIMED_RUN, timer); + context.Repeat(); + } + else + DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 0); + }); } } void CheckInstanceStatus() { - if (BossKilled >= DATA_HALAZZI) - HandleGameObject(HexLordGateGUID, true); - - if (BossKilled >= DATA_HEXLORD) - HandleGameObject(ZulJinGateGUID, true); + if (AllBossesDone({ DATA_NALORAKK, DATA_AKILZON, DATA_JANALAI, DATA_HALAZZI })) + HandleGameObject(ObjectGuid::Empty, true, GetGameObject(DATA_HEXLORD_GATE)); } - std::string GetSaveData() override + void SetData(uint32 type, uint32 data) override { - OUT_SAVE_INST_DATA; - - std::ostringstream ss; - ss << "S " << BossKilled << ' ' << ChestLooted << ' ' << QuestMinute; - - OUT_SAVE_INST_DATA_COMPLETE; - return ss.str(); + if (type == TYPE_RAND_VENDOR_1) + RandVendor[0] = data; + else if (type == TYPE_RAND_VENDOR_2) + RandVendor[1] = data; } - void Load(const char* load) override + bool SetBossState(uint32 type, EncounterState state) override { - if (!load) - return; - - std::istringstream ss(load); - char dataHead; // S - uint16 data1, data2, data3; - ss >> dataHead >> data1 >> data2 >> data3; - - if (dataHead == 'S') - { - BossKilled = data1; - ChestLooted = data2; - QuestMinute = data3; - } - else - { - LOG_ERROR("misc", "Zul'aman: corrupted save data."); - } - } + if (!InstanceScript::SetBossState(type, state)) + return false; - void SetData(uint32 type, uint32 data) override - { switch (type) { - case DATA_GONGEVENT: - m_auiEncounter[DATA_GONGEVENT] = data; - if (data == IN_PROGRESS) - SaveToDB(); - else if (data == DONE) - QuestMinute = 21; - break; case DATA_NALORAKK: - m_auiEncounter[DATA_NALORAKK] = data; - if (data == DONE) + if (state == DONE) { - if (QuestMinute) + if (uint32 timer = GetPersistentData(DATA_TIMED_RUN)) { - QuestMinute += 15; - DoUpdateWorldState(WORLDSTATE_TIME_TO_SACRIFICE, QuestMinute); + StorePersistentData(DATA_TIMED_RUN, timer += 15); + DoUpdateWorldState(WORLDSTATE_TIME_TO_SACRIFICE, timer); } SummonHostage(0); - SaveToDB(); } break; case DATA_AKILZON: - m_auiEncounter[DATA_AKILZON] = data; - HandleGameObject(AkilzonDoorGUID, data != IN_PROGRESS); - if (data == DONE) + if (state == DONE) { - if (QuestMinute) + if (uint32 timer = GetPersistentData(DATA_TIMED_RUN)) { - QuestMinute += 10; - DoUpdateWorldState(WORLDSTATE_TIME_TO_SACRIFICE, QuestMinute); + StorePersistentData(DATA_TIMED_RUN, timer += 10); + DoUpdateWorldState(WORLDSTATE_TIME_TO_SACRIFICE, timer); } SummonHostage(1); - SaveToDB(); } break; case DATA_JANALAI: - m_auiEncounter[DATA_JANALAI] = data; - if (data == DONE) + if (state == DONE) SummonHostage(2); - SaveToDB(); break; case DATA_HALAZZI: - m_auiEncounter[DATA_HALAZZI] = data; - HandleGameObject(HalazziDoorGUID, data != IN_PROGRESS); - if (data == DONE) SummonHostage(3); - SaveToDB(); + if (state == DONE) + SummonHostage(3); break; case DATA_HEXLORD: - m_auiEncounter[DATA_HEXLORD] = data; - if (data == IN_PROGRESS) - HandleGameObject(HexLordGateGUID, false); - else if (data == NOT_STARTED) + if (state == IN_PROGRESS) + HandleGameObject(ObjectGuid::Empty, false, GetGameObject(DATA_HEXLORD_GATE)); + else if (state == NOT_STARTED) CheckInstanceStatus(); - SaveToDB(); - break; - case DATA_CHESTLOOTED: - ++ChestLooted; - SaveToDB(); - break; - case TYPE_RAND_VENDOR_1: - RandVendor[0] = data; - break; - case TYPE_RAND_VENDOR_2: - RandVendor[1] = data; break; } - if (data == DONE) + if (state == DONE) { - ++BossKilled; - if (QuestMinute && BossKilled >= DATA_HALAZZI) + if (GetPersistentData(DATA_TIMED_RUN) && AllBossesDone({ DATA_NALORAKK, DATA_AKILZON, DATA_JANALAI, DATA_HALAZZI })) { - QuestMinute = 0; + StorePersistentData(DATA_TIMED_RUN, 0); DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 0); } + CheckInstanceStatus(); - SaveToDB(); } + + return true; } uint32 GetData(uint32 type) const override { - switch (type) - { - case DATA_GONGEVENT: - return m_auiEncounter[DATA_GONGEVENT]; - case DATA_NALORAKK: - return m_auiEncounter[DATA_NALORAKK]; - case DATA_AKILZON: - return m_auiEncounter[DATA_AKILZON]; - case DATA_JANALAI: - return m_auiEncounter[DATA_JANALAI]; - case DATA_HALAZZI: - return m_auiEncounter[DATA_HALAZZI]; - case DATA_HEXLORD: - return m_auiEncounter[DATA_HEXLORD]; - case DATA_ZULJIN: - return m_auiEncounter[DATA_ZULJIN]; - case DATA_CHESTLOOTED: - return ChestLooted; - case TYPE_RAND_VENDOR_1: - return RandVendor[0]; - case TYPE_RAND_VENDOR_2: - return RandVendor[1]; - default: - return 0; - } + if (type == TYPE_RAND_VENDOR_1) + return RandVendor[0]; + else if (type == TYPE_RAND_VENDOR_2) + return RandVendor[1]; + + return 0; } void Update(uint32 diff) override { - if (QuestMinute) - { - if (QuestTimer <= diff) - { - QuestMinute--; - SaveToDB(); - QuestTimer += 60000; - if (QuestMinute) - { - DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 1); - DoUpdateWorldState(WORLDSTATE_TIME_TO_SACRIFICE, QuestMinute); - } - else DoUpdateWorldState(WORLDSTATE_SHOW_TIMER, 0); - } - QuestTimer -= diff; - } + scheduler.Update(diff); } - ObjectGuid GetGuidData(uint32 type) const override - { - switch (type) - { - case GO_STRANGE_GONG: - return StrangeGongGUID; - case GO_MASSIVE_GATE: - return MassiveGateGUID; - } - - return ObjectGuid::Empty; - } + private: + uint32 RandVendor[RAND_VENDOR]; }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp index 1f9e44d783ec22..8896931d22d106 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp @@ -63,384 +63,177 @@ enum ForestFrog NPC_BRENNAN = 24453, NPC_HOLLEE = 24455, - // Says - SAY_MANNUTH_0 = 0, - SAY_MANNUTH_1 = 1, - SAY_MANNUTH_2 = 2, - SAY_MANNUTH_3 = 3, - - SAY_DEEZ_0 = 0, - SAY_DEEZ_1 = 1, - SAY_DEEZ_2 = 2, - SAY_DEEZ_3 = 3, - - SAY_GALATHRYN_0 = 0, - SAY_GALATHRYN_1 = 1, - SAY_GALATHRYN_2 = 2, - SAY_GALATHRYN_3 = 3, - - SAY_ADARRAH_1 = 1, - SAY_ADARRAH_2 = 2, - SAY_ADARRAH_3 = 3, - SAY_ADARRAH_4 = 4, - - SAY_DARWEN_0 = 0, - SAY_DARWEN_1 = 1, - SAY_DARWEN_2 = 2, - SAY_DARWEN_3 = 3, - - SAY_FUDGERICK_0 = 0, - SAY_FUDGERICK_1 = 1, - SAY_FUDGERICK_2 = 2, - SAY_FUDGERICK_3 = 3, - - SAY_GUNTER_0 = 0, - SAY_GUNTER_1 = 1, - SAY_GUNTER_2 = 2, - - SAY_KYREN_0 = 0, - SAY_KYREN_1 = 1, - SAY_KYREN_2 = 2, - - SAY_MITZI_0 = 0, - SAY_MITZI_1 = 1, - SAY_MITZI_2 = 2, - SAY_MITZI_3 = 3, - - SAY_CHRISTIAN_0 = 0, - SAY_CHRISTIAN_1 = 1, - SAY_CHRISTIAN_2 = 2, - SAY_CHRISTIAN_3 = 3, - - SAY_BRENNAN_0 = 0, - SAY_BRENNAN_1 = 1, - SAY_BRENNAN_2 = 2, - SAY_BRENNAN_3 = 3, - - SAY_HOLLEE_0 = 0, - SAY_HOLLEE_1 = 1, - SAY_HOLLEE_2 = 2, - SAY_HOLLEE_3 = 3, - - POINT_DESPAWN = 1 + // Adarrah is spawned elsewhere. + // So her text 0 isn't used in this instance. + SAY_THANKS_FREED = 0, + SAY_CHEST_SPAWN = 1, + SAY_CHEST_TALK = 2, + SAY_GOODBYE = 3, + + POINT_DESPAWN = 1, }; -class npc_forest_frog : public CreatureScript +struct npc_forest_frog : public ScriptedAI { -public: - npc_forest_frog() : CreatureScript("npc_forest_frog") { } - - struct npc_forest_frogAI : public ScriptedAI + npc_forest_frog(Creature* creature) : ScriptedAI(creature) { - npc_forest_frogAI(Creature* creature) : ScriptedAI(creature) - { - instance = creature->GetInstanceScript(); - } - - InstanceScript* instance; - EventMap events; - uint8 eventTimer; - ObjectGuid PlayerGUID; - - void Reset() override { } + instance = creature->GetInstanceScript(); + } - void JustEngagedWith(Unit* /*who*/) override { } + void JustEngagedWith(Unit* /*who*/) override { } - void MovementInform(uint32 type, uint32 data) override - { - if (type == POINT_MOTION_TYPE && data == POINT_DESPAWN) - me->DespawnOrUnsummon(1000); - } + void MovementInform(uint32 type, uint32 data) override + { + if (type == POINT_MOTION_TYPE && data == POINT_DESPAWN) + me->DespawnOrUnsummon(1000); + } - void UpdateAI(uint32 diff) override + void UpdateAI(uint32 diff) override + { + events.Update(diff); + if (eventTimer) { - events.Update(diff); - if (eventTimer) + Player* player = ObjectAccessor::GetPlayer(me->GetMap(), PlayerGUID); + switch (events.ExecuteEvent()) { - Player* player = ObjectAccessor::GetPlayer(me->GetMap(), PlayerGUID); - switch (events.ExecuteEvent()) - { - case 1: - switch (me->GetEntry()) - { - case NPC_MANNUTH: - Talk(SAY_MANNUTH_0, player); - break; - case NPC_DEEZ: - Talk(SAY_DEEZ_0, player); - break; - case NPC_GALATHRYN: - Talk(SAY_GALATHRYN_0, player); - break; - case NPC_ADARRAH: - Talk(SAY_ADARRAH_1, player); - break; - case NPC_DARWEN: - Talk(SAY_DARWEN_0, player); - break; - case NPC_FUDGERICK: - Talk(SAY_FUDGERICK_0, player); - break; - case NPC_GUNTER: - Talk(SAY_GUNTER_0, player); - break; - case NPC_KYREN: - Talk(SAY_KYREN_0, player); - break; - case NPC_MITZI: - Talk(SAY_MITZI_0, player); - break; - case NPC_CHRISTIAN: - Talk(SAY_CHRISTIAN_0, player); - break; - case NPC_BRENNAN: - Talk(SAY_BRENNAN_0, player); - break; - case NPC_HOLLEE: - Talk(SAY_HOLLEE_0, player); - break; - } - eventTimer = 2; - events.ScheduleEvent(eventTimer, urand(4000, 5000)); - break; - case 2: - if (me->GetEntry() != NPC_GUNTER && me->GetEntry() != NPC_KYREN) // vendors don't kneel? - me->SetStandState(UNIT_STAND_STATE_KNEEL); - - switch (me->GetEntry()) - { - case NPC_MANNUTH: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_2, true); - Talk(SAY_MANNUTH_1, player); - break; - case NPC_DEEZ: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_2, true); - Talk(SAY_DEEZ_1, player); - break; - case NPC_GALATHRYN: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_2, true); - Talk(SAY_GALATHRYN_1, player); - break; - case NPC_ADARRAH: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_2, true); - Talk(SAY_ADARRAH_2, player); - break; - case NPC_DARWEN: - DoCast(me, SPELL_SUMMON_MONEY_BAG, true); - me->LoadEquipment(0, true); - Talk(SAY_DARWEN_1, player); - break; - case NPC_FUDGERICK: - DoCast(me, SPELL_SUMMON_MONEY_BAG, true); - me->LoadEquipment(0, true); - Talk(SAY_FUDGERICK_1, player); - break; - case NPC_GUNTER: - Talk(SAY_GUNTER_1, player); - break; - case NPC_KYREN: - Talk(SAY_KYREN_1, player); - break; - case NPC_MITZI: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_1, true); - Talk(SAY_MITZI_1, player); - break; - case NPC_CHRISTIAN: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_1, true); - Talk(SAY_CHRISTIAN_1, player); - break; - case NPC_BRENNAN: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_1, true); - Talk(SAY_BRENNAN_1, player); - break; - case NPC_HOLLEE: - DoCast(me, SPELL_SUMMON_AMANI_CHARM_CHEST_1, true); - Talk(SAY_HOLLEE_1, player); - break; - } - eventTimer = 3; - events.ScheduleEvent(eventTimer, urand(6000, 7000)); - break; - case 3: - me->SetStandState(EMOTE_ONESHOT_NONE); - switch (me->GetEntry()) - { - case NPC_MANNUTH: - Talk(SAY_MANNUTH_2, player); - break; - case NPC_DEEZ: - Talk(SAY_DEEZ_2, player); - break; - case NPC_GALATHRYN: - Talk(SAY_GALATHRYN_2, player); - break; - case NPC_ADARRAH: - Talk(SAY_ADARRAH_3, player); - break; - case NPC_DARWEN: - Talk(SAY_DARWEN_2, player); - break; - case NPC_FUDGERICK: - Talk(SAY_FUDGERICK_2, player); - break; - case NPC_GUNTER: - Talk(SAY_GUNTER_2, player); - break; - case NPC_KYREN: - Talk(SAY_KYREN_2, player); - break; - case NPC_MITZI: - Talk(SAY_MITZI_2, player); - break; - case NPC_CHRISTIAN: - Talk(SAY_CHRISTIAN_2, player); - break; - case NPC_BRENNAN: - Talk(SAY_BRENNAN_2, player); - break; - case NPC_HOLLEE: - Talk(SAY_HOLLEE_2, player); - break; - } - eventTimer = 4; - if (me->GetEntry() == NPC_GUNTER || me->GetEntry() == NPC_KYREN) - events.ScheduleEvent(eventTimer, 5 * MINUTE * IN_MILLISECONDS); // vendors wait for 5 minutes before running away and despawning - else - events.ScheduleEvent(eventTimer, 6000); - break; - case 4: - me->HandleEmoteCommand(EMOTE_ONESHOT_WAVE); - switch (me->GetEntry()) - { - case NPC_MANNUTH: - Talk(SAY_MANNUTH_3, player); - break; - case NPC_DEEZ: - Talk(SAY_DEEZ_3, player); - break; - case NPC_GALATHRYN: - Talk(SAY_GALATHRYN_3, player); - break; - case NPC_ADARRAH: - Talk(SAY_ADARRAH_4, player); - break; - case NPC_DARWEN: - Talk(SAY_DARWEN_3, player); - break; - case NPC_FUDGERICK: - Talk(SAY_FUDGERICK_3, player); - break; - case NPC_MITZI: - Talk(SAY_MITZI_3, player); - break; - case NPC_CHRISTIAN: - Talk(SAY_CHRISTIAN_3, player); - break; - case NPC_BRENNAN: - Talk(SAY_BRENNAN_3, player); - break; - case NPC_HOLLEE: - Talk(SAY_HOLLEE_3, player); - break; - } - eventTimer = 5; - events.ScheduleEvent(eventTimer, 2000); - break; - case 5: - switch (me->GetEntry()) - { - case NPC_ADARRAH: - DoCast(me, SPELL_STEALTH_, true); - break; - } - if (me->GetPositionY() > 1290.0f) - me->GetMotionMaster()->MovePoint(POINT_DESPAWN, 118.2742f, 1400.657f, -9.118711f); - else - me->GetMotionMaster()->MovePoint(POINT_DESPAWN, 114.3155f, 1244.244f, -20.97606f); - eventTimer = 0; - break; - } - } - } + case 1: - void DoSpawnRandom() - { - if (instance) - { - uint32 cEntry = NPC_MANNUTH; - switch (urand(0, 9)) - { - case 1: - cEntry = NPC_DEEZ; - break; - case 2: - cEntry = NPC_GALATHRYN; - break; - case 3: - cEntry = NPC_ADARRAH; - break; - case 4: - cEntry = NPC_FUDGERICK; - break; - case 5: - cEntry = NPC_DARWEN; - break; - case 6: - cEntry = NPC_MITZI; - break; - case 7: - cEntry = NPC_CHRISTIAN; - break; - case 8: - cEntry = NPC_BRENNAN; - break; - case 9: - cEntry = NPC_HOLLEE; - break; - } + if (me->GetEntry() == NPC_ADARRAH) + Talk(SAY_THANKS_FREED + 1, player); + else + Talk(SAY_THANKS_FREED, player); - if (!instance->GetData(TYPE_RAND_VENDOR_1) && roll_chance_i(10)) - { - cEntry = NPC_GUNTER; - instance->SetData(TYPE_RAND_VENDOR_1, DONE); - } - else if (!instance->GetData(TYPE_RAND_VENDOR_2) && roll_chance_i(10)) + eventTimer = 2; + events.ScheduleEvent(eventTimer, urand(4000, 5000)); + break; + case 2: + if (me->GetEntry() != NPC_GUNTER && me->GetEntry() != NPC_KYREN) // vendors don't kneel? + me->SetStandState(UNIT_STAND_STATE_KNEEL); + + switch (me->GetEntry()) { - cEntry = NPC_KYREN; - instance->SetData(TYPE_RAND_VENDOR_2, DONE); + case NPC_MANNUTH: + case NPC_DEEZ: + case NPC_GALATHRYN: + DoCastSelf(SPELL_SUMMON_AMANI_CHARM_CHEST_2, true); + Talk(SAY_CHEST_SPAWN, player); + break; + case NPC_ADARRAH: + DoCastSelf(SPELL_SUMMON_AMANI_CHARM_CHEST_2, true); + Talk(SAY_CHEST_SPAWN + 1, player); + break; + case NPC_DARWEN: + case NPC_FUDGERICK: + DoCastSelf(SPELL_SUMMON_MONEY_BAG, true); + me->LoadEquipment(0, true); + Talk(SAY_CHEST_SPAWN, player); + break; + case NPC_KYREN: + case NPC_GUNTER: + Talk(SAY_CHEST_SPAWN, player); + break; + case NPC_MITZI: + case NPC_CHRISTIAN: + case NPC_BRENNAN: + case NPC_HOLLEE: + DoCastSelf(SPELL_SUMMON_AMANI_CHARM_CHEST_1, true); + Talk(SAY_CHEST_SPAWN, player); + break; } + eventTimer = 3; + events.ScheduleEvent(eventTimer, urand(6000, 7000)); + break; + case 3: + me->SetStandState(EMOTE_ONESHOT_NONE); + + if (me->GetEntry() == NPC_ADARRAH) + Talk(SAY_CHEST_TALK + 1, player); + else + Talk(SAY_CHEST_TALK); + + eventTimer = 4; + if (me->GetEntry() == NPC_GUNTER || me->GetEntry() == NPC_KYREN) + events.ScheduleEvent(eventTimer, 5 * MINUTE * IN_MILLISECONDS); // vendors wait for 5 minutes before running away and despawning + else + events.ScheduleEvent(eventTimer, 6000); + break; + case 4: + me->HandleEmoteCommand(EMOTE_ONESHOT_WAVE); - // start generic rp - eventTimer = 1; - events.ScheduleEvent(eventTimer, 3000); + if (me->GetEntry() == NPC_ADARRAH) + Talk(SAY_GOODBYE + 1, player); + else + Talk(SAY_GOODBYE); + + eventTimer = 5; + events.ScheduleEvent(eventTimer, 2000); + break; + case 5: - me->UpdateEntry(cEntry); + if (me->GetEntry() == NPC_ADARRAH) + DoCastSelf(SPELL_STEALTH_, true); + + if (me->GetPositionY() > 1290.0f) + me->GetMotionMaster()->MovePoint(POINT_DESPAWN, 118.2742f, 1400.657f, -9.118711f); + else + me->GetMotionMaster()->MovePoint(POINT_DESPAWN, 114.3155f, 1244.244f, -20.97606f); + eventTimer = 0; + break; } } + } - void SpellHit(Unit* caster, SpellInfo const* spell) override + void DoSpawnRandom() + { + auto const& entries = { - if (spell->Id == SPELL_REMOVE_AMANI_CURSE && caster->IsPlayer() && me->GetEntry() == NPC_FOREST_FROG) - { - me->GetMotionMaster()->MoveIdle(); - me->SetFacingToObject(caster); - PlayerGUID = caster->GetGUID(); + NPC_MANNUTH, NPC_DEEZ, NPC_GALATHRYN, NPC_ADARRAH, NPC_FUDGERICK, NPC_DARWEN, NPC_MITZI, + NPC_CHRISTIAN, NPC_BRENNAN, NPC_HOLLEE + }; - if (roll_chance_i(2)) - { - DoCast(caster, SPELL_PUSH_MOJO, true); - me->GetMotionMaster()->MovePoint(POINT_DESPAWN, caster->GetPositionX(), caster->GetPositionY(), caster->GetPositionZ()); - } - else - DoSpawnRandom(); - } + uint32 cEntry = Acore::Containers::SelectRandomContainerElement(entries); + + if (!instance->GetData(TYPE_RAND_VENDOR_1) && roll_chance_i(10)) + { + cEntry = NPC_GUNTER; + instance->SetData(TYPE_RAND_VENDOR_1, DONE); + } + else if (!instance->GetData(TYPE_RAND_VENDOR_2) && roll_chance_i(10)) + { + cEntry = NPC_KYREN; + instance->SetData(TYPE_RAND_VENDOR_2, DONE); } - }; - CreatureAI* GetAI(Creature* creature) const override + // start generic rp + eventTimer = 1; + events.ScheduleEvent(eventTimer, 3000); + + me->UpdateEntry(cEntry); + } + + void SpellHit(Unit* caster, SpellInfo const* spell) override { - return GetZulAmanAI(creature); + if (spell->Id == SPELL_REMOVE_AMANI_CURSE && caster->IsPlayer() && me->GetEntry() == NPC_FOREST_FROG) + { + me->GetMotionMaster()->MoveIdle(); + me->SetFacingToObject(caster); + PlayerGUID = caster->GetGUID(); + + if (roll_chance_i(2)) + { + DoCast(caster, SPELL_PUSH_MOJO, true); + me->GetMotionMaster()->MovePoint(POINT_DESPAWN, caster->GetPosition()); + } + else + DoSpawnRandom(); + } } + + private: + InstanceScript* instance; + EventMap events; + uint8 eventTimer; + ObjectGuid PlayerGUID; }; /*###### @@ -467,8 +260,6 @@ class npc_zulaman_hostage : public CreatureScript bool IsLoot; ObjectGuid PlayerGUID; - void Reset() override { } - void JustEngagedWith(Unit* /*who*/) override { } void JustDied(Unit* /*killer*/) override @@ -508,21 +299,14 @@ class npc_zulaman_hostage : public CreatureScript creature->RemoveNpcFlag(UNIT_NPC_FLAG_GOSSIP); - InstanceScript* instance = creature->GetInstanceScript(); - if (instance) + float x, y, z; + creature->GetPosition(x, y, z); + for (uint8 i = 0; i < 4; ++i) { - //uint8 progress = instance->GetData(DATA_CHESTLOOTED); - instance->SetData(DATA_CHESTLOOTED, 0); - float x, y, z; - creature->GetPosition(x, y, z); - uint32 entry = creature->GetEntry(); - for (uint8 i = 0; i < 4; ++i) + if (HostageEntry[i] == creature->GetEntry()) { - if (HostageEntry[i] == entry) - { - creature->SummonGameObject(ChestEntry[i], x - 2, y, z, 0, 0, 0, 0, 0, 0); - break; - } + creature->SummonGameObject(ChestEntry[i], x - 2, y, z, 0, 0, 0, 0, 0, 0); + break; } } @@ -591,201 +375,172 @@ enum Weapons WEAPON_SPEAR = 13631 }; -class npc_harrison_jones : public CreatureScript +struct npc_harrison_jones : public ScriptedAI { -public: - npc_harrison_jones() : CreatureScript("npc_harrison_jones") + npc_harrison_jones(Creature* creature) : ScriptedAI(creature) { + _instance = creature->GetInstanceScript(); } - struct npc_harrison_jonesAI : public ScriptedAI + void Reset() override { - npc_harrison_jonesAI(Creature* creature) : ScriptedAI(creature) - { - instance = creature->GetInstanceScript(); - } + _gongEvent = 0; + _gongTimer = 0; + uiTargetGUID.Clear(); + } - InstanceScript* instance; + void JustEngagedWith(Unit* /*who*/) override { } - uint8 _gongEvent; - uint32 _gongTimer; - ObjectGuid uiTargetGUID; - - void Reset() override + void sGossipSelect(Player* player, uint32 sender, uint32 action) override + { + if (me->GetCreatureTemplate()->GossipMenuId == sender && !action) { - _gongEvent = 0; - _gongTimer = 0; - uiTargetGUID.Clear(); + CloseGossipMenuFor(player); + me->SetFacingToObject(player); + me->RemoveNpcFlag(UNIT_NPC_FLAG_GOSSIP); + Talk(SAY_HARRISON_0); + _gongEvent = GONG_EVENT_1; + _gongTimer = 4000; } + } - void JustEngagedWith(Unit* /*who*/) override { } - - void sGossipSelect(Player* player, uint32 sender, uint32 action) override + void SpellHit(Unit*, SpellInfo const* spell) override + { + if (spell->Id == SPELL_COSMETIC_SPEAR_THROW) { - if (me->GetCreatureTemplate()->GossipMenuId == sender && !action) - { - CloseGossipMenuFor(player); - me->SetFacingToObject(player); - me->RemoveNpcFlag(UNIT_NPC_FLAG_GOSSIP); - Talk(SAY_HARRISON_0); - _gongEvent = GONG_EVENT_1; - _gongTimer = 4000; - } - } - - void SpellHit(Unit*, SpellInfo const* spell) override - { - if (spell->Id == SPELL_COSMETIC_SPEAR_THROW) - { - me->RemoveAllAuras(); - me->SetEntry(NPC_HARRISON_JONES_2); - me->SetDisplayId(MODEL_HARRISON_JONES_2); - me->SetTarget(); - me->SetByteValue(UNIT_FIELD_BYTES_1, UNIT_BYTES_1_OFFSET_STAND_STATE, UNIT_STAND_STATE_DEAD); - me->SetDynamicFlag(UNIT_DYNFLAG_DEAD); - instance->SetData(DATA_GONGEVENT, DONE); - } + me->RemoveAllAuras(); + me->SetEntry(NPC_HARRISON_JONES_2); + me->SetDisplayId(MODEL_HARRISON_JONES_2); + me->SetTarget(); + me->SetByteValue(UNIT_FIELD_BYTES_1, UNIT_BYTES_1_OFFSET_STAND_STATE, UNIT_STAND_STATE_DEAD); + me->SetDynamicFlag(UNIT_DYNFLAG_DEAD); + _instance->StorePersistentData(DATA_TIMED_RUN, 21); + _instance->DoAction(ACTION_START_TIMED_RUN); } + } - void UpdateAI(uint32 diff) override + void UpdateAI(uint32 diff) override + { + if (_gongEvent) { - if (_gongEvent) + if (_gongTimer <= diff) { - if (_gongTimer <= diff) + switch (_gongEvent) { - switch (_gongEvent) + case GONG_EVENT_1: + me->GetMotionMaster()->MovePath(HARRISON_MOVE_1, false); + _gongEvent = GONG_EVENT_2; + _gongTimer = 12000; + break; + case GONG_EVENT_2: + me->SetFacingTo(6.235659f); + Talk(SAY_HARRISON_1); + DoCastSelf(SPELL_BANGING_THE_GONG); + me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 0, uint32(WEAPON_MACE)); + me->SetSheath(SHEATH_STATE_MELEE); + _gongEvent = GONG_EVENT_3; + _gongTimer = 4000; + break; + case GONG_EVENT_3: + if (GameObject* gong = _instance->GetGameObject(DATA_STRANGE_GONG)) + gong->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE); + _gongEvent = GONG_EVENT_4; + _gongTimer = 105000; + break; + case GONG_EVENT_4: + me->RemoveAura(SPELL_BANGING_THE_GONG); + if (GameObject* gong = _instance->GetGameObject(DATA_STRANGE_GONG)) + gong->SetGameObjectFlag(GO_FLAG_NOT_SELECTABLE); + + // Players are Now Saved to instance at SPECIAL (Player should be notified?) + me->GetMotionMaster()->MovePath(HARRISON_MOVE_2, false); + _gongEvent = GONG_EVENT_5; + _gongTimer = 5000; + break; + case GONG_EVENT_5: + me->SetEntry(NPC_HARRISON_JONES_1); + me->SetDisplayId(MODEL_HARRISON_JONES_1); + Talk(SAY_HARRISON_2); + _gongTimer = 12000; + _gongEvent = GONG_EVENT_6; + break; + case GONG_EVENT_6: + me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_USE_STANDING); + Talk(SAY_HARRISON_3); + _gongTimer = 7000; + _gongEvent = GONG_EVENT_7; + break; + case GONG_EVENT_7: + if (!uiTargetGUID) { - case GONG_EVENT_1: - me->GetMotionMaster()->MovePath(HARRISON_MOVE_1, false); - _gongEvent = GONG_EVENT_2; - _gongTimer = 12000; - break; - case GONG_EVENT_2: - me->SetFacingTo(6.235659f); - Talk(SAY_HARRISON_1); - DoCast(me, SPELL_BANGING_THE_GONG); - me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 0, uint32(WEAPON_MACE)); - me->SetSheath(SHEATH_STATE_MELEE); - _gongEvent = GONG_EVENT_3; - _gongTimer = 4000; - break; - case GONG_EVENT_3: - if (GameObject* gong = me->GetMap()->GetGameObject(instance->GetGuidData(GO_STRANGE_GONG))) - gong->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE); - _gongEvent = GONG_EVENT_4; - _gongTimer = 105000; - break; - case GONG_EVENT_4: - me->RemoveAura(SPELL_BANGING_THE_GONG); - if (GameObject* gong = me->GetMap()->GetGameObject(instance->GetGuidData(GO_STRANGE_GONG))) - gong->SetGameObjectFlag(GO_FLAG_NOT_SELECTABLE); - - // trigger or gong will need to be scripted to set IN_PROGRESS after enough hits. - // This is temp workaround. - instance->SetData(DATA_GONGEVENT, IN_PROGRESS); // to be removed. - - if (instance->GetData(DATA_GONGEVENT) == IN_PROGRESS) - { - // Players are Now Saved to instance at SPECIAL (Player should be notified?) - me->GetMotionMaster()->MovePath(HARRISON_MOVE_2, false); - _gongEvent = GONG_EVENT_5; - _gongTimer = 5000; - } - else - { - _gongTimer = 1000; - _gongEvent = GONG_EVENT_9; - } - break; - case GONG_EVENT_5: - me->SetEntry(NPC_HARRISON_JONES_1); - me->SetDisplayId(MODEL_HARRISON_JONES_1); - Talk(SAY_HARRISON_2); - _gongTimer = 12000; - _gongEvent = GONG_EVENT_6; - break; - case GONG_EVENT_6: - me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_USE_STANDING); - Talk(SAY_HARRISON_3); - _gongTimer = 7000; - _gongEvent = GONG_EVENT_7; - break; - case GONG_EVENT_7: - if (!uiTargetGUID) + std::list targetList; + GetCreatureListWithEntryInGrid(targetList, me, NPC_AMANISHI_GUARDIAN, 26.0f); + if (!targetList.empty()) + { + for (auto const& creature : targetList) { - std::list targetList; - GetCreatureListWithEntryInGrid(targetList, me, NPC_AMANISHI_GUARDIAN, 26.0f); - if (!targetList.empty()) + if (creature) { - for (std::list::const_iterator itr = targetList.begin(); itr != targetList.end(); ++itr) + creature->SetImmuneToPC(true); + creature->SetReactState(REACT_PASSIVE); + + if (creature->GetPositionX() > 120) { - if (Creature* ptarget = *itr) - { - if (ptarget->GetPositionX() > 120) - { - ptarget->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 0, uint32(WEAPON_SPEAR)); - ptarget->SetImmuneToPC(true); - ptarget->SetReactState(REACT_PASSIVE); - ptarget->AI()->SetData(0, 1); - } - else - { - ptarget->SetImmuneToPC(true); - ptarget->SetReactState(REACT_PASSIVE); - ptarget->AI()->SetData(0, 2); - } - } + creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 0, uint32(WEAPON_SPEAR)); + creature->AI()->SetData(0, 1); } + else + creature->AI()->SetData(0, 2); } } - - if (GameObject* gate = me->GetMap()->GetGameObject(instance->GetGuidData(GO_MASSIVE_GATE))) - gate->SetGoState(GO_STATE_ACTIVE); - _gongTimer = 2000; - _gongEvent = GONG_EVENT_8; - break; - case GONG_EVENT_8: - DoCast(me, SPELL_STEALTH); - me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 0, uint32(0)); - me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); - me->GetMotionMaster()->MovePath(HARRISON_MOVE_3, false); - _gongTimer = 1000; - _gongEvent = 0; - break; - case GONG_EVENT_9: - me->GetMotionMaster()->MovePoint(0, 120.687f, 1674.0f, 42.0217f); - _gongTimer = 12000; - _gongEvent = GONG_EVENT_10; - break; - case GONG_EVENT_10: - me->SetFacingTo(1.59044f); - _gongEvent = 11; - _gongTimer = 6000; - break; - case GONG_EVENT_11: - me->SetNpcFlag(UNIT_NPC_FLAG_GOSSIP); - - instance->SetData(DATA_GONGEVENT, NOT_STARTED); - _gongEvent = 0; - _gongTimer = 1000; - break; + } } + + if (GameObject* gate = _instance->GetGameObject(DATA_MASSIVE_GATE)) + gate->SetGoState(GO_STATE_ACTIVE); + _gongTimer = 2000; + _gongEvent = GONG_EVENT_8; + break; + case GONG_EVENT_8: + DoCastSelf(SPELL_STEALTH); + me->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 0, uint32(0)); + me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); + me->GetMotionMaster()->MovePath(HARRISON_MOVE_3, false); + _gongTimer = 1000; + _gongEvent = 0; + break; + case GONG_EVENT_9: + me->GetMotionMaster()->MovePoint(0, 120.687f, 1674.0f, 42.0217f); + _gongTimer = 12000; + _gongEvent = GONG_EVENT_10; + break; + case GONG_EVENT_10: + me->SetFacingTo(1.59044f); + _gongEvent = 11; + _gongTimer = 6000; + break; + case GONG_EVENT_11: + me->SetNpcFlag(UNIT_NPC_FLAG_GOSSIP); + _gongEvent = 0; + _gongTimer = 1000; + break; } - else - _gongTimer -= diff; } + else + _gongTimer -= diff; } - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetZulAmanAI(creature); } + + private: + InstanceScript* _instance; + uint8 _gongEvent; + uint32 _gongTimer; + ObjectGuid uiTargetGUID; }; void AddSC_zulaman() { - new npc_forest_frog(); + RegisterZulAmanCreatureAI(npc_forest_frog); new npc_zulaman_hostage(); - new npc_harrison_jones(); + RegisterZulAmanCreatureAI(npc_harrison_jones); } diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h index a15512712582d4..86092f9186ee7d 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h @@ -25,18 +25,19 @@ enum DataTypes { - DATA_GONGEVENT = 0, - DATA_NALORAKK = 1, - DATA_AKILZON = 2, - DATA_JANALAI = 3, - DATA_HALAZZI = 4, - DATA_HEXLORD = 5, - DATA_ZULJIN = 6, - MAX_ENCOUNTER = 7, - DATA_SPIRIT_LYNX = 8, - DATA_CHESTLOOTED = 9, - TYPE_RAND_VENDOR_1 = 10, - TYPE_RAND_VENDOR_2 = 11 + DATA_NALORAKK = 0, + DATA_AKILZON = 1, + DATA_JANALAI = 2, + DATA_HALAZZI = 3, + DATA_HEXLORD = 4, + DATA_ZULJIN = 5, + MAX_ENCOUNTER = 6, + DATA_SPIRIT_LYNX = 7, + TYPE_RAND_VENDOR_1 = 8, + TYPE_RAND_VENDOR_2 = 9, + DATA_STRANGE_GONG = 10, + DATA_MASSIVE_GATE = 11, + DATA_HEXLORD_GATE = 12 }; enum CreatureIds @@ -69,6 +70,15 @@ enum GameobjectIds GO_STRANGE_GONG = 187359 }; +enum MiscIds +{ + DATA_TIMED_RUN = 0, + ACTION_START_TIMED_RUN = 0, + GROUP_TIMED_RUN = 1 +}; + +uint32 constexpr PersistentDataCount = 1; + template inline AI* GetZulAmanAI(T* obj) { From e2be8fb296f54f439f319cb94c68172820ff6d79 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 08:41:46 -0300 Subject: [PATCH 015/105] fix(Scripts/ZulAman): Fix Akilzon not spawning eagles and update script (#20493) * fix(Scripts/ZulAman): Fix Akilzon not spawning eagles and update script * Update boss_akilzon.cpp --- .../rev_1731176128691196300.sql | 4 + .../EasternKingdoms/ZulAman/boss_akilzon.cpp | 305 +++++++----------- 2 files changed, 129 insertions(+), 180 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731176128691196300.sql diff --git a/data/sql/updates/pending_db_world/rev_1731176128691196300.sql b/data/sql/updates/pending_db_world/rev_1731176128691196300.sql new file mode 100644 index 00000000000000..bb2a54344489c8 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731176128691196300.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `creature_template_movement` WHERE `CreatureId` = 24858; +INSERT INTO `creature_template_movement` (`CreatureId`, `Ground`, `Flight`) VALUES +(24858, 1, 1); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp index ee9b78f81283b7..f2e1c70f1eb171 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp @@ -58,26 +58,6 @@ enum Says constexpr auto NPC_SOARING_EAGLE = 24858; -//enum Misc -//{ -// SE_LOC_X_MAX = 400, -// SE_LOC_X_MIN = 335, -// SE_LOC_Y_MAX = 1435, -// SE_LOC_Y_MIN = 1370 -//}; - -enum Events -{ - EVENT_STATIC_DISRUPTION = 1, - EVENT_GUST_OF_WIND = 2, - EVENT_CALL_LIGHTNING = 3, - EVENT_ELECTRICAL_STORM = 4, - EVENT_RAIN = 5, - EVENT_SUMMON_EAGLES = 6, - EVENT_STORM_SEQUENCE = 7, - EVENT_ENRAGE = 8 -}; - class boss_akilzon : public CreatureScript { public: @@ -85,9 +65,7 @@ class boss_akilzon : public CreatureScript struct boss_akilzonAI : public BossAI { - boss_akilzonAI(Creature* creature) : BossAI(creature, DATA_AKILZON) - { - } + boss_akilzonAI(Creature* creature) : BossAI(creature, DATA_AKILZON) { } void Reset() override { @@ -97,32 +75,103 @@ class boss_akilzon : public CreatureScript CloudGUID.Clear(); CycloneGUID.Clear(); - for (uint8 i = 0; i < 8; ++i) - BirdGUIDs[i].Clear(); - StormCount = 0; isRaining = false; SetWeather(WEATHER_STATE_FINE, 0.0f); + + me->m_Events.KillAllEvents(false); } void JustEngagedWith(Unit* /*who*/) override { - events.ScheduleEvent(EVENT_STATIC_DISRUPTION, urand(10000, 20000)); // 10 to 20 seconds (bosskillers) - events.ScheduleEvent(EVENT_GUST_OF_WIND, urand(20000, 30000)); // 20 to 30 seconds(bosskillers) - events.ScheduleEvent(EVENT_CALL_LIGHTNING, urand(10000, 20000)); // totaly random timer. can't find any info on this - events.ScheduleEvent(EVENT_ELECTRICAL_STORM, 60000); // 60 seconds(bosskillers) - events.ScheduleEvent(EVENT_RAIN, urand(47000, 52000)); - events.ScheduleEvent(EVENT_ENRAGE, 10 * MINUTE * IN_MILLISECONDS); // 10 minutes till enrage(bosskillers) + ScheduleTimedEvent(10s, 20s, [&]{ + Unit* target = SelectTarget(SelectTargetMethod::Random, 1); + if (!target) + target = me->GetVictim(); + if (target) + { + TargetGUID = target->GetGUID(); + DoCast(target, SPELL_STATIC_DISRUPTION, false); + me->SetInFront(me->GetVictim()); + } + }, 10s, 18s); + + ScheduleTimedEvent(20s, 30s, [&] { + Unit* target = SelectTarget(SelectTargetMethod::Random, 1); + if (!target) + target = me->GetVictim(); + if (target) + DoCast(target, SPELL_GUST_OF_WIND); + }, 20s, 30s); + + ScheduleTimedEvent(10s, 20s, [&] { + DoCastVictim(SPELL_CALL_LIGHTNING); + }, 12s, 17s); + + ScheduleTimedEvent(1min, [&] { + Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50, true); + if (!target) + { + EnterEvadeMode(); + return; + } + target->CastSpell(target, 44007, true); // cloud visual + DoCast(target, SPELL_ELECTRICAL_STORM, false); // storm cyclon + visual + float x, y, z; + target->GetPosition(x, y, z); + + Unit* Cloud = me->SummonTrigger(x, y, me->GetPositionZ() + 16, 0, 15000); + if (Cloud) + { + target->GetMotionMaster()->MoveJump(Cloud->GetPosition(), 1.0f, 1.0f); + + CloudGUID = Cloud->GetGUID(); + Cloud->SetDisableGravity(true); + Cloud->StopMoving(); + Cloud->SetObjectScale(1.0f); + Cloud->SetFaction(FACTION_FRIENDLY); + Cloud->SetMaxHealth(9999999); + Cloud->SetHealth(9999999); + Cloud->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + + me->m_Events.AddEventAtOffset([&, Cloud] { + HandleStormSequence(Cloud); + }, 3s); + } + + StormCount = 1; + + me->m_Events.AddEventAtOffset([&] { + if (!isRaining) + { + SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); + isRaining = true; + } + }, Seconds(urand(47, 52))); + }, 1min); + + ScheduleTimedEvent(47s, 52s, [&] { + if (!isRaining) + { + SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); + isRaining = true; + } + }, 47s, 52s); + + me->m_Events.AddEventAtOffset([&] { + Talk(SAY_ENRAGE); + DoCastSelf(SPELL_BERSERK, true); + }, 10min); Talk(SAY_AGGRO); - //DoZoneInCombat(); } void JustDied(Unit* /*killer*/) override { Talk(SAY_DEATH); _JustDied(); + me->m_Events.KillAllEvents(false); } void KilledUnit(Unit* who) override @@ -133,18 +182,14 @@ class boss_akilzon : public CreatureScript void SetWeather(uint32 weather, float grade) { - Map* map = me->GetMap(); - if (!map->IsDungeon()) - return; - - WorldPacket data(SMSG_WEATHER, (4 + 4 + 4)); - data << uint32(weather) << float(grade) << uint8(0); - - map->SendToPlayers(&data); + me->GetMap()->SetZoneWeather(me->GetZoneId(), WeatherState(weather), grade); } void HandleStormSequence(Unit* Cloud) // 1: begin, 2-9: tick, 10: end { + if (!Cloud) + return; + if (StormCount < 10 && StormCount > 1) { // deal damage @@ -159,9 +204,9 @@ class boss_akilzon : public CreatureScript Cell::VisitAllObjects(me, searcher, SIZE_OF_GRIDS); // deal damage - for (std::list::const_iterator i = tempUnitMap.begin(); i != tempUnitMap.end(); ++i) + for (auto const& target : tempUnitMap) { - if (Unit* target = (*i)) + if (target) { if (Cloud && !Cloud->IsWithinDist(target, 6, false)) Cloud->CastCustomSpell(target, SPELL_ZAP, &bp0, nullptr, nullptr, true, 0, 0, me->GetGUID()); @@ -192,158 +237,58 @@ class boss_akilzon : public CreatureScript if (StormCount > 10) { StormCount = 0; // finish - events.ScheduleEvent(EVENT_SUMMON_EAGLES, 5000); + + me->m_Events.AddEventAtOffset([&] { + SummonEagles(); + }, 5s); + me->InterruptNonMeleeSpells(false); CloudGUID.Clear(); if (Cloud) - Unit::DealDamage(Cloud, Cloud, Cloud->GetHealth(), nullptr, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, nullptr, false); + Cloud->KillSelf(); SetWeather(WEATHER_STATE_FINE, 0.0f); isRaining = false; } - events.ScheduleEvent(EVENT_STORM_SEQUENCE, 1000); + + me->m_Events.AddEventAtOffset([&] { + Unit* target = ObjectAccessor::GetUnit(*me, CloudGUID); + if (!target || !target->IsAlive()) + return; + else if (Unit* Cyclone = ObjectAccessor::GetUnit(*me, CycloneGUID)) + Cyclone->CastSpell(target, SPELL_SAND_STORM, true); // keep casting or... + HandleStormSequence(target); + }, 1s); } - void UpdateAI(uint32 diff) override + void SummonEagles() { - if (!UpdateVictim()) - return; + Talk(SAY_SUMMON); - events.Update(diff); + float x, y, z; + me->GetPosition(x, y, z); - while (uint32 eventId = events.ExecuteEvent()) + for (uint8 i = 0; i < 8; ++i) { - switch (eventId) + Unit* bird = ObjectAccessor::GetUnit(*me, BirdGUIDs[i]); + if (!bird) //they despawned on die { - case EVENT_STATIC_DISRUPTION: - { - Unit* target = SelectTarget(SelectTargetMethod::Random, 1); - if (!target) - target = me->GetVictim(); - if (target) - { - TargetGUID = target->GetGUID(); - DoCast(target, SPELL_STATIC_DISRUPTION, false); - me->SetInFront(me->GetVictim()); - } - /*if (float dist = me->IsWithinDist3d(target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 5.0f) dist = 5.0f; - SDisruptAOEVisual_Timer = 1000 + std::floor(dist / 30 * 1000.0f);*/ - events.ScheduleEvent(EVENT_STATIC_DISRUPTION, urand(10000, 18000)); - break; - } - case EVENT_GUST_OF_WIND: - { - Unit* target = SelectTarget(SelectTargetMethod::Random, 1); - if (!target) - target = me->GetVictim(); - if (target) - DoCast(target, SPELL_GUST_OF_WIND); - events.ScheduleEvent(EVENT_GUST_OF_WIND, urand(20000, 30000)); - break; - } - case EVENT_CALL_LIGHTNING: - DoCastVictim(SPELL_CALL_LIGHTNING); - events.ScheduleEvent(EVENT_CALL_LIGHTNING, urand(12000, 17000)); // totaly random timer. can't find any info on this - break; - case EVENT_ELECTRICAL_STORM: - { - Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50, true); - if (!target) - { - EnterEvadeMode(); - return; - } - target->CastSpell(target, 44007, true); // cloud visual - DoCast(target, SPELL_ELECTRICAL_STORM, false); // storm cyclon + visual - float x, y, z; - target->GetPosition(x, y, z); - /// @todo: fix it in correct way, that causes player to can fly until logout - /* - if (target) - { - target->SetDisableGravity(true); - target->MonsterMoveWithSpeed(x, y, me->GetPositionZ()+15, 0); - } - */ - - Unit* Cloud = me->SummonTrigger(x, y, me->GetPositionZ() + 16, 0, 15000); - if (Cloud) - { - CloudGUID = Cloud->GetGUID(); - Cloud->SetDisableGravity(true); - Cloud->StopMoving(); - Cloud->SetObjectScale(1.0f); - Cloud->SetFaction(FACTION_FRIENDLY); - Cloud->SetMaxHealth(9999999); - Cloud->SetHealth(9999999); - Cloud->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - } - StormCount = 1; - events.ScheduleEvent(EVENT_ELECTRICAL_STORM, 60000); // 60 seconds(bosskillers) - events.ScheduleEvent(EVENT_RAIN, urand(47000, 52000)); - break; - } - case EVENT_RAIN: - if (!isRaining) - { - SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); - isRaining = true; - } - else - events.ScheduleEvent(EVENT_RAIN, 1000); - break; - case EVENT_STORM_SEQUENCE: - { - Unit* target = ObjectAccessor::GetUnit(*me, CloudGUID); - if (!target || !target->IsAlive()) - { - EnterEvadeMode(); - return; - } - else if (Unit* Cyclone = ObjectAccessor::GetUnit(*me, CycloneGUID)) - Cyclone->CastSpell(target, SPELL_SAND_STORM, true); // keep casting or... - HandleStormSequence(target); - break; - } - case EVENT_SUMMON_EAGLES: - Talk(SAY_SUMMON); - - float x, y, z; - me->GetPosition(x, y, z); - - for (uint8 i = 0; i < 8; ++i) - { - Unit* bird = ObjectAccessor::GetUnit(*me, BirdGUIDs[i]); - if (!bird) //they despawned on die - { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - { - x = target->GetPositionX() + irand(-10, 10); - y = target->GetPositionY() + irand(-10, 10); - z = target->GetPositionZ() + urand(16, 20); - if (z > 95) - z = 95.0f - urand(0, 5); - } - Creature* creature = me->SummonCreature(NPC_SOARING_EAGLE, x, y, z, 0, TEMPSUMMON_CORPSE_DESPAWN, 0); - if (creature) - { - creature->AddThreat(me->GetVictim(), 1.0f); - creature->AI()->AttackStart(me->GetVictim()); - BirdGUIDs[i] = creature->GetGUID(); - } - } - } - break; - case EVENT_ENRAGE: - Talk(SAY_ENRAGE); - DoCast(me, SPELL_BERSERK, true); - events.ScheduleEvent(EVENT_ENRAGE, 600000); - break; - default: - break; + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) + { + x = target->GetPositionX() + irand(-10, 10); + y = target->GetPositionY() + irand(-10, 10); + z = target->GetPositionZ() + urand(16, 20); + if (z > 95) + z = 95.0f - urand(0, 5); + } +; + if (Creature* creature = me->SummonCreature(NPC_SOARING_EAGLE, x, y, z, 0, TEMPSUMMON_CORPSE_DESPAWN, 0)) + { + creature->AddThreat(me->GetVictim(), 1.0f); + creature->AI()->AttackStart(me->GetVictim()); + BirdGUIDs[i] = creature->GetGUID(); + } } } - - DoMeleeAttackIfReady(); } private: From 60c6cbdeb8b03ff090a2200f4321ca3fd9eab719 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 10 Nov 2024 11:42:19 +0000 Subject: [PATCH 016/105] chore(DB): import pending files Referenced commit(s): 8904a1330479f3f5c141d239c888a92f9ec0e7b9 --- .../rev_1731176128691196300.sql => db_world/2024_11_10_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731176128691196300.sql => db_world/2024_11_10_00.sql} (79%) diff --git a/data/sql/updates/pending_db_world/rev_1731176128691196300.sql b/data/sql/updates/db_world/2024_11_10_00.sql similarity index 79% rename from data/sql/updates/pending_db_world/rev_1731176128691196300.sql rename to data/sql/updates/db_world/2024_11_10_00.sql index bb2a54344489c8..4ede8d14b2d9fb 100644 --- a/data/sql/updates/pending_db_world/rev_1731176128691196300.sql +++ b/data/sql/updates/db_world/2024_11_10_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_09_03 -> 2024_11_10_00 -- DELETE FROM `creature_template_movement` WHERE `CreatureId` = 24858; INSERT INTO `creature_template_movement` (`CreatureId`, `Ground`, `Flight`) VALUES From 734bcb5d10f76e4389390ea71fdc44f6c81f1240 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 11:21:58 -0300 Subject: [PATCH 017/105] chore(Core/Creature): Fix typo (#20510) --- src/server/game/AI/SmartScripts/SmartScript.cpp | 2 +- src/server/game/Entities/Creature/CreatureData.h | 2 +- src/server/game/Entities/Creature/enuminfo_CreatureData.cpp | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index 553a5b82d9f861..4605b9fba8e947 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -5073,7 +5073,7 @@ void SmartScript::GetScript() if (CreatureTemplate const* cInfo = me->GetCreatureTemplate()) { - if (cInfo->HasFlagsExtra(CREATURE_FLAG_DONT_OVERRIDE_ENTRY_SAI)) + if (cInfo->HasFlagsExtra(CREATURE_FLAG_EXTRA_DONT_OVERRIDE_ENTRY_SAI)) { e = sSmartScriptMgr->GetScript((int32)me->GetEntry(), mScriptType); FillScript(e, me, nullptr); diff --git a/src/server/game/Entities/Creature/CreatureData.h b/src/server/game/Entities/Creature/CreatureData.h index f7ee05b0070ceb..4ca6cda4ab4cb0 100644 --- a/src/server/game/Entities/Creature/CreatureData.h +++ b/src/server/game/Entities/Creature/CreatureData.h @@ -69,7 +69,7 @@ enum CreatureFlagsExtra : uint32 CREATURE_FLAG_EXTRA_MODULE = 0x01000000, CREATURE_FLAG_EXTRA_DONT_CALL_ASSISTANCE = 0x02000000, // Prevent creatures from calling for assistance on initial aggro CREATURE_FLAG_EXTRA_IGNORE_ALL_ASSISTANCE_CALLS = 0x04000000, // Prevents creature from responding to assistance calls - CREATURE_FLAG_DONT_OVERRIDE_ENTRY_SAI = 0x08000000, // Load both ENTRY and GUID specific SAI + CREATURE_FLAG_EXTRA_DONT_OVERRIDE_ENTRY_SAI = 0x08000000, // Load both ENTRY and GUID specific SAI CREATURE_FLAG_EXTRA_DUNGEON_BOSS = 0x10000000, // creature is a dungeon boss (SET DYNAMICALLY, DO NOT ADD IN DB) CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING = 0x20000000, // creature ignore pathfinding CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK = 0x40000000, // creature is immune to knockback effects diff --git a/src/server/game/Entities/Creature/enuminfo_CreatureData.cpp b/src/server/game/Entities/Creature/enuminfo_CreatureData.cpp index 1fa83fe3fde2ea..a2efe7bcc7f449 100644 --- a/src/server/game/Entities/Creature/enuminfo_CreatureData.cpp +++ b/src/server/game/Entities/Creature/enuminfo_CreatureData.cpp @@ -58,7 +58,7 @@ AC_API_EXPORT EnumText EnumUtils::ToString(CreatureFlagsExtr case CREATURE_FLAG_EXTRA_MODULE: return { "CREATURE_FLAG_EXTRA_MODULE", "CREATURE_FLAG_EXTRA_MODULE", "" }; case CREATURE_FLAG_EXTRA_DONT_CALL_ASSISTANCE: return { "CREATURE_FLAG_EXTRA_DONT_CALL_ASSISTANCE", "CREATURE_FLAG_EXTRA_DONT_CALL_ASSISTANCE", "Prevent creatures from calling for assistance on initial aggro" }; case CREATURE_FLAG_EXTRA_IGNORE_ALL_ASSISTANCE_CALLS: return { "CREATURE_FLAG_EXTRA_IGNORE_ALL_ASSISTANCE_CALLS", "CREATURE_FLAG_EXTRA_IGNORE_ALL_ASSISTANCE_CALLS", "Prevents creature from responding to assistance calls" }; - case CREATURE_FLAG_DONT_OVERRIDE_ENTRY_SAI: return { "CREATURE_FLAG_DONT_OVERRIDE_ENTRY_SAI", "CREATURE_FLAG_DONT_OVERRIDE_ENTRY_SAI", "Load both ENTRY and GUID specific SAI" }; + case CREATURE_FLAG_EXTRA_DONT_OVERRIDE_ENTRY_SAI: return { "CREATURE_FLAG_EXTRA_DONT_OVERRIDE_ENTRY_SAI", "CREATURE_FLAG_EXTRA_DONT_OVERRIDE_ENTRY_SAI", "Load both ENTRY and GUID specific SAI" }; case CREATURE_FLAG_EXTRA_DUNGEON_BOSS: return { "CREATURE_FLAG_EXTRA_DUNGEON_BOSS", "CREATURE_FLAG_EXTRA_DUNGEON_BOSS", "creature is a dungeon boss (SET DYNAMICALLY, DO NOT ADD IN DB)" }; case CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING: return { "CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING", "CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING", "creature ignore pathfinding" }; case CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK: return { "CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK", "CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK", "creature is immune to knockback effects" }; @@ -102,7 +102,7 @@ AC_API_EXPORT CreatureFlagsExtra EnumUtils::FromIndex(std::s case 24: return CREATURE_FLAG_EXTRA_MODULE; case 25: return CREATURE_FLAG_EXTRA_DONT_CALL_ASSISTANCE; case 26: return CREATURE_FLAG_EXTRA_IGNORE_ALL_ASSISTANCE_CALLS; - case 27: return CREATURE_FLAG_DONT_OVERRIDE_ENTRY_SAI; + case 27: return CREATURE_FLAG_EXTRA_DONT_OVERRIDE_ENTRY_SAI; case 28: return CREATURE_FLAG_EXTRA_DUNGEON_BOSS; case 29: return CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING; case 30: return CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK; @@ -143,7 +143,7 @@ AC_API_EXPORT std::size_t EnumUtils::ToIndex(CreatureFlagsEx case CREATURE_FLAG_EXTRA_MODULE: return 24; case CREATURE_FLAG_EXTRA_DONT_CALL_ASSISTANCE: return 25; case CREATURE_FLAG_EXTRA_IGNORE_ALL_ASSISTANCE_CALLS: return 26; - case CREATURE_FLAG_DONT_OVERRIDE_ENTRY_SAI: return 27; + case CREATURE_FLAG_EXTRA_DONT_OVERRIDE_ENTRY_SAI: return 27; case CREATURE_FLAG_EXTRA_DUNGEON_BOSS: return 28; case CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING: return 29; case CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK: return 30; From 4da49dd63ada801af308818eb6908cc3782255db Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 11:33:01 -0300 Subject: [PATCH 018/105] fix(Scripts/ZulAman): Fix crash in Nalorakk script (#20499) --- .../EasternKingdoms/ZulAman/boss_nalorakk.cpp | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp index 7bd34745d2cbd8..b3c9d4398d15b3 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp @@ -130,7 +130,6 @@ struct boss_nalorakk : public BossAI _introScheduler.Schedule(5s, GROUP_CHECK_DEAD, [this](TaskContext context) { if (CheckFullyDeadGroup(_waveList)) - { if (_phase == PHASE_SEND_GUARDS_1) { _introScheduler.CancelGroup(GROUP_CHECK_DEAD); @@ -144,7 +143,6 @@ struct boss_nalorakk : public BossAI }); _phase = PHASE_SEND_GUARDS_2; } - } context.Repeat(5s); }); break; @@ -157,7 +155,6 @@ struct boss_nalorakk : public BossAI _introScheduler.Schedule(5s, GROUP_CHECK_DEAD, [this](TaskContext context) { if (CheckFullyDeadGroup(_waveList)) - { if (_phase == PHASE_SEND_GUARDS_2) { _introScheduler.CancelGroup(GROUP_CHECK_DEAD); @@ -171,8 +168,6 @@ struct boss_nalorakk : public BossAI }); _phase = PHASE_SEND_GUARDS_3; } - - } context.Repeat(5s); }); break; @@ -183,13 +178,12 @@ struct boss_nalorakk : public BossAI _introScheduler.Schedule(5s, GROUP_CHECK_DEAD, [this](TaskContext context) { if (CheckFullyDeadGroup(_waveList)) - { if (_phase == PHASE_SEND_GUARDS_3) { _introScheduler.CancelGroup(GROUP_CHECK_DEAD); _waveList.clear(); Talk(SAY_RUN_AWAY); - me->GetMotionMaster()->MovePath(me->GetEntry()*100+3, false); + me->GetMotionMaster()->MovePath(me->GetEntry() * 100 + 3, false); _introScheduler.Schedule(6s, [this](TaskContext) { me->SetFacingTo(1.54f); @@ -197,7 +191,6 @@ struct boss_nalorakk : public BossAI }); _phase = PHASE_SEND_GUARDS_4; } - } context.Repeat(5s); }); break; @@ -209,7 +202,6 @@ struct boss_nalorakk : public BossAI _introScheduler.Schedule(5s, GROUP_CHECK_DEAD, [this](TaskContext context) { if (CheckFullyDeadGroup(_waveList)) - { if (_phase == PHASE_SEND_GUARDS_4) { _introScheduler.CancelGroup(GROUP_CHECK_DEAD); @@ -221,7 +213,6 @@ struct boss_nalorakk : public BossAI _phase = PHASE_START_COMBAT; _ranIntro = true; } - } context.Repeat(5s); }); break; @@ -245,15 +236,13 @@ struct boss_nalorakk : public BossAI context.Repeat(); }).Schedule(10s, 15s, GROUP_HUMAN, [this](TaskContext context) { - if (!me->GetVictim()->HasAura(SPELL_MANGLEEFFECT)) + if (me->GetVictim() && !me->GetVictim()->HasAura(SPELL_MANGLEEFFECT)) { DoCastVictim(SPELL_MANGLE); context.Repeat(1s); } else - { context.Repeat(); - } }).Schedule(10min, GROUP_BERSERK, [this](TaskContext) { Talk(SAY_BERSERK); From e8366f69350fd09ed9d8b37474a7b3274b761559 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 14:54:05 -0300 Subject: [PATCH 019/105] fix(Scripts/SSC): Fix Leotheras running in melee range in demon phase (#20507) * fix(Scripts/SSC): Fix Leotheras running in melee range in demon phase * Update boss_leotheras_the_blind.cpp --- .../boss_leotheras_the_blind.cpp | 20 ++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp index aef75b35927ae5..621ecbc2bc348f 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp @@ -128,6 +128,14 @@ struct boss_leotheras_the_blind : public BossAI }); } + void AttackStart(Unit* who) override + { + if (me->HasAura(SPELL_METAMORPHOSIS)) + AttackStartCaster(who, 40.0f); + else + ScriptedAI::AttackStart(who); + } + void DoAction(int32 actionId) override { if (actionId == ACTION_CHECK_SPELLBINDERS) @@ -172,15 +180,13 @@ struct boss_leotheras_the_blind : public BossAI void MoveToTargetIfOutOfRange(Unit* target) { - if (me->GetDistance2d(target) > 40.0f) + if (!me->IsWithinDistInMap(target, 40.0f)) { - me->GetMotionMaster()->MoveChase(target, 5.0f, 0); + me->GetMotionMaster()->MoveChase(target, 40.0f, 0); me->AddThreat(target, 0.0f); } else - { me->GetMotionMaster()->Clear(); - } } void DemonTime() @@ -204,7 +210,7 @@ struct boss_leotheras_the_blind : public BossAI { DoResetThreatList(); me->LoadEquipment(); - me->GetMotionMaster()->MoveChase(me->GetVictim(), 0.0f); + me->ResumeChasingVictim(); me->RemoveAurasDueToSpell(SPELL_METAMORPHOSIS); scheduler.CancelGroup(GROUP_DEMON); ElfTime(); @@ -223,9 +229,7 @@ struct boss_leotheras_the_blind : public BossAI if (me->GetDisplayId() == me->GetNativeDisplayId()) { if (me->GetReactState() != REACT_PASSIVE) - { DoMeleeAttackIfReady(); - } } else if (me->isAttackReady(BASE_ATTACK)) { @@ -235,9 +239,7 @@ struct boss_leotheras_the_blind : public BossAI DoMeleeAttackIfReady(); } else - { me->setAttackTimer(BASE_ATTACK, 2000); - } } } private: From 91b8cc29cfa2652f84a780998ad82e37b950934c Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 14:54:33 -0300 Subject: [PATCH 020/105] fix(Scripts/Spells): Limit Cyclone (39594) to 4 targets (#20506) --- data/sql/updates/pending_db_world/rev_1731221614295821000.sql | 4 ++++ src/server/scripts/Spells/spell_generic.cpp | 1 + 2 files changed, 5 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731221614295821000.sql diff --git a/data/sql/updates/pending_db_world/rev_1731221614295821000.sql b/data/sql/updates/pending_db_world/rev_1731221614295821000.sql new file mode 100644 index 00000000000000..806f99e6fb14de --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731221614295821000.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `spell_script_names` WHERE `spell_id` = 39594; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(39594, 'spell_gen_select_target_count_15_4'); diff --git a/src/server/scripts/Spells/spell_generic.cpp b/src/server/scripts/Spells/spell_generic.cpp index cbdf5c4a43eb76..d139bccd03366c 100644 --- a/src/server/scripts/Spells/spell_generic.cpp +++ b/src/server/scripts/Spells/spell_generic.cpp @@ -5348,6 +5348,7 @@ void AddSC_generic_spell_scripts() RegisterSpellScriptWithArgs(spell_gen_select_target_count, "spell_gen_select_target_count_7_1", TARGET_UNIT_SRC_AREA_ENTRY, 1); RegisterSpellScriptWithArgs(spell_gen_select_target_count, "spell_gen_select_target_count_24_1", TARGET_UNIT_CONE_ENEMY_24, 1); RegisterSpellScriptWithArgs(spell_gen_select_target_count, "spell_gen_select_target_count_30_1", TARGET_UNIT_SRC_AREA_ALLY, 1); + RegisterSpellScriptWithArgs(spell_gen_select_target_count, "spell_gen_select_target_count_15_4", TARGET_UNIT_SRC_AREA_ENEMY, 4); RegisterSpellScript(spell_gen_use_spell_base_level_check); RegisterSpellScript(spell_gen_proc_from_direct_damage); RegisterSpellScript(spell_gen_no_offhand_proc); From 8e05cd7e8096d4254c337d808802259c09050b26 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 14:55:04 -0300 Subject: [PATCH 021/105] refactor(Scripts/ZulAman): Move Spirit of the Lynx to SAI (#20498) --- .../rev_1731208074789403000.sql | 9 ++ .../EasternKingdoms/ZulAman/boss_halazzi.cpp | 99 +++---------------- 2 files changed, 23 insertions(+), 85 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731208074789403000.sql diff --git a/data/sql/updates/pending_db_world/rev_1731208074789403000.sql b/data/sql/updates/pending_db_world/rev_1731208074789403000.sql new file mode 100644 index 00000000000000..d15098e2d3a7ce --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731208074789403000.sql @@ -0,0 +1,9 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 24143; + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 24143) AND (`source_type` = 0) AND (`id` IN (0, 1, 2, 3)); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(24143, 0, 0, 0, 0, 0, 100, 0, 30000, 50000, 30000, 50000, 0, 0, 11, 43290, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Spirit of the Lynx - In Combat - Cast \'Lynx Flurry\''), +(24143, 0, 1, 0, 0, 0, 100, 0, 4000, 4000, 4000, 4000, 0, 0, 11, 43243, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Spirit of the Lynx - In Combat - Cast \'Shred Armor\''), +(24143, 0, 2, 0, 25, 0, 100, 0, 0, 0, 0, 0, 0, 0, 42, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Spirit of the Lynx - On Reset - Set Invincibility Hp 1'), +(24143, 0, 3, 0, 2, 0, 100, 0, 20, 20, 0, 0, 0, 0, 223, 0, 0, 0, 0, 0, 0, 23, 0, 0, 0, 0, 0, 0, 0, 0, 'Spirit of the Lynx - Between 20-20% Health - Do Action ID 0'); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp index 46efc1da6bf7cc..4524cd4a7378b6 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp @@ -74,6 +74,11 @@ enum Groups GROUP_MERGE = 2 }; +enum Actions +{ + ACTION_MERGE = 0 +}; + struct boss_halazzi : public BossAI { boss_halazzi(Creature* creature) : BossAI(creature, DATA_HALAZZI) @@ -118,33 +123,19 @@ struct boss_halazzi : public BossAI void DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damagetype*/, SpellSchoolMask /*damageSchoolMask*/) override { if (damage >= me->GetHealth() && _phase != PHASE_ENRAGE) - { damage = 0; - } else { if (_phase == PHASE_LYNX || _phase == PHASE_ENRAGE) { _healthCheckPercentage = 25 * (3 - _transformCount); if (!HealthAbovePct(_healthCheckPercentage)) - { EnterPhase(PHASE_SPLIT); - } } else if (_phase == PHASE_HUMAN) { - if (Creature* lynx = instance->GetCreature(DATA_SPIRIT_LYNX)) - { - if (!HealthAbovePct(20) || !lynx->HealthAbovePct(20)) - { - EnterPhase(PHASE_MERGE); - } - } - else - { - //should not really happen - EnterEvadeMode(); - } + if (!HealthAbovePct(20)) + EnterPhase(PHASE_MERGE); } } } @@ -152,17 +143,13 @@ struct boss_halazzi : public BossAI void SpellHit(Unit*, SpellInfo const* spell) override { if (spell->Id == SPELL_TRANSFORM_SPLIT2) - { EnterPhase(PHASE_HUMAN); - } } void AttackStart(Unit* who) override { if (_phase != PHASE_MERGE) - { BossAI::AttackStart(who); - } } void EnterPhase(PhaseHalazzi nextPhase) @@ -175,7 +162,7 @@ struct boss_halazzi : public BossAI { DoCastSelf(SPELL_TRANSFORM_MERGE, true); me->RemoveAurasDueToSpell(SPELL_TRANSFORM_SPLIT2); - me->GetMotionMaster()->MoveChase(me->GetVictim()); + me->ResumeChasingVictim(); } summons.DespawnAll(); me->SetMaxHealth(_lynxFormHealth); @@ -207,13 +194,9 @@ struct boss_halazzi : public BossAI if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) { if (target->IsNonMeleeSpellCast(false)) - { DoCast(target, SPELL_EARTHSHOCK); - } else - { DoCast(target, SPELL_FLAMESHOCK); - } } context.Repeat(10s, 15s); }).Schedule(12s, GROUP_HUMAN, [this](TaskContext context) @@ -236,19 +219,13 @@ struct boss_halazzi : public BossAI scheduler.Schedule(2s, GROUP_MERGE, [this](TaskContext context) { if (Creature* lynx = instance->GetCreature(DATA_SPIRIT_LYNX)) - { if (me->IsWithinDistInMap(lynx, 6.0f)) { if (_transformCount < 3) - { EnterPhase(PHASE_LYNX); - } else - { EnterPhase(PHASE_ENRAGE); - } } - } context.Repeat(2s); }); } @@ -263,9 +240,13 @@ struct boss_halazzi : public BossAI { BossAI::KilledUnit(victim); if (victim->IsPlayer()) - { Talk(SAY_KILL); - } + } + + void DoAction(int32 actionId) override + { + if (actionId == ACTION_MERGE) + EnterPhase(PHASE_MERGE); } void JustDied(Unit* killer) override @@ -281,60 +262,8 @@ struct boss_halazzi : public BossAI uint32 _healthCheckPercentage; PhaseHalazzi _phase; }; -// Spirits Lynx AI -struct npc_halazzi_lynx : public ScriptedAI -{ - npc_halazzi_lynx(Creature* creature) : ScriptedAI(creature) { } - - void Reset() override - { - scheduler.CancelAll(); - } - - void DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damagetype*/, SpellSchoolMask /*damageSchoolMask*/) override - { - if (damage >= me->GetHealth()) - { - damage = 0; - } - } - - void AttackStart(Unit* who) override - { - if (!me->HasUnitFlag(UNIT_FLAG_NON_ATTACKABLE)) - { - ScriptedAI::AttackStart(who); - } - } - - void JustEngagedWith(Unit* who) override - { - ScriptedAI::JustEngagedWith(who); - - ScheduleTimedEvent(30s, 50s, [&] - { - DoCastSelf(SPELL_LYNX_FRENZY); - }, 30s, 50s); - ScheduleTimedEvent(4s, [&]{ - DoCastVictim(SPELL_SHRED_ARMOR); - }, 4s); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - { - return; - } - - scheduler.Update(diff); - - DoMeleeAttackIfReady(); - } -}; void AddSC_boss_halazzi() { RegisterZulAmanCreatureAI(boss_halazzi); - RegisterZulAmanCreatureAI(npc_halazzi_lynx); } From 264f924f46409089a9d982c0991fbbd5745da75a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 10 Nov 2024 17:55:10 +0000 Subject: [PATCH 022/105] chore(DB): import pending files Referenced commit(s): e8366f69350fd09ed9d8b37474a7b3274b761559 --- .../rev_1731208074789403000.sql => db_world/2024_11_10_01.sql} | 1 + .../rev_1731221614295821000.sql => db_world/2024_11_10_02.sql} | 1 + 2 files changed, 2 insertions(+) rename data/sql/updates/{pending_db_world/rev_1731208074789403000.sql => db_world/2024_11_10_01.sql} (96%) rename data/sql/updates/{pending_db_world/rev_1731221614295821000.sql => db_world/2024_11_10_02.sql} (80%) diff --git a/data/sql/updates/pending_db_world/rev_1731208074789403000.sql b/data/sql/updates/db_world/2024_11_10_01.sql similarity index 96% rename from data/sql/updates/pending_db_world/rev_1731208074789403000.sql rename to data/sql/updates/db_world/2024_11_10_01.sql index d15098e2d3a7ce..a14ecc32093a6c 100644 --- a/data/sql/updates/pending_db_world/rev_1731208074789403000.sql +++ b/data/sql/updates/db_world/2024_11_10_01.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_10_00 -> 2024_11_10_01 -- UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 24143; diff --git a/data/sql/updates/pending_db_world/rev_1731221614295821000.sql b/data/sql/updates/db_world/2024_11_10_02.sql similarity index 80% rename from data/sql/updates/pending_db_world/rev_1731221614295821000.sql rename to data/sql/updates/db_world/2024_11_10_02.sql index 806f99e6fb14de..2de8584b763b04 100644 --- a/data/sql/updates/pending_db_world/rev_1731221614295821000.sql +++ b/data/sql/updates/db_world/2024_11_10_02.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_10_01 -> 2024_11_10_02 -- DELETE FROM `spell_script_names` WHERE `spell_id` = 39594; INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES From 3866c35f2f6134c3f1041d041843d250cf79fd73 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 15:02:02 -0300 Subject: [PATCH 023/105] =?UTF-8?q?fix(Scripts/Commands):=20Remove=20Spiri?= =?UTF-8?q?t=20of=20Redemption=20when=20using=20Revive=20=E2=80=A6=20(#204?= =?UTF-8?q?92)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix(Scripts/Commands): Remove Spirit of Redemption when using Revive command --- src/server/scripts/Commands/cs_misc.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/server/scripts/Commands/cs_misc.cpp b/src/server/scripts/Commands/cs_misc.cpp index 94ccfb6eb5e625..fa85bac3fb80a6 100644 --- a/src/server/scripts/Commands/cs_misc.cpp +++ b/src/server/scripts/Commands/cs_misc.cpp @@ -1157,19 +1157,15 @@ class misc_commandscript : public CommandScript static bool HandleReviveCommand(ChatHandler* handler, Optional target) { if (!target) - { target = PlayerIdentifier::FromTargetOrSelf(handler); - } if (!target) - { return false; - } if (target->IsConnected()) { auto targetPlayer = target->GetConnectedPlayer(); - + targetPlayer->RemoveAurasDueToSpell(27827); // Spirit of Redemption targetPlayer->ResurrectPlayer(!AccountMgr::IsPlayerAccount(targetPlayer->GetSession()->GetSecurity()) ? 1.0f : 0.5f); targetPlayer->SpawnCorpseBones(); targetPlayer->SaveToDB(false, false); From bf925eda3c94b5dfd099a740fee33e9c04071867 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 15:44:35 -0300 Subject: [PATCH 024/105] refactor(Scripts/SWP): Update creature scripts to new register method (#20503) --- .../SunwellPlateau/boss_brutallus.cpp | 516 ++++--- .../SunwellPlateau/boss_eredar_twins.cpp | 456 +++--- .../SunwellPlateau/boss_felmyst.cpp | 567 ++++--- .../SunwellPlateau/boss_kalecgos.cpp | 799 +++++----- .../SunwellPlateau/boss_kiljaeden.cpp | 1299 ++++++++--------- .../SunwellPlateau/boss_muru.cpp | 377 +++-- .../SunwellPlateau/sunwell_plateau.h | 2 + 7 files changed, 1921 insertions(+), 2095 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp index 1fdb6a115a76d9..e8e46a03f33351 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp @@ -63,106 +63,95 @@ enum Misc ACTION_SPAWN_FELMYST = 2 }; -class boss_brutallus : public CreatureScript +struct boss_brutallus : public BossAI { -public: - boss_brutallus() : CreatureScript("boss_brutallus") { } + boss_brutallus(Creature* creature) : BossAI(creature, DATA_BRUTALLUS) { } - struct boss_brutallusAI : public BossAI + void Reset() override { - boss_brutallusAI(Creature* creature) : BossAI(creature, DATA_BRUTALLUS) { } - - void Reset() override - { - BossAI::Reset(); - me->CastSpell(me, SPELL_DUAL_WIELD, true); - } + BossAI::Reset(); + me->CastSpell(me, SPELL_DUAL_WIELD, true); + } - void DamageTaken(Unit* who, uint32& damage, DamageEffectType, SpellSchoolMask) override + void DamageTaken(Unit* who, uint32& damage, DamageEffectType, SpellSchoolMask) override + { + if (me->GetReactState() == REACT_PASSIVE && (!who || who->GetEntry() != NPC_MADRIGOSA)) { - if (me->GetReactState() == REACT_PASSIVE && (!who || who->GetEntry() != NPC_MADRIGOSA)) - { - if (who) - Unit::Kill(me, who); - damage = 0; - } + if (who) + Unit::Kill(me, who); + damage = 0; } + } - void JustEngagedWith(Unit* who) override - { - if (who->GetEntry() == NPC_MADRIGOSA) - return; - - Talk(YELL_AGGRO); - BossAI::JustEngagedWith(who); + void JustEngagedWith(Unit* who) override + { + if (who->GetEntry() == NPC_MADRIGOSA) + return; - events.ScheduleEvent(EVENT_SPELL_SLASH, 11000); - events.ScheduleEvent(EVENT_SPELL_STOMP, 30000); - events.ScheduleEvent(EVENT_SPELL_BURN, 45000); - events.ScheduleEvent(EVENT_SPELL_BERSERK, 360000); - } + Talk(YELL_AGGRO); + BossAI::JustEngagedWith(who); - void KilledUnit(Unit* victim) override - { - if (victim->IsPlayer() && roll_chance_i(50)) - Talk(YELL_KILL); - } + events.ScheduleEvent(EVENT_SPELL_SLASH, 11000); + events.ScheduleEvent(EVENT_SPELL_STOMP, 30000); + events.ScheduleEvent(EVENT_SPELL_BURN, 45000); + events.ScheduleEvent(EVENT_SPELL_BERSERK, 360000); + } - void JustDied(Unit* killer) override - { - BossAI::JustDied(killer); - Talk(YELL_DEATH); + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer() && roll_chance_i(50)) + Talk(YELL_KILL); + } - me->CastSpell(me, SPELL_SUMMON_BRUTALLUS_DEATH_CLOUD, true); - if (Creature* madrigosa = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MADRIGOSA))) - madrigosa->AI()->DoAction(ACTION_SPAWN_FELMYST); - } + void JustDied(Unit* killer) override + { + BossAI::JustDied(killer); + Talk(YELL_DEATH); - void AttackStart(Unit* who) override - { - if (who->GetEntry() == NPC_MADRIGOSA) - return; - BossAI::AttackStart(who); - } + me->CastSpell(me, SPELL_SUMMON_BRUTALLUS_DEATH_CLOUD, true); + if (Creature* madrigosa = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MADRIGOSA))) + madrigosa->AI()->DoAction(ACTION_SPAWN_FELMYST); + } - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; + void AttackStart(Unit* who) override + { + if (who->GetEntry() == NPC_MADRIGOSA) + return; + BossAI::AttackStart(who); + } - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_SLASH: - me->CastSpell(me->GetVictim(), SPELL_METEOR_SLASH, false); - events.ScheduleEvent(EVENT_SPELL_SLASH, 10000); - break; - case EVENT_SPELL_STOMP: - me->CastSpell(me->GetVictim(), SPELL_STOMP, false); - Talk(YELL_LOVE); - events.ScheduleEvent(EVENT_SPELL_STOMP, 30000); - break; - case EVENT_SPELL_BURN: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 100.0f, true, true, -SPELL_BURN_DAMAGE)) - me->CastSpell(target, SPELL_BURN, false); - events.ScheduleEvent(EVENT_SPELL_BURN, 60000); - break; - case EVENT_SPELL_BERSERK: - me->CastSpell(me, SPELL_BERSERK, true); - Talk(YELL_BERSERK); - break; - } + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - DoMeleeAttackIfReady(); + switch (events.ExecuteEvent()) + { + case EVENT_SPELL_SLASH: + me->CastSpell(me->GetVictim(), SPELL_METEOR_SLASH, false); + events.ScheduleEvent(EVENT_SPELL_SLASH, 10000); + break; + case EVENT_SPELL_STOMP: + me->CastSpell(me->GetVictim(), SPELL_STOMP, false); + Talk(YELL_LOVE); + events.ScheduleEvent(EVENT_SPELL_STOMP, 30000); + break; + case EVENT_SPELL_BURN: + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 100.0f, true, true, -SPELL_BURN_DAMAGE)) + me->CastSpell(target, SPELL_BURN, false); + events.ScheduleEvent(EVENT_SPELL_BURN, 60000); + break; + case EVENT_SPELL_BERSERK: + me->CastSpell(me, SPELL_BERSERK, true); + Talk(YELL_BERSERK); + break; } - }; - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); + DoMeleeAttackIfReady(); } }; @@ -210,203 +199,192 @@ enum eMadrigosa SPELL_BRUTALLUS_BREAK_ICE = 46637, }; -class npc_madrigosa : public CreatureScript +struct npc_madrigosa : public NullCreatureAI { -public: - npc_madrigosa() : CreatureScript("npc_madrigosa") { } + npc_madrigosa(Creature* creature) : NullCreatureAI(creature) + { + instance = creature->GetInstanceScript(); + bool appear = instance->GetBossState(DATA_BRUTALLUS) != DONE && instance->GetBossState(DATA_MADRIGOSA) == DONE; + creature->SetVisible(appear); + creature->SetStandState(UNIT_STAND_STATE_DEAD); + creature->SetDynamicFlag(UNIT_DYNFLAG_DEAD); + } - struct npc_madrigosaAI : public NullCreatureAI + EventMap events; + InstanceScript* instance; + + void DoAction(int32 param) override { - npc_madrigosaAI(Creature* creature) : NullCreatureAI(creature) + if (param == ACTION_START_EVENT) { - instance = creature->GetInstanceScript(); - bool appear = instance->GetBossState(DATA_BRUTALLUS) != DONE && instance->GetBossState(DATA_MADRIGOSA) == DONE; - creature->SetVisible(appear); - creature->SetStandState(UNIT_STAND_STATE_DEAD); - creature->SetDynamicFlag(UNIT_DYNFLAG_DEAD); + me->SetDisableGravity(true); + me->SetStandState(UNIT_STAND_STATE_STAND); + me->RemoveDynamicFlag(UNIT_DYNFLAG_DEAD); + me->NearTeleportTo(1570.97f, 725.51f, 79.77f, 3.82f); + events.ScheduleEvent(EVENT_MAD_1, 2000); } + else if (param == ACTION_SPAWN_FELMYST) + events.ScheduleEvent(EVENT_SPAWN_FELMYST, 60000); + } - EventMap events; - InstanceScript* instance; - - void DoAction(int32 param) override + void UpdateAI(uint32 diff) override + { + events.Update(diff); + switch (events.ExecuteEvent()) { - if (param == ACTION_START_EVENT) + case EVENT_MAD_1: + me->SetVisible(true); + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) { - me->SetDisableGravity(true); - me->SetStandState(UNIT_STAND_STATE_STAND); - me->RemoveDynamicFlag(UNIT_DYNFLAG_DEAD); - me->NearTeleportTo(1570.97f, 725.51f, 79.77f, 3.82f); - events.ScheduleEvent(EVENT_MAD_1, 2000); + me->SetTarget(brutallus->GetGUID()); + brutallus->SetReactState(REACT_PASSIVE); + brutallus->setActive(true); } - else if (param == ACTION_SPAWN_FELMYST) - events.ScheduleEvent(EVENT_SPAWN_FELMYST, 60000); - } - - void UpdateAI(uint32 diff) override - { - events.Update(diff); - switch (events.ExecuteEvent()) + me->GetMotionMaster()->MovePoint(1, 1477.94f, 643.22f, 21.21f); + me->AddUnitState(UNIT_STATE_NO_ENVIRONMENT_UPD); + events.ScheduleEvent(EVENT_MAD_2, 6000); + break; + case EVENT_MAD_2: + Talk(SAY_MAD_1); + me->CastSpell(me, SPELL_MADRIGOSA_FREEZE, false); + events.ScheduleEvent(EVENT_MAD_2_1, 1000); + break; + case EVENT_MAD_2_1: + me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); + me->SetDisableGravity(false); + me->CastSpell(me, SPELL_MADRIGOSA_FROST_BREATH, false); + events.ScheduleEvent(EVENT_MAD_3, 7000); + break; + case EVENT_MAD_3: + Talk(SAY_MAD_2); + events.ScheduleEvent(EVENT_MAD_4, 7000); + break; + case EVENT_MAD_4: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + brutallus->AI()->Talk(YELL_INTRO); + events.ScheduleEvent(EVENT_MAD_5, 5000); + break; + case EVENT_MAD_5: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) { - case EVENT_MAD_1: - me->SetVisible(true); - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - me->SetTarget(brutallus->GetGUID()); - brutallus->SetReactState(REACT_PASSIVE); - brutallus->setActive(true); - } - me->GetMotionMaster()->MovePoint(1, 1477.94f, 643.22f, 21.21f); - me->AddUnitState(UNIT_STATE_NO_ENVIRONMENT_UPD); - events.ScheduleEvent(EVENT_MAD_2, 6000); - break; - case EVENT_MAD_2: - Talk(SAY_MAD_1); - me->CastSpell(me, SPELL_MADRIGOSA_FREEZE, false); - events.ScheduleEvent(EVENT_MAD_2_1, 1000); - break; - case EVENT_MAD_2_1: - me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); - me->SetDisableGravity(false); - me->CastSpell(me, SPELL_MADRIGOSA_FROST_BREATH, false); - events.ScheduleEvent(EVENT_MAD_3, 7000); - break; - case EVENT_MAD_3: - Talk(SAY_MAD_2); - events.ScheduleEvent(EVENT_MAD_4, 7000); - break; - case EVENT_MAD_4: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - brutallus->AI()->Talk(YELL_INTRO); - events.ScheduleEvent(EVENT_MAD_5, 5000); - break; - case EVENT_MAD_5: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - brutallus->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_ATTACK1H); - me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_ATTACK1H); - } - events.ScheduleEvent(EVENT_MAD_6, 10000); - break; - case EVENT_MAD_6: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - brutallus->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); - me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); - } - me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); - me->SetDisableGravity(true); - events.ScheduleEvent(EVENT_MAD_7, 4000); - break; - case EVENT_MAD_7: - Talk(SAY_MAD_3); - me->CastSpell(me, SPELL_MADRIGOSA_FROST_BLAST, false); - events.ScheduleEvent(EVENT_MAD_8, 3000); - events.ScheduleEvent(EVENT_MAD_8, 5000); - events.ScheduleEvent(EVENT_MAD_8, 6500); - events.ScheduleEvent(EVENT_MAD_8, 7500); - events.ScheduleEvent(EVENT_MAD_8, 8500); - events.ScheduleEvent(EVENT_MAD_8, 9500); - events.ScheduleEvent(EVENT_MAD_9, 11000); - events.ScheduleEvent(EVENT_MAD_8, 12000); - events.ScheduleEvent(EVENT_MAD_8, 14000); - break; - case EVENT_MAD_8: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - me->CastSpell(brutallus, SPELL_MADRIGOSA_FROSTBOLT, false); - break; - case EVENT_MAD_9: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_FLAME_RING, true); - brutallus->RemoveAllAuras(); - brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_FEL_FIREBALL, false); - brutallus->AI()->Talk(YELL_INTRO_BREAK_ICE); - } - events.ScheduleEvent(EVENT_MAD_11, 6000); - break; - //case EVENT_MAD_10: - case EVENT_MAD_11: - me->SetDisableGravity(false); - me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); - events.ScheduleEvent(EVENT_MAD_13, 2500); - break; - case EVENT_MAD_13: - Talk(SAY_MAD_4); - me->RemoveAllAuras(); - me->CastSpell(me, SPELL_MADRIGOSA_ENCAPSULATE, false); - events.ScheduleEvent(EVENT_MAD_14, 2000); - break; - case EVENT_MAD_14: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - brutallus->SetDisableGravity(true); - brutallus->GetMotionMaster()->MovePoint(0, brutallus->GetPositionX(), brutallus->GetPositionY() - 30.0f, brutallus->GetPositionZ() + 15.0f, false, true); - } - events.ScheduleEvent(EVENT_MAD_15, 10000); - break; - case EVENT_MAD_15: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - brutallus->RemoveAllAuras(); - brutallus->SetDisableGravity(false); - brutallus->GetMotionMaster()->MoveFall(); - brutallus->AI()->Talk(YELL_INTRO_CHARGE); - } - events.ScheduleEvent(EVENT_MAD_16, 1400); - break; - case EVENT_MAD_16: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - brutallus->CastSpell(me, SPELL_BRUTALLUS_CHARGE, true); - events.ScheduleEvent(EVENT_MAD_17, 1200); - break; - case EVENT_MAD_17: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - brutallus->HandleEmoteCommand(EMOTE_ONESHOT_ATTACK1H); - events.ScheduleEvent(EVENT_MAD_18, 500); - break; - case EVENT_MAD_18: - Talk(SAY_MAD_5); - me->SetDynamicFlag(UNIT_DYNFLAG_DEAD); - me->SetStandState(UNIT_STAND_STATE_DEAD); - events.ScheduleEvent(EVENT_MAD_19, 6000); - break; - case EVENT_MAD_19: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - brutallus->AI()->Talk(YELL_INTRO_KILL_MADRIGOSA); - events.ScheduleEvent(EVENT_MAD_20, 7000); - break; - case EVENT_MAD_20: - me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - me->SetFaction(FACTION_FRIENDLY); - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - brutallus->AI()->Talk(YELL_INTRO_TAUNT); - brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_BREAK_ICE, false); - } - events.ScheduleEvent(EVENT_MAD_21, 4000); - break; - case EVENT_MAD_21: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) - { - brutallus->SetReactState(REACT_AGGRESSIVE); - brutallus->SetHealth(brutallus->GetMaxHealth()); - brutallus->AI()->EnterEvadeMode(); - brutallus->setActive(false); - } - break; - case EVENT_SPAWN_FELMYST: - me->DespawnOrUnsummon(1); - if (Creature* felmyst = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_FELMYST))) - felmyst->AI()->DoAction(ACTION_START_EVENT); - break; + brutallus->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_ATTACK1H); + me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_ATTACK1H); + } + events.ScheduleEvent(EVENT_MAD_6, 10000); + break; + case EVENT_MAD_6: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + { + brutallus->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); + me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); + } + me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); + me->SetDisableGravity(true); + events.ScheduleEvent(EVENT_MAD_7, 4000); + break; + case EVENT_MAD_7: + Talk(SAY_MAD_3); + me->CastSpell(me, SPELL_MADRIGOSA_FROST_BLAST, false); + events.ScheduleEvent(EVENT_MAD_8, 3000); + events.ScheduleEvent(EVENT_MAD_8, 5000); + events.ScheduleEvent(EVENT_MAD_8, 6500); + events.ScheduleEvent(EVENT_MAD_8, 7500); + events.ScheduleEvent(EVENT_MAD_8, 8500); + events.ScheduleEvent(EVENT_MAD_8, 9500); + events.ScheduleEvent(EVENT_MAD_9, 11000); + events.ScheduleEvent(EVENT_MAD_8, 12000); + events.ScheduleEvent(EVENT_MAD_8, 14000); + break; + case EVENT_MAD_8: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + me->CastSpell(brutallus, SPELL_MADRIGOSA_FROSTBOLT, false); + break; + case EVENT_MAD_9: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + { + brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_FLAME_RING, true); + brutallus->RemoveAllAuras(); + brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_FEL_FIREBALL, false); + brutallus->AI()->Talk(YELL_INTRO_BREAK_ICE); + } + events.ScheduleEvent(EVENT_MAD_11, 6000); + break; + //case EVENT_MAD_10: + case EVENT_MAD_11: + me->SetDisableGravity(false); + me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); + events.ScheduleEvent(EVENT_MAD_13, 2500); + break; + case EVENT_MAD_13: + Talk(SAY_MAD_4); + me->RemoveAllAuras(); + me->CastSpell(me, SPELL_MADRIGOSA_ENCAPSULATE, false); + events.ScheduleEvent(EVENT_MAD_14, 2000); + break; + case EVENT_MAD_14: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + { + brutallus->SetDisableGravity(true); + brutallus->GetMotionMaster()->MovePoint(0, brutallus->GetPositionX(), brutallus->GetPositionY() - 30.0f, brutallus->GetPositionZ() + 15.0f, false, true); + } + events.ScheduleEvent(EVENT_MAD_15, 10000); + break; + case EVENT_MAD_15: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + { + brutallus->RemoveAllAuras(); + brutallus->SetDisableGravity(false); + brutallus->GetMotionMaster()->MoveFall(); + brutallus->AI()->Talk(YELL_INTRO_CHARGE); + } + events.ScheduleEvent(EVENT_MAD_16, 1400); + break; + case EVENT_MAD_16: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + brutallus->CastSpell(me, SPELL_BRUTALLUS_CHARGE, true); + events.ScheduleEvent(EVENT_MAD_17, 1200); + break; + case EVENT_MAD_17: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + brutallus->HandleEmoteCommand(EMOTE_ONESHOT_ATTACK1H); + events.ScheduleEvent(EVENT_MAD_18, 500); + break; + case EVENT_MAD_18: + Talk(SAY_MAD_5); + me->SetDynamicFlag(UNIT_DYNFLAG_DEAD); + me->SetStandState(UNIT_STAND_STATE_DEAD); + events.ScheduleEvent(EVENT_MAD_19, 6000); + break; + case EVENT_MAD_19: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + brutallus->AI()->Talk(YELL_INTRO_KILL_MADRIGOSA); + events.ScheduleEvent(EVENT_MAD_20, 7000); + break; + case EVENT_MAD_20: + me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetFaction(FACTION_FRIENDLY); + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + { + brutallus->AI()->Talk(YELL_INTRO_TAUNT); + brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_BREAK_ICE, false); } + events.ScheduleEvent(EVENT_MAD_21, 4000); + break; + case EVENT_MAD_21: + if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + { + brutallus->SetReactState(REACT_AGGRESSIVE); + brutallus->SetHealth(brutallus->GetMaxHealth()); + brutallus->AI()->EnterEvadeMode(); + brutallus->setActive(false); + } + break; + case EVENT_SPAWN_FELMYST: + me->DespawnOrUnsummon(1); + if (Creature* felmyst = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_FELMYST))) + felmyst->AI()->DoAction(ACTION_START_EVENT); + break; } - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); } }; @@ -519,8 +497,8 @@ class AreaTrigger_at_sunwell_madrigosa : public AreaTriggerScript void AddSC_boss_brutallus() { - new boss_brutallus(); - new npc_madrigosa(); + RegisterSunwellPlateauCreatureAI(boss_brutallus); + RegisterSunwellPlateauCreatureAI(npc_madrigosa); RegisterSpellScript(spell_madrigosa_activate_barrier); RegisterSpellScript(spell_madrigosa_deactivate_barrier); RegisterSpellScript(spell_brutallus_burn); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp index 88375cdde7aa01..b3751e4278d3bc 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp @@ -82,290 +82,268 @@ enum Misc EVENT_SPELL_FLAME_SEAR = 9 }; -class boss_sacrolash : public CreatureScript +struct boss_sacrolash : public BossAI { -public: - boss_sacrolash() : CreatureScript("boss_sacrolash") { } + boss_sacrolash(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS) {} - struct boss_sacrolashAI : public BossAI + bool sisterDied; + void Reset() override { - boss_sacrolashAI(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS) {} + me->CastSpell(me, SPELL_SHADOWFORM, true); + sisterDied = false; + BossAI::Reset(); + me->SetLootMode(0); + } - bool sisterDied; - void Reset() override + void DoAction(int32 param) override + { + if (param == ACTION_SISTER_DIED) { - me->CastSpell(me, SPELL_SHADOWFORM, true); - sisterDied = false; - BossAI::Reset(); - me->SetLootMode(0); + me->ResetLootMode(); + sisterDied = true; + Talk(YELL_SISTER_ALYTHESS_DEAD); + me->CastSpell(me, SPELL_EMPOWER, true); + + uint32 timer = events.GetNextEventTime(EVENT_SPELL_SHADOW_NOVA); + events.CancelEvent(EVENT_SPELL_SHADOW_NOVA); + events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, timer - events.GetTimer()); } + } - void DoAction(int32 param) override + void EnterEvadeMode(EvadeReason why) override + { + BossAI::EnterEvadeMode(why); + if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) { - if (param == ACTION_SISTER_DIED) - { - me->ResetLootMode(); - sisterDied = true; - Talk(YELL_SISTER_ALYTHESS_DEAD); - me->CastSpell(me, SPELL_EMPOWER, true); - - uint32 timer = events.GetNextEventTime(EVENT_SPELL_SHADOW_NOVA); - events.CancelEvent(EVENT_SPELL_SHADOW_NOVA); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, timer - events.GetTimer()); - } + if (!alythess->IsAlive()) + alythess->Respawn(true); + else if (!alythess->IsInEvadeMode()) + alythess->AI()->EnterEvadeMode(why); } + } - void EnterEvadeMode(EvadeReason why) override - { - BossAI::EnterEvadeMode(why); - if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) - { - if (!alythess->IsAlive()) - alythess->Respawn(true); - else if (!alythess->IsInEvadeMode()) - alythess->AI()->EnterEvadeMode(why); - } - } + void JustEngagedWith(Unit* who) override + { + BossAI::JustEngagedWith(who); + if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) + if (alythess->IsAlive() && !alythess->IsInCombat()) + alythess->AI()->AttackStart(who); + + events.ScheduleEvent(EVENT_SPELL_SHADOW_BLADES, 10000); + events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, 36000); + events.ScheduleEvent(EVENT_SPELL_CONFOUNDING_BLOW, 25000); + events.ScheduleEvent(EVENT_SHADOW_IMAGE, 20000); + events.ScheduleEvent(EVENT_SPELL_ENRAGE, 360000); + } - void JustEngagedWith(Unit* who) override - { - BossAI::JustEngagedWith(who); - if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) - if (alythess->IsAlive() && !alythess->IsInCombat()) - alythess->AI()->AttackStart(who); + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer() && urand(0, 1)) + Talk(YELL_SAC_KILL); + } - events.ScheduleEvent(EVENT_SPELL_SHADOW_BLADES, 10000); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, 36000); - events.ScheduleEvent(EVENT_SPELL_CONFOUNDING_BLOW, 25000); - events.ScheduleEvent(EVENT_SHADOW_IMAGE, 20000); - events.ScheduleEvent(EVENT_SPELL_ENRAGE, 360000); - } + void JustDied(Unit* /*killer*/) override + { + events.Reset(); + summons.DespawnAll(); - void KilledUnit(Unit* victim) override + if (sisterDied) { - if (victim->IsPlayer() && urand(0, 1)) - Talk(YELL_SAC_KILL); + Talk(YELL_SAC_DEAD); + instance->SetBossState(DATA_EREDAR_TWINS, DONE); } + else if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) + alythess->AI()->DoAction(ACTION_SISTER_DIED); + } - void JustDied(Unit* /*killer*/) override + void JustSummoned(Creature* summon) override + { + summons.Summon(summon); + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) { - events.Reset(); - summons.DespawnAll(); - - if (sisterDied) - { - Talk(YELL_SAC_DEAD); - instance->SetBossState(DATA_EREDAR_TWINS, DONE); - } - else if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) - alythess->AI()->DoAction(ACTION_SISTER_DIED); + summon->AI()->AttackStart(target); + summon->AddThreat(target, 10000000); } + } + + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; - void JustSummoned(Creature* summon) override + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; + + switch (events.ExecuteEvent()) { - summons.Summon(summon); - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) - { - summon->AI()->AttackStart(target); - summon->AddThreat(target, 10000000); - } + case EVENT_SPELL_ENRAGE: + Talk(YELL_ENRAGE); + me->CastSpell(me, SPELL_ENRAGE, true); + break; + case EVENT_SPELL_CONFOUNDING_BLOW: + me->CastSpell(me->GetVictim(), SPELL_CONFOUNDING_BLOW, false); + events.ScheduleEvent(EVENT_SPELL_CONFOUNDING_BLOW, urand(20000, 25000)); + break; + case EVENT_SPELL_SHADOW_BLADES: + me->CastSpell(me, SPELL_SHADOW_BLADES, false); + events.ScheduleEvent(EVENT_SPELL_SHADOW_BLADES, 10000); + break; + case EVENT_SPELL_SHADOW_NOVA: + { + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + Talk(EMOTE_SHADOW_NOVA, target); + Talk(YELL_SHADOW_NOVA); + me->CastSpell(target, SPELL_SHADOW_NOVA, false); + events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, urand(30000, 35000)); + break; } - - void UpdateAI(uint32 diff) override + case EVENT_SHADOW_IMAGE: + me->SummonCreature(NPC_SHADOW_IMAGE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation(), TEMPSUMMON_TIMED_DESPAWN, 12000); + events.ScheduleEvent(EVENT_SHADOW_IMAGE, 6000); + break; + case EVENT_SPELL_CONFLAGRATION: { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - Talk(YELL_ENRAGE); - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SPELL_CONFOUNDING_BLOW: - me->CastSpell(me->GetVictim(), SPELL_CONFOUNDING_BLOW, false); - events.ScheduleEvent(EVENT_SPELL_CONFOUNDING_BLOW, urand(20000, 25000)); - break; - case EVENT_SPELL_SHADOW_BLADES: - me->CastSpell(me, SPELL_SHADOW_BLADES, false); - events.ScheduleEvent(EVENT_SPELL_SHADOW_BLADES, 10000); - break; - case EVENT_SPELL_SHADOW_NOVA: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - Talk(EMOTE_SHADOW_NOVA, target); - Talk(YELL_SHADOW_NOVA); - me->CastSpell(target, SPELL_SHADOW_NOVA, false); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, urand(30000, 35000)); - break; - } - case EVENT_SHADOW_IMAGE: - me->SummonCreature(NPC_SHADOW_IMAGE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation(), TEMPSUMMON_TIMED_DESPAWN, 12000); - events.ScheduleEvent(EVENT_SHADOW_IMAGE, 6000); - break; - case EVENT_SPELL_CONFLAGRATION: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - me->CastSpell(target, SPELL_CONFLAGRATION, false); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, urand(30000, 35000)); - break; - } - } - - DoMeleeAttackIfReady(); + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + me->CastSpell(target, SPELL_CONFLAGRATION, false); + events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, urand(30000, 35000)); + break; + } } - }; - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); - }; + DoMeleeAttackIfReady(); + } }; -class boss_alythess : public CreatureScript +struct boss_alythess : public BossAI { -public: - boss_alythess() : CreatureScript("boss_alythess") { } + boss_alythess(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS) { } - struct boss_alythessAI : public BossAI + bool sisterDied; + void Reset() override { - boss_alythessAI(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS) { } + me->CastSpell(me, SPELL_FIREFORM, true); + sisterDied = false; + BossAI::Reset(); + me->SetLootMode(0); + } - bool sisterDied; - void Reset() override + void DoAction(int32 param) override + { + if (param == ACTION_SISTER_DIED) { - me->CastSpell(me, SPELL_FIREFORM, true); - sisterDied = false; - BossAI::Reset(); - me->SetLootMode(0); + me->ResetLootMode(); + sisterDied = true; + Talk(YELL_SISTER_SACROLASH_DEAD); + me->CastSpell(me, SPELL_EMPOWER, true); + + uint32 timer = events.GetNextEventTime(EVENT_SPELL_CONFLAGRATION); + events.CancelEvent(EVENT_SPELL_CONFLAGRATION); + events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, timer - events.GetTimer()); } + } - void DoAction(int32 param) override + void EnterEvadeMode(EvadeReason why) override + { + BossAI::EnterEvadeMode(why); + if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) { - if (param == ACTION_SISTER_DIED) - { - me->ResetLootMode(); - sisterDied = true; - Talk(YELL_SISTER_SACROLASH_DEAD); - me->CastSpell(me, SPELL_EMPOWER, true); - - uint32 timer = events.GetNextEventTime(EVENT_SPELL_CONFLAGRATION); - events.CancelEvent(EVENT_SPELL_CONFLAGRATION); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, timer - events.GetTimer()); - } + if (!scorlash->IsAlive()) + scorlash->Respawn(true); + else if (!scorlash->IsInEvadeMode()) + scorlash->AI()->EnterEvadeMode(why); } + } - void EnterEvadeMode(EvadeReason why) override - { - BossAI::EnterEvadeMode(why); - if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) - { - if (!scorlash->IsAlive()) - scorlash->Respawn(true); - else if (!scorlash->IsInEvadeMode()) - scorlash->AI()->EnterEvadeMode(why); - } - } + void JustEngagedWith(Unit* who) override + { + BossAI::JustEngagedWith(who); + if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) + if (scorlash->IsAlive() && !scorlash->IsInCombat()) + scorlash->AI()->AttackStart(who); + + events.ScheduleEvent(EVENT_SPELL_BLAZE, 100); + events.ScheduleEvent(EVENT_SPELL_PYROGENICS, 15000); + events.ScheduleEvent(EVENT_SPELL_FLAME_SEAR, 20000); + events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, 30000); + events.ScheduleEvent(EVENT_SPELL_ENRAGE, 360000); + } - void JustEngagedWith(Unit* who) override - { - BossAI::JustEngagedWith(who); - if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) - if (scorlash->IsAlive() && !scorlash->IsInCombat()) - scorlash->AI()->AttackStart(who); + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer() && urand(0, 1)) + Talk(YELL_SAC_KILL); + } - events.ScheduleEvent(EVENT_SPELL_BLAZE, 100); - events.ScheduleEvent(EVENT_SPELL_PYROGENICS, 15000); - events.ScheduleEvent(EVENT_SPELL_FLAME_SEAR, 20000); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, 30000); - events.ScheduleEvent(EVENT_SPELL_ENRAGE, 360000); - } + void JustDied(Unit* /*killer*/) override + { + events.Reset(); + summons.DespawnAll(); - void KilledUnit(Unit* victim) override + if (sisterDied) { - if (victim->IsPlayer() && urand(0, 1)) - Talk(YELL_SAC_KILL); + Talk(YELL_SAC_DEAD); + instance->SetBossState(DATA_EREDAR_TWINS, DONE); } + else if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) + scorlash->AI()->DoAction(ACTION_SISTER_DIED); + } - void JustDied(Unit* /*killer*/) override - { - events.Reset(); - summons.DespawnAll(); + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; - if (sisterDied) - { - Talk(YELL_SAC_DEAD); - instance->SetBossState(DATA_EREDAR_TWINS, DONE); - } - else if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) - scorlash->AI()->DoAction(ACTION_SISTER_DIED); - } + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - void UpdateAI(uint32 diff) override + switch (events.ExecuteEvent()) { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - Talk(YELL_BERSERK); - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SPELL_PYROGENICS: - me->CastSpell(me, SPELL_PYROGENICS, false); - events.ScheduleEvent(EVENT_SPELL_PYROGENICS, 15000); - break; - case EVENT_SPELL_FLAME_SEAR: - me->CastCustomSpell(SPELL_FLAME_SEAR, SPELLVALUE_MAX_TARGETS, 5, me, TRIGGERED_NONE); - events.ScheduleEvent(EVENT_SPELL_FLAME_SEAR, 15000); - break; - case EVENT_SPELL_BLAZE: - me->CastSpell(me->GetVictim(), SPELL_BLAZE, false); - events.ScheduleEvent(EVENT_SPELL_BLAZE, 3800); - break; - case EVENT_SPELL_SHADOW_NOVA: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - me->CastSpell(target, SPELL_SHADOW_NOVA, false); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, urand(30000, 35000)); - break; - } - case EVENT_SPELL_CONFLAGRATION: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - Talk(EMOTE_CONFLAGRATION, target); - Talk(YELL_CANFLAGRATION); - me->CastSpell(target, SPELL_CONFLAGRATION, false); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, urand(30000, 35000)); - break; - } - } - - DoMeleeAttackIfReady(); + case EVENT_SPELL_ENRAGE: + Talk(YELL_BERSERK); + me->CastSpell(me, SPELL_ENRAGE, true); + break; + case EVENT_SPELL_PYROGENICS: + me->CastSpell(me, SPELL_PYROGENICS, false); + events.ScheduleEvent(EVENT_SPELL_PYROGENICS, 15000); + break; + case EVENT_SPELL_FLAME_SEAR: + me->CastCustomSpell(SPELL_FLAME_SEAR, SPELLVALUE_MAX_TARGETS, 5, me, TRIGGERED_NONE); + events.ScheduleEvent(EVENT_SPELL_FLAME_SEAR, 15000); + break; + case EVENT_SPELL_BLAZE: + me->CastSpell(me->GetVictim(), SPELL_BLAZE, false); + events.ScheduleEvent(EVENT_SPELL_BLAZE, 3800); + break; + case EVENT_SPELL_SHADOW_NOVA: + { + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + me->CastSpell(target, SPELL_SHADOW_NOVA, false); + events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, urand(30000, 35000)); + break; + } + case EVENT_SPELL_CONFLAGRATION: + { + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + Talk(EMOTE_CONFLAGRATION, target); + Talk(YELL_CANFLAGRATION); + me->CastSpell(target, SPELL_CONFLAGRATION, false); + events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, urand(30000, 35000)); + break; + } } - }; - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); - }; + DoMeleeAttackIfReady(); + } }; class spell_eredar_twins_apply_dark_touched : public SpellScript @@ -496,8 +474,8 @@ class AreaTrigger_at_sunwell_eredar_twins : public AreaTriggerScript void AddSC_boss_eredar_twins() { - new boss_sacrolash(); - new boss_alythess(); + RegisterSunwellPlateauCreatureAI(boss_sacrolash); + RegisterSunwellPlateauCreatureAI(boss_alythess); RegisterSpellScript(spell_eredar_twins_apply_dark_touched); RegisterSpellScript(spell_eredar_twins_apply_flame_touched); RegisterSpellScript(spell_eredar_twins_handle_touch); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp index 0187c46b3fd508..ef67623da69222 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp @@ -126,356 +126,323 @@ class CorruptTriggers : public BasicEvent Unit* _caster; }; -class boss_felmyst : public CreatureScript +struct boss_felmyst : public BossAI { -public: - boss_felmyst() : CreatureScript("boss_felmyst") { } + boss_felmyst(Creature* creature) : BossAI(creature, DATA_FELMYST) + { + bool appear = instance->GetBossState(DATA_BRUTALLUS) == DONE; + creature->SetVisible(appear); + creature->SetStandState(UNIT_STAND_STATE_SLEEP); + creature->SetReactState(REACT_PASSIVE); + } + + EventMap events2; - struct boss_felmystAI : public BossAI + void DoAction(int32 param) override { - boss_felmystAI(Creature* creature) : BossAI(creature, DATA_FELMYST) + if (param == ACTION_START_EVENT) { - bool appear = instance->GetBossState(DATA_BRUTALLUS) == DONE; - creature->SetVisible(appear); - creature->SetStandState(UNIT_STAND_STATE_SLEEP); - creature->SetReactState(REACT_PASSIVE); + me->SetVisible(true); + me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + events2.ScheduleEvent(EVENT_INTRO_1, 3000); } + } - EventMap events2; + void Reset() override + { + BossAI::Reset(); + me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetReactState(REACT_PASSIVE); + me->SetDisableGravity(false); + events2.Reset(); + instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_FOG_OF_CORRUPTION_CHARM); + } - void DoAction(int32 param) override - { - if (param == ACTION_START_EVENT) - { - me->SetVisible(true); - me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - events2.ScheduleEvent(EVENT_INTRO_1, 3000); - } - } + void JustEngagedWith(Unit* who) override + { + BossAI::JustEngagedWith(who); + me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + if (events.Empty() && events2.Empty()) + events2.ScheduleEvent(EVENT_INTRO_2, 3000); + } - void Reset() override + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer() && roll_chance_i(50)) + Talk(YELL_KILL); + } + + void JustDied(Unit* killer) override + { + BossAI::JustDied(killer); + Talk(YELL_DEATH); + instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_FOG_OF_CORRUPTION_CHARM); + + // Summon Kalecgos (human form of kalecgos fight) + me->SummonCreature(NPC_KALEC, 1526.28f, 700.10f, 60.0f, 4.33f); + } + + void MovementInform(uint32 type, uint32 point) override + { + if (type != POINT_MOTION_TYPE) + return; + + if (point == POINT_GROUND) { - BossAI::Reset(); - me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - me->SetReactState(REACT_PASSIVE); + me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); me->SetDisableGravity(false); - events2.Reset(); - instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_FOG_OF_CORRUPTION_CHARM); + me->SendMovementFlagUpdate(); + + events.ScheduleEvent(EVENT_RESTORE_COMBAT, 0); + events.ScheduleEvent(EVENT_RESTORE_COMBAT2, 1); + events.ScheduleEvent(EVENT_SPELL_CLEAVE, 7500, 1); + events.ScheduleEvent(EVENT_SPELL_CORROSION, 12000, 1); + events.ScheduleEvent(EVENT_SPELL_GAS_NOVA, 18000, 1); + events.ScheduleEvent(EVENT_SPELL_ENCAPSULATE, 25000, 1); + events.ScheduleEvent(EVENT_FLIGHT, 60000, 1); } - - void JustEngagedWith(Unit* who) override + else if (point == POINT_AIR_BREATH_START1) { - BossAI::JustEngagedWith(who); - me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - if (events.Empty() && events2.Empty()) - events2.ScheduleEvent(EVENT_INTRO_2, 3000); + me->SetTarget(); + me->SetFacingTo(4.71f); + events.ScheduleEvent(EVENT_FLIGHT_EMOTE, 2000); + events.ScheduleEvent(EVENT_CORRUPT_TRIGGERS, 5000); + events.ScheduleEvent(EVENT_FLIGHT_FLYOVER1, 5000); } - - void KilledUnit(Unit* victim) override + else if (point == POINT_AIR_BREATH_END1) { - if (victim->IsPlayer() && roll_chance_i(50)) - Talk(YELL_KILL); + me->RemoveAurasDueToSpell(SPELL_FELMYST_SPEED_BURST); + me->SetFacingTo(1.57f); + if (events.GetNextEventTime(EVENT_FLIGHT_BREATH1) != 0) + events.ScheduleEvent(EVENT_FLIGHT_BREATH2, 2000); } - - void JustDied(Unit* killer) override + else if (point == POINT_AIR_BREATH_START2) { - BossAI::JustDied(killer); - Talk(YELL_DEATH); - instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_FOG_OF_CORRUPTION_CHARM); - - // Summon Kalecgos (human form of kalecgos fight) - me->SummonCreature(NPC_KALEC, 1526.28f, 700.10f, 60.0f, 4.33f); + me->SetTarget(); + me->SetFacingTo(1.57f); + events.ScheduleEvent(EVENT_FLIGHT_EMOTE, 2000); + events.ScheduleEvent(EVENT_CORRUPT_TRIGGERS, 5000); + events.ScheduleEvent(EVENT_FLIGHT_FLYOVER2, 5000); } - - void MovementInform(uint32 type, uint32 point) override + else if (point == POINT_AIR_BREATH_END2) { - if (type != POINT_MOTION_TYPE) - return; - - if (point == POINT_GROUND) - { - me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); - me->SetDisableGravity(false); - me->SendMovementFlagUpdate(); - - events.ScheduleEvent(EVENT_RESTORE_COMBAT, 0); - events.ScheduleEvent(EVENT_RESTORE_COMBAT2, 1); - events.ScheduleEvent(EVENT_SPELL_CLEAVE, 7500, 1); - events.ScheduleEvent(EVENT_SPELL_CORROSION, 12000, 1); - events.ScheduleEvent(EVENT_SPELL_GAS_NOVA, 18000, 1); - events.ScheduleEvent(EVENT_SPELL_ENCAPSULATE, 25000, 1); - events.ScheduleEvent(EVENT_FLIGHT, 60000, 1); - } - else if (point == POINT_AIR_BREATH_START1) - { - me->SetTarget(); - me->SetFacingTo(4.71f); - events.ScheduleEvent(EVENT_FLIGHT_EMOTE, 2000); - events.ScheduleEvent(EVENT_CORRUPT_TRIGGERS, 5000); - events.ScheduleEvent(EVENT_FLIGHT_FLYOVER1, 5000); - } - else if (point == POINT_AIR_BREATH_END1) - { - me->RemoveAurasDueToSpell(SPELL_FELMYST_SPEED_BURST); - me->SetFacingTo(1.57f); - if (events.GetNextEventTime(EVENT_FLIGHT_BREATH1) != 0) - events.ScheduleEvent(EVENT_FLIGHT_BREATH2, 2000); - } - else if (point == POINT_AIR_BREATH_START2) - { - me->SetTarget(); - me->SetFacingTo(1.57f); - events.ScheduleEvent(EVENT_FLIGHT_EMOTE, 2000); - events.ScheduleEvent(EVENT_CORRUPT_TRIGGERS, 5000); - events.ScheduleEvent(EVENT_FLIGHT_FLYOVER2, 5000); - } - else if (point == POINT_AIR_BREATH_END2) - { - me->RemoveAurasDueToSpell(SPELL_FELMYST_SPEED_BURST); - me->SetFacingTo(4.71f); - } + me->RemoveAurasDueToSpell(SPELL_FELMYST_SPEED_BURST); + me->SetFacingTo(4.71f); } + } - void JustSummoned(Creature* summon) override - { - summons.Summon(summon); - } + void JustSummoned(Creature* summon) override + { + summons.Summon(summon); + } - void UpdateAI(uint32 diff) override + void UpdateAI(uint32 diff) override + { + events2.Update(diff); + switch (events2.ExecuteEvent()) { - events2.Update(diff); - switch (events2.ExecuteEvent()) - { - case EVENT_INTRO_1: - me->SetStandState(UNIT_STAND_STATE_STAND); - events2.ScheduleEvent(EVENT_INTRO_2, 4000); - break; - case EVENT_INTRO_2: - Talk(YELL_BIRTH); - me->SetDisableGravity(true); - me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); - me->SendMovementFlagUpdate(); - events2.ScheduleEvent(EVENT_INTRO_3, 1500); - break; - case EVENT_INTRO_3: - me->GetMotionMaster()->MovePoint(POINT_AIR, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 10.0f, false, true); - events2.ScheduleEvent(EVENT_INTRO_4, 2000); - break; - case EVENT_INTRO_4: - events.ScheduleEvent(EVENT_LAND, 3000, 1); - events.ScheduleEvent(EVENT_SPELL_BERSERK, 600000); - me->SetInCombatWithZone(); - me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - me->CastSpell(me, SPELL_NOXIOUS_FUMES, true); - me->GetMotionMaster()->MovePoint(POINT_MISC, 1472.18f, 603.38f, 34.0f, false, true); - break; - } - - if (!events2.Empty()) - return; + case EVENT_INTRO_1: + me->SetStandState(UNIT_STAND_STATE_STAND); + events2.ScheduleEvent(EVENT_INTRO_2, 4000); + break; + case EVENT_INTRO_2: + Talk(YELL_BIRTH); + me->SetDisableGravity(true); + me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); + me->SendMovementFlagUpdate(); + events2.ScheduleEvent(EVENT_INTRO_3, 1500); + break; + case EVENT_INTRO_3: + me->GetMotionMaster()->MovePoint(POINT_AIR, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 10.0f, false, true); + events2.ScheduleEvent(EVENT_INTRO_4, 2000); + break; + case EVENT_INTRO_4: + events.ScheduleEvent(EVENT_LAND, 3000, 1); + events.ScheduleEvent(EVENT_SPELL_BERSERK, 600000); + me->SetInCombatWithZone(); + me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->CastSpell(me, SPELL_NOXIOUS_FUMES, true); + me->GetMotionMaster()->MovePoint(POINT_MISC, 1472.18f, 603.38f, 34.0f, false, true); + break; + } - if (!UpdateVictim()) - return; + if (!events2.Empty()) + return; - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + if (!UpdateVictim()) + return; - switch (events.ExecuteEvent()) - { - case EVENT_RESTORE_COMBAT: - me->SetReactState(REACT_AGGRESSIVE); - break; - case EVENT_RESTORE_COMBAT2: - me->SetTarget(me->GetVictim()->GetGUID()); - me->GetMotionMaster()->MoveChase(me->GetVictim()); - break; - case EVENT_LAND: - me->GetMotionMaster()->MovePoint(POINT_GROUND, me->GetPositionX(), me->GetPositionY(), me->GetMapHeight(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ()), false, true); - break; - case EVENT_SPELL_BERSERK: - Talk(YELL_BERSERK); - me->CastSpell(me, SPELL_BERSERK, true); - break; - case EVENT_SPELL_CLEAVE: - me->CastSpell(me->GetVictim(), SPELL_CLEAVE, false); - events.ScheduleEvent(EVENT_SPELL_CLEAVE, 7500, 1); - break; - case EVENT_SPELL_CORROSION: - me->CastSpell(me->GetVictim(), SPELL_CORROSION, false); - events.ScheduleEvent(EVENT_SPELL_CORROSION, 20000, 1); - break; - case EVENT_SPELL_GAS_NOVA: - DoCast(me, SPELL_GAS_NOVA, false); - events.ScheduleEvent(EVENT_SPELL_GAS_NOVA, 20000, 1); - break; - case EVENT_SPELL_ENCAPSULATE: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) - me->CastSpell(target, SPELL_ENCAPSULATE_CHANNEL, false); - events.ScheduleEvent(EVENT_SPELL_ENCAPSULATE, 25000, 1); - break; - case EVENT_FLIGHT: - events.CancelEventGroup(1); - events.ScheduleEvent(EVENT_FLIGHT_SEQ, 1000); - me->SetReactState(REACT_PASSIVE); - me->StopMoving(); - me->GetMotionMaster()->Clear(); - break; - case EVENT_FLIGHT_SEQ: - Talk(YELL_TAKEOFF); - me->SetTarget(); - me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); - me->SetDisableGravity(true); - me->SendMovementFlagUpdate(); - - events.ScheduleEvent(EVENT_FLIGHT_MOVE_UP, 2000); - events.ScheduleEvent(EVENT_FLIGHT_VAPOR, 8000); - events.ScheduleEvent(EVENT_FLIGHT_VAPOR, 21000); - events.ScheduleEvent(EVENT_FLIGHT_BREATH1, 35000); - events.ScheduleEvent(EVENT_FLIGHT_BREATH1, 72000); - events.ScheduleEvent(EVENT_LAND_FIGHT, 86000); - break; - case EVENT_FLIGHT_MOVE_UP: - me->GetMotionMaster()->MovePoint(POINT_AIR, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 15.0f, false, true); - break; - case EVENT_FLIGHT_VAPOR: - me->CastCustomSpell(SPELL_SUMMON_DEMONIC_VAPOR, SPELLVALUE_MAX_TARGETS, 1, me, true); - break; - case EVENT_FLIGHT_BREATH1: - { - Position pos = {1447.0f + urand(0, 2) * 25.0f, 705.0f, 50.0f, 4.71f}; - me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_START1, pos, false, true); - break; - } - case EVENT_FLIGHT_BREATH2: - { - Position pos = {1447.0f + urand(0, 2) * 25.0f, 515.0f, 50.0f, 1.57f}; - me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_START2, pos, false, true); - break; - } - case EVENT_FLIGHT_EMOTE: - Talk(EMOTE_BREATH); - break; - case EVENT_CORRUPT_TRIGGERS: - Talk(YELL_BREATH); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(0)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(500)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(1000)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(1500)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(2000)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(2500)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(3000)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(3500)); - me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(4000)); - break; - case EVENT_FLIGHT_FLYOVER1: - me->CastSpell(me, SPELL_FELMYST_SPEED_BURST, true); - me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END1, me->GetPositionX(), me->GetPositionY() - 200.0f, me->GetPositionZ() + 5.0f, false, true); - break; - case EVENT_FLIGHT_FLYOVER2: - me->CastSpell(me, SPELL_FELMYST_SPEED_BURST, true); - me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END2, me->GetPositionX(), me->GetPositionY() + 200.0f, me->GetPositionZ() + 5.0f, false, true); - break; - case EVENT_LAND_FIGHT: - me->GetMotionMaster()->MovePoint(POINT_GROUND, 1500.0f, 552.8f, 26.52f, false, true); - break; - } + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - if (!me->HasUnitMovementFlag(MOVEMENTFLAG_DISABLE_GRAVITY)) - DoMeleeAttackIfReady(); + switch (events.ExecuteEvent()) + { + case EVENT_RESTORE_COMBAT: + me->SetReactState(REACT_AGGRESSIVE); + break; + case EVENT_RESTORE_COMBAT2: + me->SetTarget(me->GetVictim()->GetGUID()); + me->GetMotionMaster()->MoveChase(me->GetVictim()); + break; + case EVENT_LAND: + me->GetMotionMaster()->MovePoint(POINT_GROUND, me->GetPositionX(), me->GetPositionY(), me->GetMapHeight(me->GetPositionX(), me->GetPositionY(), me->GetPositionZ()), false, true); + break; + case EVENT_SPELL_BERSERK: + Talk(YELL_BERSERK); + me->CastSpell(me, SPELL_BERSERK, true); + break; + case EVENT_SPELL_CLEAVE: + me->CastSpell(me->GetVictim(), SPELL_CLEAVE, false); + events.ScheduleEvent(EVENT_SPELL_CLEAVE, 7500, 1); + break; + case EVENT_SPELL_CORROSION: + me->CastSpell(me->GetVictim(), SPELL_CORROSION, false); + events.ScheduleEvent(EVENT_SPELL_CORROSION, 20000, 1); + break; + case EVENT_SPELL_GAS_NOVA: + DoCast(me, SPELL_GAS_NOVA, false); + events.ScheduleEvent(EVENT_SPELL_GAS_NOVA, 20000, 1); + break; + case EVENT_SPELL_ENCAPSULATE: + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) + me->CastSpell(target, SPELL_ENCAPSULATE_CHANNEL, false); + events.ScheduleEvent(EVENT_SPELL_ENCAPSULATE, 25000, 1); + break; + case EVENT_FLIGHT: + events.CancelEventGroup(1); + events.ScheduleEvent(EVENT_FLIGHT_SEQ, 1000); + me->SetReactState(REACT_PASSIVE); + me->StopMoving(); + me->GetMotionMaster()->Clear(); + break; + case EVENT_FLIGHT_SEQ: + Talk(YELL_TAKEOFF); + me->SetTarget(); + me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); + me->SetDisableGravity(true); + me->SendMovementFlagUpdate(); + + events.ScheduleEvent(EVENT_FLIGHT_MOVE_UP, 2000); + events.ScheduleEvent(EVENT_FLIGHT_VAPOR, 8000); + events.ScheduleEvent(EVENT_FLIGHT_VAPOR, 21000); + events.ScheduleEvent(EVENT_FLIGHT_BREATH1, 35000); + events.ScheduleEvent(EVENT_FLIGHT_BREATH1, 72000); + events.ScheduleEvent(EVENT_LAND_FIGHT, 86000); + break; + case EVENT_FLIGHT_MOVE_UP: + me->GetMotionMaster()->MovePoint(POINT_AIR, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 15.0f, false, true); + break; + case EVENT_FLIGHT_VAPOR: + me->CastCustomSpell(SPELL_SUMMON_DEMONIC_VAPOR, SPELLVALUE_MAX_TARGETS, 1, me, true); + break; + case EVENT_FLIGHT_BREATH1: + { + Position pos = { 1447.0f + urand(0, 2) * 25.0f, 705.0f, 50.0f, 4.71f }; + me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_START1, pos, false, true); + break; + } + case EVENT_FLIGHT_BREATH2: + { + Position pos = { 1447.0f + urand(0, 2) * 25.0f, 515.0f, 50.0f, 1.57f }; + me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_START2, pos, false, true); + break; + } + case EVENT_FLIGHT_EMOTE: + Talk(EMOTE_BREATH); + break; + case EVENT_CORRUPT_TRIGGERS: + Talk(YELL_BREATH); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(0)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(500)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(1000)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(1500)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(2000)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(2500)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(3000)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(3500)); + me->m_Events.AddEvent(new CorruptTriggers(me), me->m_Events.CalculateTime(4000)); + break; + case EVENT_FLIGHT_FLYOVER1: + me->CastSpell(me, SPELL_FELMYST_SPEED_BURST, true); + me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END1, me->GetPositionX(), me->GetPositionY() - 200.0f, me->GetPositionZ() + 5.0f, false, true); + break; + case EVENT_FLIGHT_FLYOVER2: + me->CastSpell(me, SPELL_FELMYST_SPEED_BURST, true); + me->GetMotionMaster()->MovePoint(POINT_AIR_BREATH_END2, me->GetPositionX(), me->GetPositionY() + 200.0f, me->GetPositionZ() + 5.0f, false, true); + break; + case EVENT_LAND_FIGHT: + me->GetMotionMaster()->MovePoint(POINT_GROUND, 1500.0f, 552.8f, 26.52f, false, true); + break; } - }; - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); + if (!me->HasUnitMovementFlag(MOVEMENTFLAG_DISABLE_GRAVITY)) + DoMeleeAttackIfReady(); } }; -class npc_demonic_vapor : public CreatureScript +struct npc_demonic_vapor : public NullCreatureAI { -public: - npc_demonic_vapor() : CreatureScript("npc_demonic_vapor") { } + npc_demonic_vapor(Creature* creature) : NullCreatureAI(creature) { } - CreatureAI* GetAI(Creature* creature) const override + void Reset() override { - return GetSunwellPlateauAI(creature); + me->CastSpell(me, SPELL_DEMONIC_VAPOR_SPAWN_TRIGGER, true); + me->CastSpell(me, SPELL_DEMONIC_VAPOR_PERIODIC, true); } - struct npc_demonic_vaporAI : public NullCreatureAI + void UpdateAI(uint32 /*diff*/) override { - npc_demonic_vaporAI(Creature* creature) : NullCreatureAI(creature) { } - - void Reset() override - { - me->CastSpell(me, SPELL_DEMONIC_VAPOR_SPAWN_TRIGGER, true); - me->CastSpell(me, SPELL_DEMONIC_VAPOR_PERIODIC, true); - } - - void UpdateAI(uint32 /*diff*/) override + if (me->GetMotionMaster()->GetMotionSlotType(MOTION_SLOT_CONTROLLED) == NULL_MOTION_TYPE) { - if (me->GetMotionMaster()->GetMotionSlotType(MOTION_SLOT_CONTROLLED) == NULL_MOTION_TYPE) - { - Map::PlayerList const& players = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) - if (me->GetDistance2d(itr->GetSource()) < 20.0f && itr->GetSource()->IsAlive()) - { - me->GetMotionMaster()->MoveFollow(itr->GetSource(), 0.0f, 0.0f, MOTION_SLOT_CONTROLLED); - break; - } - } + Map::PlayerList const& players = me->GetMap()->GetPlayers(); + for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) + if (me->GetDistance2d(itr->GetSource()) < 20.0f && itr->GetSource()->IsAlive()) + { + me->GetMotionMaster()->MoveFollow(itr->GetSource(), 0.0f, 0.0f, MOTION_SLOT_CONTROLLED); + break; + } } - }; + } }; -class npc_demonic_vapor_trail : public CreatureScript +struct npc_demonic_vapor_trail : public NullCreatureAI { -public: - npc_demonic_vapor_trail() : CreatureScript("npc_demonic_vapor_trail") { } - - CreatureAI* GetAI(Creature* creature) const override + npc_demonic_vapor_trail(Creature* creature) : NullCreatureAI(creature) { - return GetSunwellPlateauAI(creature); + timer = 1; } - struct npc_demonic_vapor_trailAI : public NullCreatureAI + uint32 timer; + void Reset() override { - npc_demonic_vapor_trailAI(Creature* creature) : NullCreatureAI(creature) - { - timer = 1; - } - - uint32 timer; - void Reset() override - { - me->CastSpell(me, SPELL_DEMONIC_VAPOR_TRAIL_PERIODIC, true); - } + me->CastSpell(me, SPELL_DEMONIC_VAPOR_TRAIL_PERIODIC, true); + } - void SpellHitTarget(Unit*, SpellInfo const* spellInfo) override - { - if (spellInfo->Id == SPELL_DEMONIC_VAPOR) - me->CastSpell(me, SPELL_SUMMON_BLAZING_DEAD, true); - } + void SpellHitTarget(Unit*, SpellInfo const* spellInfo) override + { + if (spellInfo->Id == SPELL_DEMONIC_VAPOR) + me->CastSpell(me, SPELL_SUMMON_BLAZING_DEAD, true); + } - void UpdateAI(uint32 diff) override + void UpdateAI(uint32 diff) override + { + if (timer) { - if (timer) + timer += diff; + if (timer >= 6000) { - timer += diff; - if (timer >= 6000) - { - timer = 0; - me->CastSpell(me, SPELL_SUMMON_BLAZING_DEAD, true); - } + timer = 0; + me->CastSpell(me, SPELL_SUMMON_BLAZING_DEAD, true); } } + } - void JustSummoned(Creature* summon) override - { - summon->SetInCombatWithZone(); - summon->AI()->AttackStart(summon->AI()->SelectTarget(SelectTargetMethod::Random, 0, 100.0f)); - } - }; + void JustSummoned(Creature* summon) override + { + summon->SetInCombatWithZone(); + summon->AI()->AttackStart(summon->AI()->SelectTarget(SelectTargetMethod::Random, 0, 100.0f)); + } }; class spell_felmyst_fog_of_corruption : public SpellScript @@ -558,9 +525,9 @@ class spell_felmyst_open_brutallus_back_doors : public SpellScript void AddSC_boss_felmyst() { - new boss_felmyst(); - new npc_demonic_vapor(); - new npc_demonic_vapor_trail(); + RegisterSunwellPlateauCreatureAI(boss_felmyst); + RegisterSunwellPlateauCreatureAI(npc_demonic_vapor); + RegisterSunwellPlateauCreatureAI(npc_demonic_vapor_trail); RegisterSpellScript(spell_felmyst_fog_of_corruption); RegisterSpellScript(spell_felmyst_fog_of_corruption_charm_aura); RegisterSpellScript(spell_felmyst_open_brutallus_back_doors); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp index ea6b27523154ab..92f91e14b5a784 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp @@ -114,250 +114,239 @@ enum kalEvents #define DRAGON_REALM_Z 53.079f -class boss_kalecgos : public CreatureScript +struct boss_kalecgos : public BossAI { -public: - boss_kalecgos() : CreatureScript("boss_kalecgos") { } + boss_kalecgos(Creature* creature) : BossAI(creature, DATA_KALECGOS) + { + } - struct boss_kalecgosAI : public BossAI + bool sathBanished; + EventMap events2; + + bool CanAIAttack(Unit const* target) const override { - boss_kalecgosAI(Creature* creature) : BossAI(creature, DATA_KALECGOS) - { - } + return target->GetPositionZ() > 50.0f; + } - bool sathBanished; - EventMap events2; + void JustReachedHome() override + { + BossAI::JustReachedHome(); + me->SetVisible(true); + } - bool CanAIAttack(Unit const* target) const override - { - return target->GetPositionZ() > 50.0f; - } + void Reset() override + { + BossAI::Reset(); + me->SetHealth(me->GetMaxHealth()); + me->SetStandState(UNIT_STAND_STATE_SLEEP); + me->SetDisableGravity(false); + me->SetReactState(REACT_AGGRESSIVE); + me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE); + events2.Reset(); + + sathBanished = false; + ClearPlayerAuras(); + } + + void ClearPlayerAuras() const + { + instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_CURSE_OF_BOUNDLESS_AGONY); + instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_CURSE_OF_BOUNDLESS_AGONY_PLR); + instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_SPECTRAL_REALM); + } - void JustReachedHome() override + void DoAction(int32 param) override + { + if (param == ACTION_ENRAGE || param == ACTION_ENRAGE_OTHER) { - BossAI::JustReachedHome(); - me->SetVisible(true); + Talk(param == ACTION_ENRAGE ? SAY_KALEC_ENRAGE_SATH : SAY_SATH_ENRAGE_ME); + me->CastSpell(me, SPELL_CRAZED_RAGE, true); + events.CancelEvent(EVENT_CHECK_HEALTH); + return; } - - void Reset() override + else if (param == ACTION_BANISH) { - BossAI::Reset(); - me->SetHealth(me->GetMaxHealth()); - me->SetStandState(UNIT_STAND_STATE_SLEEP); - me->SetDisableGravity(false); - me->SetReactState(REACT_AGGRESSIVE); - me->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE); - events2.Reset(); - - sathBanished = false; - ClearPlayerAuras(); + me->CastSpell(me, SPELL_BANISH, true); + events.Reset(); } - - void ClearPlayerAuras() const + else if (param == ACTION_SATH_BANISH) + sathBanished = true; + else if (param == ACTION_KALEC_DIED) { - instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_CURSE_OF_BOUNDLESS_AGONY); - instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_CURSE_OF_BOUNDLESS_AGONY_PLR); - instance->DoRemoveAurasDueToSpellOnPlayers(SPELL_SPECTRAL_REALM); + events.Reset(); + events2.ScheduleEvent(EVENT_TALK_BAD_1, 0); + ClearPlayerAuras(); + return; } - void DoAction(int32 param) override + if (me->HasAura(SPELL_BANISH) && sathBanished) { - if (param == ACTION_ENRAGE || param == ACTION_ENRAGE_OTHER) - { - Talk(param == ACTION_ENRAGE ? SAY_KALEC_ENRAGE_SATH : SAY_SATH_ENRAGE_ME); - me->CastSpell(me, SPELL_CRAZED_RAGE, true); - events.CancelEvent(EVENT_CHECK_HEALTH); - return; - } - else if (param == ACTION_BANISH) - { - me->CastSpell(me, SPELL_BANISH, true); - events.Reset(); - } - else if (param == ACTION_SATH_BANISH) - sathBanished = true; - else if (param == ACTION_KALEC_DIED) - { - events.Reset(); - events2.ScheduleEvent(EVENT_TALK_BAD_1, 0); - ClearPlayerAuras(); - return; - } - - if (me->HasAura(SPELL_BANISH) && sathBanished) + events.Reset(); + events2.ScheduleEvent(EVENT_TALK_GOOD_1, 1000); + ClearPlayerAuras(); + if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) { - events.Reset(); - events2.ScheduleEvent(EVENT_TALK_GOOD_1, 1000); - ClearPlayerAuras(); - if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) - { - Sath->RemoveAllAuras(); - Sath->GetMotionMaster()->MovementExpired(); - Sath->SetReactState(REACT_PASSIVE); - Sath->NearTeleportTo(1696.20f, 915.0f, DRAGON_REALM_Z, Sath->GetOrientation()); - } + Sath->RemoveAllAuras(); + Sath->GetMotionMaster()->MovementExpired(); + Sath->SetReactState(REACT_PASSIVE); + Sath->NearTeleportTo(1696.20f, 915.0f, DRAGON_REALM_Z, Sath->GetOrientation()); } } + } - void JustDied(Unit* killer) override - { - BossAI::JustDied(killer); - } - - void JustEngagedWith(Unit* who) override - { - BossAI::JustEngagedWith(who); - events.ScheduleEvent(EVENT_ARCANE_BUFFET, 6000); - events.ScheduleEvent(EVENT_FROST_BREATH, 15000); - events.ScheduleEvent(EVENT_WILD_MAGIC, 10000); - events.ScheduleEvent(EVENT_TAIL_LASH, 25000); - events.ScheduleEvent(EVENT_SPECTRAL_BLAST, 20000); - events.ScheduleEvent(EVENT_CHECK_POS, 5000); - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); - events.ScheduleEvent(EVENT_SPAWN_SPECTRALS, 16000); + void JustDied(Unit* killer) override + { + BossAI::JustDied(killer); + } - me->SetStandState(UNIT_STAND_STATE_STAND); - Talk(SAY_EVIL_AGGRO); - } + void JustEngagedWith(Unit* who) override + { + BossAI::JustEngagedWith(who); + events.ScheduleEvent(EVENT_ARCANE_BUFFET, 6000); + events.ScheduleEvent(EVENT_FROST_BREATH, 15000); + events.ScheduleEvent(EVENT_WILD_MAGIC, 10000); + events.ScheduleEvent(EVENT_TAIL_LASH, 25000); + events.ScheduleEvent(EVENT_SPECTRAL_BLAST, 20000); + events.ScheduleEvent(EVENT_CHECK_POS, 5000); + events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); + events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); + events.ScheduleEvent(EVENT_SPAWN_SPECTRALS, 16000); + + me->SetStandState(UNIT_STAND_STATE_STAND); + Talk(SAY_EVIL_AGGRO); + } - void DamageTaken(Unit* attacker, uint32& damage, DamageEffectType, SpellSchoolMask) override - { - if (damage >= me->GetHealth() && attacker != me) - damage = 0; - } + void DamageTaken(Unit* attacker, uint32& damage, DamageEffectType, SpellSchoolMask) override + { + if (damage >= me->GetHealth() && attacker != me) + damage = 0; + } - void KilledUnit(Unit* victim) override - { - if (victim->IsPlayer() && roll_chance_i(50)) - Talk(SAY_EVIL_SLAY); - } + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer() && roll_chance_i(50)) + Talk(SAY_EVIL_SLAY); + } - void UpdateAI(uint32 diff) override + void UpdateAI(uint32 diff) override + { + events2.Update(diff); + switch (events2.ExecuteEvent()) { - events2.Update(diff); - switch (events2.ExecuteEvent()) + case EVENT_TALK_GOOD_1: + me->SetRegeneratingHealth(false); + me->RemoveAllAuras(); + me->SetReactState(REACT_PASSIVE); + me->CombatStop(); + me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->SetFaction(FACTION_FRIENDLY); + events2.ScheduleEvent(EVENT_TALK_GOOD_2, 1000); + break; + case EVENT_TALK_GOOD_2: + if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) { - case EVENT_TALK_GOOD_1: - me->SetRegeneratingHealth(false); - me->RemoveAllAuras(); - me->SetReactState(REACT_PASSIVE); - me->CombatStop(); - me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - me->SetFaction(FACTION_FRIENDLY); - events2.ScheduleEvent(EVENT_TALK_GOOD_2, 1000); - break; - case EVENT_TALK_GOOD_2: - if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) - { - summons.Despawn(Sath); - Unit::Kill(me, Sath); - } - events2.ScheduleEvent(EVENT_TALK_GOOD_3, 8000); - break; - case EVENT_TALK_GOOD_3: - Talk(SAY_GOOD_PLRWIN); - events2.ScheduleEvent(EVENT_TALK_GOOD_4, 10000); - break; - case EVENT_TALK_GOOD_4: - me->SetDisableGravity(true); - me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); - events2.ScheduleEvent(EVENT_TALK_GOOD_5, 10000); - break; - case EVENT_TALK_GOOD_5: - me->SetVisible(false); - me->KillSelf(); - break; - case EVENT_TALK_BAD_1: - me->SetReactState(REACT_PASSIVE); - me->CombatStop(); - me->RemoveAllAuras(); - me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - Talk(SAY_EVIL_ENRAGE); - events2.ScheduleEvent(EVENT_TALK_BAD_2, 3000); - break; - case EVENT_TALK_BAD_2: - me->SetDisableGravity(true); - me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); - events2.ScheduleEvent(EVENT_TALK_BAD_3, 15000); - break; - case EVENT_TALK_BAD_3: - me->SetVisible(false); - EnterEvadeMode(); - break; + summons.Despawn(Sath); + Unit::Kill(me, Sath); } + events2.ScheduleEvent(EVENT_TALK_GOOD_3, 8000); + break; + case EVENT_TALK_GOOD_3: + Talk(SAY_GOOD_PLRWIN); + events2.ScheduleEvent(EVENT_TALK_GOOD_4, 10000); + break; + case EVENT_TALK_GOOD_4: + me->SetDisableGravity(true); + me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); + events2.ScheduleEvent(EVENT_TALK_GOOD_5, 10000); + break; + case EVENT_TALK_GOOD_5: + me->SetVisible(false); + me->KillSelf(); + break; + case EVENT_TALK_BAD_1: + me->SetReactState(REACT_PASSIVE); + me->CombatStop(); + me->RemoveAllAuras(); + me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + Talk(SAY_EVIL_ENRAGE); + events2.ScheduleEvent(EVENT_TALK_BAD_2, 3000); + break; + case EVENT_TALK_BAD_2: + me->SetDisableGravity(true); + me->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF); + events2.ScheduleEvent(EVENT_TALK_BAD_3, 15000); + break; + case EVENT_TALK_BAD_3: + me->SetVisible(false); + EnterEvadeMode(); + break; + } - if (!events2.Empty()) - return; + if (!events2.Empty()) + return; - if (!UpdateVictim()) - return; + if (!UpdateVictim()) + return; - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - switch (events.ExecuteEvent()) + switch (events.ExecuteEvent()) + { + case EVENT_SPAWN_SPECTRALS: + me->SummonCreature(NPC_KALEC, 1702.21f, 931.7f, -74.56f, 5.07f, TEMPSUMMON_MANUAL_DESPAWN); + me->SummonCreature(NPC_SATHROVARR, 1704.62f, 927.78f, -73.9f, 2.0f, TEMPSUMMON_MANUAL_DESPAWN); + break; + case EVENT_ARCANE_BUFFET: + me->CastSpell(me, SPELL_ARCANE_BUFFET, false); + events.ScheduleEvent(EVENT_ARCANE_BUFFET, 8000); + break; + case EVENT_FROST_BREATH: + me->CastSpell(me->GetVictim(), SPELL_FROST_BREATH, false); + events.ScheduleEvent(EVENT_FROST_BREATH, 15000); + break; + case EVENT_TAIL_LASH: + me->CastSpell(me->GetVictim(), SPELL_TAIL_LASH, false); + events.ScheduleEvent(EVENT_TAIL_LASH, 15000); + break; + case EVENT_WILD_MAGIC: + me->CastCustomSpell(RAND(44978, 45001, 45002, 45004, 45006, 45010), SPELLVALUE_MAX_TARGETS, 1, me, false); + events.ScheduleEvent(EVENT_WILD_MAGIC, 20000); + break; + case EVENT_SPECTRAL_BLAST: + me->CastSpell(me, SPELL_SPECTRAL_BLAST, false); + events.ScheduleEvent(EVENT_SPECTRAL_BLAST, urand(15000, 25000)); + break; + case EVENT_CHECK_POS: + if (me->GetDistance(me->GetHomePosition()) > 50.0f) { - case EVENT_SPAWN_SPECTRALS: - me->SummonCreature(NPC_KALEC, 1702.21f, 931.7f, -74.56f, 5.07f, TEMPSUMMON_MANUAL_DESPAWN); - me->SummonCreature(NPC_SATHROVARR, 1704.62f, 927.78f, -73.9f, 2.0f, TEMPSUMMON_MANUAL_DESPAWN); - break; - case EVENT_ARCANE_BUFFET: - me->CastSpell(me, SPELL_ARCANE_BUFFET, false); - events.ScheduleEvent(EVENT_ARCANE_BUFFET, 8000); - break; - case EVENT_FROST_BREATH: - me->CastSpell(me->GetVictim(), SPELL_FROST_BREATH, false); - events.ScheduleEvent(EVENT_FROST_BREATH, 15000); - break; - case EVENT_TAIL_LASH: - me->CastSpell(me->GetVictim(), SPELL_TAIL_LASH, false); - events.ScheduleEvent(EVENT_TAIL_LASH, 15000); - break; - case EVENT_WILD_MAGIC: - me->CastCustomSpell(RAND(44978, 45001, 45002, 45004, 45006, 45010), SPELLVALUE_MAX_TARGETS, 1, me, false); - events.ScheduleEvent(EVENT_WILD_MAGIC, 20000); - break; - case EVENT_SPECTRAL_BLAST: - me->CastSpell(me, SPELL_SPECTRAL_BLAST, false); - events.ScheduleEvent(EVENT_SPECTRAL_BLAST, urand(15000, 25000)); - break; - case EVENT_CHECK_POS: - if (me->GetDistance(me->GetHomePosition()) > 50.0f) - { - EnterEvadeMode(); - return; - } - events.ScheduleEvent(EVENT_CHECK_POS, 5000); - break; - case EVENT_CHECK_HEALTH: - if (me->HealthBelowPct(10)) - { - if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) - Sath->AI()->DoAction(ACTION_ENRAGE_OTHER); - DoAction(ACTION_ENRAGE); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - break; - case EVENT_CHECK_HEALTH2: - if (me->HealthBelowPct(1)) - { - DoAction(ACTION_BANISH); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); - break; + EnterEvadeMode(); + return; } - - DoMeleeAttackIfReady(); + events.ScheduleEvent(EVENT_CHECK_POS, 5000); + break; + case EVENT_CHECK_HEALTH: + if (me->HealthBelowPct(10)) + { + if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) + Sath->AI()->DoAction(ACTION_ENRAGE_OTHER); + DoAction(ACTION_ENRAGE); + break; + } + events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); + break; + case EVENT_CHECK_HEALTH2: + if (me->HealthBelowPct(1)) + { + DoAction(ACTION_BANISH); + break; + } + events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); + break; } - }; - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); + DoMeleeAttackIfReady(); } }; @@ -371,255 +360,233 @@ enum Kalec EVENT_KALEC_SCENE_3 = 103 }; -class boss_kalec : public CreatureScript +struct boss_kalec : public ScriptedAI { -public: - boss_kalec() : CreatureScript("boss_kalec") { } + boss_kalec(Creature* creature) : ScriptedAI(creature) { } - CreatureAI* GetAI(Creature* creature) const override + EventMap events; + EventMap events2; + + void Reset() override { - return GetSunwellPlateauAI(creature); + events.Reset(); + events2.Reset(); + if (me->GetPositionY() < 750.0f) + { + me->SetSpeed(MOVE_RUN, 2.4f); + me->SetDisplayId(MODEL_KALECGOS_DRAGON); + me->SetDisableGravity(true); + me->GetMotionMaster()->MovePoint(0, 1483.30f, 657.99f, 28.0f, false, true); + events2.ScheduleEvent(EVENT_KALEC_SCENE_1, 9000); + events2.ScheduleEvent(EVENT_KALEC_SCENE_2, 16000); + events2.ScheduleEvent(EVENT_KALEC_SCENE_3, 22000); + } + else + me->CastSpell(me, SPELL_SPECTRAL_INVISIBILITY, true); } - struct boss_kalecAI : public ScriptedAI + void DamageTaken(Unit* who, uint32& damage, DamageEffectType, SpellSchoolMask) override { - boss_kalecAI(Creature* creature) : ScriptedAI(creature) { } + if (!who || who->GetEntry() != NPC_SATHROVARR) + damage = 0; + } - EventMap events; - EventMap events2; + void JustEngagedWith(Unit*) override + { + events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); + events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); + events.ScheduleEvent(EVENT_SPELL_REVITALIZE, 5000); + events.ScheduleEvent(EVENT_SPELL_HEROIC_STRIKE, 3000); + Talk(SAY_GOOD_AGGRO); + } - void Reset() override - { - events.Reset(); - events2.Reset(); - if (me->GetPositionY() < 750.0f) - { - me->SetSpeed(MOVE_RUN, 2.4f); - me->SetDisplayId(MODEL_KALECGOS_DRAGON); - me->SetDisableGravity(true); - me->GetMotionMaster()->MovePoint(0, 1483.30f, 657.99f, 28.0f, false, true); - events2.ScheduleEvent(EVENT_KALEC_SCENE_1, 9000); - events2.ScheduleEvent(EVENT_KALEC_SCENE_2, 16000); - events2.ScheduleEvent(EVENT_KALEC_SCENE_3, 22000); - } - else - me->CastSpell(me, SPELL_SPECTRAL_INVISIBILITY, true); - } + void JustDied(Unit*) override + { + if (InstanceScript* instance = me->GetInstanceScript()) + if (Creature* kalecgos = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS))) + kalecgos->AI()->DoAction(ACTION_KALEC_DIED); + } - void DamageTaken(Unit* who, uint32& damage, DamageEffectType, SpellSchoolMask) override + void UpdateAI(uint32 diff) override + { + events2.Update(diff); + switch (events2.ExecuteEvent()) { - if (!who || who->GetEntry() != NPC_SATHROVARR) - damage = 0; + case EVENT_KALEC_SCENE_1: + Talk(SAY_GOOD_MADRIGOSA); + me->GetMotionMaster()->MovePoint(0, 1509.0f, 560.0f, 30.0f, false, true); + break; + case EVENT_KALEC_SCENE_2: + me->CastSpell(me, SPELL_OPEN_BRUTALLUS_BACK_DOOR, true); + me->GetInstanceScript()->SetBossState(DATA_FELMYST_DOORS, NOT_STARTED); + me->GetInstanceScript()->SetBossState(DATA_FELMYST_DOORS, DONE); + break; + case EVENT_KALEC_SCENE_3: + me->GetMotionMaster()->MovePoint(0, 1400.0f, 630.0f, 90.0f, false, true); + me->DespawnOrUnsummon(6000); + break; } - void JustEngagedWith(Unit*) override - { - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); - events.ScheduleEvent(EVENT_SPELL_REVITALIZE, 5000); - events.ScheduleEvent(EVENT_SPELL_HEROIC_STRIKE, 3000); - Talk(SAY_GOOD_AGGRO); - } + if (!UpdateVictim()) + return; - void JustDied(Unit*) override - { - if (InstanceScript* instance = me->GetInstanceScript()) - if (Creature* kalecgos = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS))) - kalecgos->AI()->DoAction(ACTION_KALEC_DIED); - } + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - void UpdateAI(uint32 diff) override + switch (events.ExecuteEvent()) { - events2.Update(diff); - switch (events2.ExecuteEvent()) + case EVENT_CHECK_HEALTH: + if (me->HealthBelowPct(50)) { - case EVENT_KALEC_SCENE_1: - Talk(SAY_GOOD_MADRIGOSA); - me->GetMotionMaster()->MovePoint(0, 1509.0f, 560.0f, 30.0f, false, true); - break; - case EVENT_KALEC_SCENE_2: - me->CastSpell(me, SPELL_OPEN_BRUTALLUS_BACK_DOOR, true); - me->GetInstanceScript()->SetBossState(DATA_FELMYST_DOORS, NOT_STARTED); - me->GetInstanceScript()->SetBossState(DATA_FELMYST_DOORS, DONE); - break; - case EVENT_KALEC_SCENE_3: - me->GetMotionMaster()->MovePoint(0, 1400.0f, 630.0f, 90.0f, false, true); - me->DespawnOrUnsummon(6000); - break; + Talk(SAY_GOOD_NEAR_DEATH); + break; } - - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) + events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); + break; + case EVENT_CHECK_HEALTH2: + if (me->HealthBelowPct(10)) { - case EVENT_CHECK_HEALTH: - if (me->HealthBelowPct(50)) - { - Talk(SAY_GOOD_NEAR_DEATH); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - break; - case EVENT_CHECK_HEALTH2: - if (me->HealthBelowPct(10)) - { - Talk(SAY_GOOD_NEAR_DEATH2); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); - break; - case EVENT_SPELL_REVITALIZE: - me->CastSpell(me, SPELL_REVITALIZE, false); - events.ScheduleEvent(EVENT_SPELL_REVITALIZE, 10000); - break; - case EVENT_SPELL_HEROIC_STRIKE: - me->CastSpell(me->GetVictim(), SPELL_HEROIC_STRIKE, false); - events.ScheduleEvent(EVENT_SPELL_HEROIC_STRIKE, 5000); - break; + Talk(SAY_GOOD_NEAR_DEATH2); + break; } - - DoMeleeAttackIfReady(); + events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); + break; + case EVENT_SPELL_REVITALIZE: + me->CastSpell(me, SPELL_REVITALIZE, false); + events.ScheduleEvent(EVENT_SPELL_REVITALIZE, 10000); + break; + case EVENT_SPELL_HEROIC_STRIKE: + me->CastSpell(me->GetVictim(), SPELL_HEROIC_STRIKE, false); + events.ScheduleEvent(EVENT_SPELL_HEROIC_STRIKE, 5000); + break; } - }; + + DoMeleeAttackIfReady(); + } }; -class boss_sathrovarr : public CreatureScript +struct boss_sathrovarr : public ScriptedAI { -public: - boss_sathrovarr() : CreatureScript("boss_sathrovarr") { } + boss_sathrovarr(Creature* creature) : ScriptedAI(creature) + { + instance = creature->GetInstanceScript(); + } + + InstanceScript* instance; + EventMap events; - CreatureAI* GetAI(Creature* creature) const override + bool CanAIAttack(Unit const* target) const override { - return GetSunwellPlateauAI(creature); + return target->GetPositionZ() < 50.0f; } - struct boss_sathrovarrAI : public ScriptedAI + void Reset() override { - boss_sathrovarrAI(Creature* creature) : ScriptedAI(creature) - { - instance = creature->GetInstanceScript(); - } + events.Reset(); + me->CastSpell(me, SPELL_DEMONIC_VISUAL, true); + me->CastSpell(me, SPELL_SPECTRAL_INVISIBILITY, true); + + events.ScheduleEvent(EVENT_SHADOW_BOLT, 7000); + events.ScheduleEvent(EVENT_AGONY_CURSE, 20000); + events.ScheduleEvent(EVENT_CORRUPTION_STRIKE, 13000); + events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); + events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); + } - InstanceScript* instance; - EventMap events; + void JustEngagedWith(Unit* /*who*/) override + { + Talk(SAY_SATH_AGGRO); + } - bool CanAIAttack(Unit const* target) const override - { - return target->GetPositionZ() < 50.0f; - } + void DamageTaken(Unit* who, uint32& damage, DamageEffectType, SpellSchoolMask) override + { + if (damage >= me->GetHealth() && who != me) + damage = 0; + } - void Reset() override - { - events.Reset(); - me->CastSpell(me, SPELL_DEMONIC_VISUAL, true); - me->CastSpell(me, SPELL_SPECTRAL_INVISIBILITY, true); + void KilledUnit(Unit* target) override + { + if (target->IsPlayer()) + Talk(SAY_SATH_SLAY); + } - events.ScheduleEvent(EVENT_SHADOW_BOLT, 7000); - events.ScheduleEvent(EVENT_AGONY_CURSE, 20000); - events.ScheduleEvent(EVENT_CORRUPTION_STRIKE, 13000); - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); - } + void JustDied(Unit* /*killer*/) override + { + Talk(SAY_SATH_DEATH); + } - void JustEngagedWith(Unit* /*who*/) override + void DoAction(int32 param) override + { + if (param == ACTION_ENRAGE || param == ACTION_ENRAGE_OTHER) { - Talk(SAY_SATH_AGGRO); + me->CastSpell(me, SPELL_CRAZED_RAGE, true); + events.CancelEvent(EVENT_CHECK_HEALTH); } - - void DamageTaken(Unit* who, uint32& damage, DamageEffectType, SpellSchoolMask) override + else if (param == ACTION_BANISH) { - if (damage >= me->GetHealth() && who != me) - damage = 0; + me->CastSpell(me, SPELL_BANISH, true); + events.Reset(); } + } - void KilledUnit(Unit* target) override - { - if (target->IsPlayer()) - Talk(SAY_SATH_SLAY); - } + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; - void JustDied(Unit* /*killer*/) override - { - Talk(SAY_SATH_DEATH); - } + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - void DoAction(int32 param) override + switch (events.ExecuteEvent()) { - if (param == ACTION_ENRAGE || param == ACTION_ENRAGE_OTHER) + case EVENT_SHADOW_BOLT: + if (roll_chance_i(20)) + Talk(SAY_SATH_SPELL1); + me->CastSpell(me->GetVictim(), SPELL_SHADOW_BOLT, false); + events.ScheduleEvent(EVENT_SHADOW_BOLT, 9000); + break; + case EVENT_AGONY_CURSE: + me->CastCustomSpell(SPELL_CURSE_OF_BOUNDLESS_AGONY, SPELLVALUE_MAX_TARGETS, 1, me, false); + events.ScheduleEvent(EVENT_AGONY_CURSE, 30000); + break; + case EVENT_CORRUPTION_STRIKE: + if (roll_chance_i(20)) + Talk(SAY_SATH_SPELL2); + me->CastSpell(me->GetVictim(), SPELL_CORRUPTION_STRIKE, false); + events.ScheduleEvent(EVENT_CORRUPTION_STRIKE, 9000); + break; + case EVENT_CHECK_HEALTH: + if (me->HealthBelowPct(10)) { - me->CastSpell(me, SPELL_CRAZED_RAGE, true); - events.CancelEvent(EVENT_CHECK_HEALTH); + if (InstanceScript* instanceScript = me->GetInstanceScript()) + { + if (Creature* kalecgos = ObjectAccessor::GetCreature(*me, instanceScript->GetGuidData( + NPC_KALECGOS))) + { + kalecgos->AI()->DoAction(ACTION_ENRAGE_OTHER); + } + } + DoAction(ACTION_ENRAGE); + break; } - else if (param == ACTION_BANISH) + events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); + break; + case EVENT_CHECK_HEALTH2: + if (me->HealthBelowPct(1)) { - me->CastSpell(me, SPELL_BANISH, true); - events.Reset(); + if (Creature* kalecgos = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS))) + kalecgos->AI()->DoAction(ACTION_SATH_BANISH); + DoAction(ACTION_BANISH); + break; } + events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); + break; } - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SHADOW_BOLT: - if (roll_chance_i(20)) - Talk(SAY_SATH_SPELL1); - me->CastSpell(me->GetVictim(), SPELL_SHADOW_BOLT, false); - events.ScheduleEvent(EVENT_SHADOW_BOLT, 9000); - break; - case EVENT_AGONY_CURSE: - me->CastCustomSpell(SPELL_CURSE_OF_BOUNDLESS_AGONY, SPELLVALUE_MAX_TARGETS, 1, me, false); - events.ScheduleEvent(EVENT_AGONY_CURSE, 30000); - break; - case EVENT_CORRUPTION_STRIKE: - if (roll_chance_i(20)) - Talk(SAY_SATH_SPELL2); - me->CastSpell(me->GetVictim(), SPELL_CORRUPTION_STRIKE, false); - events.ScheduleEvent(EVENT_CORRUPTION_STRIKE, 9000); - break; - case EVENT_CHECK_HEALTH: - if (me->HealthBelowPct(10)) - { - if (InstanceScript* instanceScript = me->GetInstanceScript()) - { - if (Creature *kalecgos = ObjectAccessor::GetCreature(*me, instanceScript->GetGuidData( - NPC_KALECGOS))) - { - kalecgos->AI()->DoAction(ACTION_ENRAGE_OTHER); - } - } - DoAction(ACTION_ENRAGE); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH, 1000); - break; - case EVENT_CHECK_HEALTH2: - if (me->HealthBelowPct(1)) - { - if (Creature* kalecgos = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS))) - kalecgos->AI()->DoAction(ACTION_SATH_BANISH); - DoAction(ACTION_BANISH); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH2, 1000); - break; - } - - DoMeleeAttackIfReady(); - } - }; + DoMeleeAttackIfReady(); + } }; class SpectralBlastCheck @@ -750,9 +717,9 @@ class spell_kalecgos_spectral_realm_aura : public AuraScript void AddSC_boss_kalecgos() { - new boss_kalecgos(); - new boss_sathrovarr(); - new boss_kalec(); + RegisterSunwellPlateauCreatureAI(boss_kalecgos); + RegisterSunwellPlateauCreatureAI(boss_sathrovarr); + RegisterSunwellPlateauCreatureAI(boss_kalec); RegisterSpellScript(spell_kalecgos_spectral_blast_dummy); RegisterSpellScript(spell_kalecgos_curse_of_boundless_agony_aura); RegisterSpellScript(spell_kalecgos_spectral_realm_dummy); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp index ecf69c19fb1542..50d05cddb7f5e2 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp @@ -163,511 +163,489 @@ class CastArmageddon : public BasicEvent Creature* _caster; }; -class npc_kiljaeden_controller : public CreatureScript +struct npc_kiljaeden_controller : public NullCreatureAI { -public: - npc_kiljaeden_controller() : CreatureScript("npc_kiljaeden_controller") { } - - CreatureAI* GetAI(Creature* creature) const override + npc_kiljaeden_controller(Creature* creature) : NullCreatureAI(creature), summons(me) { - return GetSunwellPlateauAI(creature); + instance = creature->GetInstanceScript(); } - struct npc_kiljaeden_controllerAI : public NullCreatureAI - { - npc_kiljaeden_controllerAI(Creature* creature) : NullCreatureAI(creature), summons(me) - { - instance = creature->GetInstanceScript(); - } - - EventMap events; - InstanceScript* instance; - SummonList summons; + EventMap events; + InstanceScript* instance; + SummonList summons; - void ResetOrbs() - { - for (uint8 i = 0; i < 4; ++i) - if (GameObject* orb = ObjectAccessor::GetGameObject(*me, instance->GetGuidData(DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 + i))) - orb->SetGameObjectFlag(GO_FLAG_NOT_SELECTABLE); - } - - void Reset() override - { - instance->SetBossState(DATA_KILJAEDEN, NOT_STARTED); - events.Reset(); - summons.DespawnAll(); - ResetOrbs(); + void ResetOrbs() + { + for (uint8 i = 0; i < 4; ++i) + if (GameObject* orb = ObjectAccessor::GetGameObject(*me, instance->GetGuidData(DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 + i))) + orb->SetGameObjectFlag(GO_FLAG_NOT_SELECTABLE); + } - me->SummonCreature(NPC_HAND_OF_THE_DECEIVER, 1702.62f, 611.19f, 27.66f, 1.81f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 30000); - me->SummonCreature(NPC_HAND_OF_THE_DECEIVER, 1684.099f, 618.848f, 27.67f, 0.589f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 30000); - me->SummonCreature(NPC_HAND_OF_THE_DECEIVER, 1688.38f, 641.10f, 27.50f, 5.43f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 30000); - me->SummonCreature(NPC_ANVEENA, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 40.0f, 0.0f); + void Reset() override + { + instance->SetBossState(DATA_KILJAEDEN, NOT_STARTED); + events.Reset(); + summons.DespawnAll(); + ResetOrbs(); + + me->SummonCreature(NPC_HAND_OF_THE_DECEIVER, 1702.62f, 611.19f, 27.66f, 1.81f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 30000); + me->SummonCreature(NPC_HAND_OF_THE_DECEIVER, 1684.099f, 618.848f, 27.67f, 0.589f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 30000); + me->SummonCreature(NPC_HAND_OF_THE_DECEIVER, 1688.38f, 641.10f, 27.50f, 5.43f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 30000); + me->SummonCreature(NPC_ANVEENA, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 40.0f, 0.0f); + + me->CastSpell(me, SPELL_DESTROY_ALL_DRAKES, true); + me->CastSpell(me, SPELL_ANVEENA_ENERGY_DRAIN, true); + events.ScheduleEvent(EVENT_RANDOM_TALK, 60000); + } - me->CastSpell(me, SPELL_DESTROY_ALL_DRAKES, true); - me->CastSpell(me, SPELL_ANVEENA_ENERGY_DRAIN, true); - events.ScheduleEvent(EVENT_RANDOM_TALK, 60000); - } + void JustDied(Unit*) override + { + EntryCheckPredicate kilCheck(NPC_KILJAEDEN); + EntryCheckPredicate kalCheck(NPC_KALECGOS_KJ); + summons.DespawnIf(kilCheck); + summons.DoAction(ACTION_START_POST_EVENT, kalCheck); + summons.DespawnIf(kalCheck); + + me->CastSpell(me, SPELL_DESTROY_ALL_DRAKES, true); + summons.DespawnAll(); + } - void JustDied(Unit*) override - { - EntryCheckPredicate kilCheck(NPC_KILJAEDEN); - EntryCheckPredicate kalCheck(NPC_KALECGOS_KJ); - summons.DespawnIf(kilCheck); - summons.DoAction(ACTION_START_POST_EVENT, kalCheck); - summons.DespawnIf(kalCheck); - - me->CastSpell(me, SPELL_DESTROY_ALL_DRAKES, true); - summons.DespawnAll(); - } + void JustSummoned(Creature* summon) override + { + summons.Summon(summon); + if (summon->GetEntry() == NPC_SINISTER_REFLECTION) + summon->SetInCombatWithZone(); + else if (summon->GetEntry() == NPC_KALECGOS_KJ) + summon->setActive(true); + } - void JustSummoned(Creature* summon) override - { - summons.Summon(summon); - if (summon->GetEntry() == NPC_SINISTER_REFLECTION) - summon->SetInCombatWithZone(); - else if (summon->GetEntry() == NPC_KALECGOS_KJ) - summon->setActive(true); - } + void SummonedCreatureDies(Creature* summon, Unit*) override + { + summons.Despawn(summon); - void SummonedCreatureDies(Creature* summon, Unit*) override + if (summon->GetEntry() == NPC_HAND_OF_THE_DECEIVER) { - summons.Despawn(summon); + instance->SetBossState(DATA_KILJAEDEN, IN_PROGRESS); + events.ScheduleEvent(EVENT_CHECK_PLAYERS, 1000); - if (summon->GetEntry() == NPC_HAND_OF_THE_DECEIVER) + if (!summons.HasEntry(NPC_HAND_OF_THE_DECEIVER)) { - instance->SetBossState(DATA_KILJAEDEN, IN_PROGRESS); - events.ScheduleEvent(EVENT_CHECK_PLAYERS, 1000); - - if (!summons.HasEntry(NPC_HAND_OF_THE_DECEIVER)) - { - me->RemoveAurasDueToSpell(SPELL_ANVEENA_ENERGY_DRAIN); - me->SummonCreature(NPC_KILJAEDEN, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 1.5f, 4.3f, TEMPSUMMON_MANUAL_DESPAWN); - me->SummonCreature(NPC_KALECGOS_KJ, 1726.80f, 661.43f, 138.65f, 3.95f, TEMPSUMMON_MANUAL_DESPAWN); - } + me->RemoveAurasDueToSpell(SPELL_ANVEENA_ENERGY_DRAIN); + me->SummonCreature(NPC_KILJAEDEN, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + 1.5f, 4.3f, TEMPSUMMON_MANUAL_DESPAWN); + me->SummonCreature(NPC_KALECGOS_KJ, 1726.80f, 661.43f, 138.65f, 3.95f, TEMPSUMMON_MANUAL_DESPAWN); } } + } - void UpdateAI(uint32 diff) override + void UpdateAI(uint32 diff) override + { + events.Update(diff); + switch (events.ExecuteEvent()) { - events.Update(diff); - switch (events.ExecuteEvent()) + case EVENT_RANDOM_TALK: + if (instance->GetBossState(DATA_KILJAEDEN) == NOT_STARTED) + Talk(SAY_KJ_OFFCOMBAT); + events.ScheduleEvent(EVENT_RANDOM_TALK, urand(90000, 180000)); + break; + case EVENT_CHECK_PLAYERS: { - case EVENT_RANDOM_TALK: - if (instance->GetBossState(DATA_KILJAEDEN) == NOT_STARTED) - Talk(SAY_KJ_OFFCOMBAT); - events.ScheduleEvent(EVENT_RANDOM_TALK, urand(90000, 180000)); - break; - case EVENT_CHECK_PLAYERS: - { - Map::PlayerList const& players = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) - if (Player* player = itr->GetSource()) - if (!player->IsGameMaster() && me->GetDistance2d(player) < 60.0f && player->IsAlive()) - { - events.ScheduleEvent(EVENT_CHECK_PLAYERS, 1000); - return; - } - - CreatureAI::EnterEvadeMode(); - break; - } + Map::PlayerList const& players = me->GetMap()->GetPlayers(); + for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) + if (Player* player = itr->GetSource()) + if (!player->IsGameMaster() && me->GetDistance2d(player) < 60.0f && player->IsAlive()) + { + events.ScheduleEvent(EVENT_CHECK_PLAYERS, 1000); + return; + } + + CreatureAI::EnterEvadeMode(); + break; } } - }; + } }; -class boss_kiljaeden : public CreatureScript +struct boss_kiljaeden : public ScriptedAI { -public: - boss_kiljaeden() : CreatureScript("boss_kiljaeden") { } + boss_kiljaeden(Creature* creature) : ScriptedAI(creature) + { + instance = creature->GetInstanceScript(); + me->SetReactState(REACT_PASSIVE); + } + + InstanceScript* instance; + EventMap events; + EventMap events2; + uint8 phase; - struct boss_kiljaedenAI : public ScriptedAI + void InitializeAI() override { - boss_kiljaedenAI(Creature* creature) : ScriptedAI(creature) - { - instance = creature->GetInstanceScript(); - me->SetReactState(REACT_PASSIVE); - } + ScriptedAI::InitializeAI(); + me->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + + phase = PHASE_NORMAL; + events.Reset(); + events2.Reset(); + events2.ScheduleEvent(EVENT_INIT_FIGHT, 11000); + events2.ScheduleEvent(EVENT_REBIRTH, 0); + me->SetVisible(false); + } - InstanceScript* instance; - EventMap events; - EventMap events2; - uint8 phase; + void Reset() override + { + events.Reset(); + } - void InitializeAI() override - { - ScriptedAI::InitializeAI(); - me->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + void EnterEvadeMode(EvadeReason why) override + { + if (me->GetReactState() == REACT_PASSIVE) + return; + ScriptedAI::EnterEvadeMode(why); + } - phase = PHASE_NORMAL; - events.Reset(); - events2.Reset(); - events2.ScheduleEvent(EVENT_INIT_FIGHT, 11000); - events2.ScheduleEvent(EVENT_REBIRTH, 0); - me->SetVisible(false); - } + void AttackStart(Unit* who) override + { + if (me->GetReactState() == REACT_PASSIVE) + return; + ScriptedAI::AttackStart(who); + } - void Reset() override + void DamageTaken(Unit*, uint32& damage, DamageEffectType, SpellSchoolMask) override + { + if (damage >= me->GetHealth()) { + me->SetTarget(); + me->SetReactState(REACT_PASSIVE); + me->RemoveAllAuras(); + me->GetThreatMgr().ClearAllThreat(); + me->SetRegeneratingHealth(false); + me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); + me->HandleEmoteCommand(EMOTE_ONESHOT_DROWN); + me->resetAttackTimer(); events.Reset(); + events2.Reset(); + events2.ScheduleEvent(EVENT_KILL_SELF, 500); + damage = 0; } + } - void EnterEvadeMode(EvadeReason why) override - { - if (me->GetReactState() == REACT_PASSIVE) - return; - ScriptedAI::EnterEvadeMode(why); - } + void JustDied(Unit* /*killer*/) override + { + Talk(SAY_KJ_DEATH); + instance->SetBossState(DATA_KILJAEDEN, DONE); + if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KILJAEDEN_CONTROLLER))) + Unit::Kill(controller, controller); + } - void AttackStart(Unit* who) override + void DoAction(int32 param) override + { + if (param == ACTION_NO_KILL_TALK) { - if (me->GetReactState() == REACT_PASSIVE) - return; - ScriptedAI::AttackStart(who); + events.ScheduleEvent(EVENT_NO_KILL_TALK, 0); + Talk(SAY_KJ_DARKNESS); } + } - void DamageTaken(Unit*, uint32& damage, DamageEffectType, SpellSchoolMask) override - { - if (damage >= me->GetHealth()) - { - me->SetTarget(); - me->SetReactState(REACT_PASSIVE); - me->RemoveAllAuras(); - me->GetThreatMgr().ClearAllThreat(); - me->SetRegeneratingHealth(false); - me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - me->HandleEmoteCommand(EMOTE_ONESHOT_DROWN); - me->resetAttackTimer(); - events.Reset(); - events2.Reset(); - events2.ScheduleEvent(EVENT_KILL_SELF, 500); - damage = 0; - } - } + void KilledUnit(Unit* victim) override + { + if (victim->IsPlayer() && events.GetNextEventTime(EVENT_NO_KILL_TALK) == 0) + Talk(SAY_KJ_SLAY); + } - void JustDied(Unit* /*killer*/) override + void JustEngagedWith(Unit* /*who*/) override + { + events2.ScheduleEvent(EVENT_TEXT_SPEACH11, 26000, EVENT_GROUP_SPEACH); + Talk(SAY_KJ_EMERGE); + + events.SetTimer(200000); + events.ScheduleEvent(EVENT_CHECK_HEALTH85, 1000); + events.ScheduleEvent(EVENT_CHECK_HEALTH55, 1000); + events.ScheduleEvent(EVENT_CHECK_HEALTH25, 1000); + events.ScheduleEvent(EVENT_SPELL_SOUL_FLAY, 0); + events.ScheduleEvent(EVENT_SPELL_LEGION_LIGHTNING, 7000); + events.ScheduleEvent(EVENT_SPELL_FIRE_BLOOM, 9000); + events.ScheduleEvent(EVENT_SUMMON_ORBS, 10000); + } + + void JustSummoned(Creature* summon) override + { + if (summon->GetEntry() == NPC_ARMAGEDDON_TARGET) { - Talk(SAY_KJ_DEATH); - instance->SetBossState(DATA_KILJAEDEN, DONE); - if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KILJAEDEN_CONTROLLER))) - Unit::Kill(controller, controller); + summon->SetCanFly(true); + summon->SetDisableGravity(true); + summon->CastSpell(summon, SPELL_ARMAGEDDON_VISUAL, true); + summon->SetPosition(summon->GetPositionX(), summon->GetPositionY(), summon->GetPositionZ() + 20.0f, 0.0f); + summon->m_Events.AddEvent(new CastArmageddon(summon), summon->m_Events.CalculateTime(6000)); + summon->DespawnOrUnsummon(10000); } + } - void DoAction(int32 param) override + void UpdateAI(uint32 diff) override + { + events2.Update(diff); + switch (events2.ExecuteEvent()) { - if (param == ACTION_NO_KILL_TALK) + case EVENT_KILL_SELF: + me->KillSelf(); + break; + case EVENT_REBIRTH: + me->SetVisible(true); + me->CastSpell(me, SPELL_REBIRTH, false); + break; + case EVENT_EMPOWER_ORBS1: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_READY1); + EmpowerOrb(false); + break; + case EVENT_EMPOWER_ORBS2: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_READY2); + EmpowerOrb(false); + break; + case EVENT_EMPOWER_ORBS3: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_READY_ALL); + EmpowerOrb(true); + break; + case EVENT_INIT_FIGHT: + me->SetReactState(REACT_AGGRESSIVE); + me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + me->SetInCombatWithZone(); + return; + case EVENT_TEXT_SPEACH11: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_JOIN); + break; + case EVENT_TEXT_SPEACH21: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_AWAKEN); + break; + case EVENT_TEXT_SPEACH22: + if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_IMPRISONED, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); + break; + case EVENT_TEXT_SPEACH23: + Talk(SAY_KJ_PHASE3); + break; + case EVENT_TEXT_SPEACH31: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_LETGO); + break; + case EVENT_TEXT_SPEACH32: + if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_LOST, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); + break; + case EVENT_TEXT_SPEACH33: + Talk(SAY_KJ_PHASE4); + break; + case EVENT_TEXT_SPEACH41: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_FOCUS); + break; + case EVENT_TEXT_SPEACH42: + if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_KALEC, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); + break; + case EVENT_TEXT_SPEACH43: + if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + kalec->AI()->Talk(SAY_KALECGOS_FATE); + break; + case EVENT_TEXT_SPEACH44: + if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_GOODBYE, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); + break; + case EVENT_TEXT_SPEACH45: + if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + { + anveena->RemoveAllAuras(); + anveena->DespawnOrUnsummon(3500); + } + break; + case EVENT_TEXT_SPEACH46: + if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) { - events.ScheduleEvent(EVENT_NO_KILL_TALK, 0); - Talk(SAY_KJ_DARKNESS); + anveena->CastSpell(anveena, SPELL_SACRIFICE_OF_ANVEENA, true); + me->CastSpell(me, SPELL_CUSTOM_08_STATE, true); + me->SetUnitFlag(UNIT_FLAG_PACIFIED); + events.DelayEvents(7001); + events2.ScheduleEvent(EVENT_RESTORE_MELEE, 7000); } + Talk(SAY_KJ_PHASE5); + break; + case EVENT_RESTORE_MELEE: + me->RemoveAurasDueToSpell(SPELL_CUSTOM_08_STATE); + me->RemoveUnitFlag(UNIT_FLAG_PACIFIED); + break; } - void KilledUnit(Unit* victim) override - { - if (victim->IsPlayer() && events.GetNextEventTime(EVENT_NO_KILL_TALK) == 0) - Talk(SAY_KJ_SLAY); - } + if (me->GetReactState() != REACT_AGGRESSIVE) + return; - void JustEngagedWith(Unit* /*who*/) override - { - events2.ScheduleEvent(EVENT_TEXT_SPEACH11, 26000, EVENT_GROUP_SPEACH); - Talk(SAY_KJ_EMERGE); - - events.SetTimer(200000); - events.ScheduleEvent(EVENT_CHECK_HEALTH85, 1000); - events.ScheduleEvent(EVENT_CHECK_HEALTH55, 1000); - events.ScheduleEvent(EVENT_CHECK_HEALTH25, 1000); - events.ScheduleEvent(EVENT_SPELL_SOUL_FLAY, 0); - events.ScheduleEvent(EVENT_SPELL_LEGION_LIGHTNING, 7000); - events.ScheduleEvent(EVENT_SPELL_FIRE_BLOOM, 9000); - events.ScheduleEvent(EVENT_SUMMON_ORBS, 10000); - } + if (!UpdateVictim()) + return; + + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - void JustSummoned(Creature* summon) override + switch (events.ExecuteEvent()) { - if (summon->GetEntry() == NPC_ARMAGEDDON_TARGET) + case EVENT_CHECK_HEALTH85: + if (me->HealthBelowPct(85)) { - summon->SetCanFly(true); - summon->SetDisableGravity(true); - summon->CastSpell(summon, SPELL_ARMAGEDDON_VISUAL, true); - summon->SetPosition(summon->GetPositionX(), summon->GetPositionY(), summon->GetPositionZ() + 20.0f, 0.0f); - summon->m_Events.AddEvent(new CastArmageddon(summon), summon->m_Events.CalculateTime(6000)); - summon->DespawnOrUnsummon(10000); + phase = PHASE_DARKNESS; + events2.CancelEvent(EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH21, 16000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH22, 22000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH23, 28000, EVENT_GROUP_SPEACH); + events2.RescheduleEvent(EVENT_EMPOWER_ORBS1, 35000); + + events.DelayEvents(2000); + events.ScheduleEvent(EVENT_SPELL_SINISTER_REFLECTION, 500); + events.ScheduleEvent(EVENT_SPELL_SHADOW_SPIKE, 1200); + events.ScheduleEvent(EVENT_SPELL_FLAME_DART, 3000); + events.RescheduleEvent(EVENT_SPELL_DARKNESS, 16000); // will be delayed by 29 secs + break; } - } + events.ScheduleEvent(EVENT_CHECK_HEALTH85, 0); + break; - void UpdateAI(uint32 diff) override - { - events2.Update(diff); - switch (events2.ExecuteEvent()) + case EVENT_CHECK_HEALTH55: + if (me->HealthBelowPct(55)) { - case EVENT_KILL_SELF: - me->KillSelf(); - break; - case EVENT_REBIRTH: - me->SetVisible(true); - me->CastSpell(me, SPELL_REBIRTH, false); - break; - case EVENT_EMPOWER_ORBS1: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_READY1); - EmpowerOrb(false); - break; - case EVENT_EMPOWER_ORBS2: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_READY2); - EmpowerOrb(false); - break; - case EVENT_EMPOWER_ORBS3: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_READY_ALL); - EmpowerOrb(true); - break; - case EVENT_INIT_FIGHT: - me->SetReactState(REACT_AGGRESSIVE); - me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - me->SetInCombatWithZone(); - return; - case EVENT_TEXT_SPEACH11: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_JOIN); - break; - case EVENT_TEXT_SPEACH21: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_AWAKEN); - break; - case EVENT_TEXT_SPEACH22: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) - sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_IMPRISONED, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); - break; - case EVENT_TEXT_SPEACH23: - Talk(SAY_KJ_PHASE3); - break; - case EVENT_TEXT_SPEACH31: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_LETGO); - break; - case EVENT_TEXT_SPEACH32: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) - sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_LOST, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); - break; - case EVENT_TEXT_SPEACH33: - Talk(SAY_KJ_PHASE4); - break; - case EVENT_TEXT_SPEACH41: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_FOCUS); - break; - case EVENT_TEXT_SPEACH42: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) - sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_KALEC, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); - break; - case EVENT_TEXT_SPEACH43: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) - kalec->AI()->Talk(SAY_KALECGOS_FATE); - break; - case EVENT_TEXT_SPEACH44: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) - sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_GOODBYE, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); - break; - case EVENT_TEXT_SPEACH45: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) - { - anveena->RemoveAllAuras(); - anveena->DespawnOrUnsummon(3500); - } - break; - case EVENT_TEXT_SPEACH46: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) - { - anveena->CastSpell(anveena, SPELL_SACRIFICE_OF_ANVEENA, true); - me->CastSpell(me, SPELL_CUSTOM_08_STATE, true); - me->SetUnitFlag(UNIT_FLAG_PACIFIED); - events.DelayEvents(7001); - events2.ScheduleEvent(EVENT_RESTORE_MELEE, 7000); - } - Talk(SAY_KJ_PHASE5); - break; - case EVENT_RESTORE_MELEE: - me->RemoveAurasDueToSpell(SPELL_CUSTOM_08_STATE); - me->RemoveUnitFlag(UNIT_FLAG_PACIFIED); - break; + phase = PHASE_ARMAGEDDON; + events2.CancelEventGroup(EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH31, 16000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH32, 22000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH33, 28000, EVENT_GROUP_SPEACH); + events2.RescheduleEvent(EVENT_EMPOWER_ORBS2, 35000); + + events.DelayEvents(2000); + events.ScheduleEvent(EVENT_SPELL_SINISTER_REFLECTION, 500); + events.ScheduleEvent(EVENT_SPELL_SHADOW_SPIKE, 1200); + events.RescheduleEvent(EVENT_SPELL_DARKNESS, 15000); // will be delayed by 29 secs + events.ScheduleEvent(EVENT_SPELL_ARMAGEDDON, 10000); + break; } + events.ScheduleEvent(EVENT_CHECK_HEALTH55, 0); + break; - if (me->GetReactState() != REACT_AGGRESSIVE) - return; - - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) + case EVENT_CHECK_HEALTH25: + if (me->HealthBelowPct(25)) { - case EVENT_CHECK_HEALTH85: - if (me->HealthBelowPct(85)) - { - phase = PHASE_DARKNESS; - events2.CancelEvent(EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH21, 16000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH22, 22000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH23, 28000, EVENT_GROUP_SPEACH); - events2.RescheduleEvent(EVENT_EMPOWER_ORBS1, 35000); - - events.DelayEvents(2000); - events.ScheduleEvent(EVENT_SPELL_SINISTER_REFLECTION, 500); - events.ScheduleEvent(EVENT_SPELL_SHADOW_SPIKE, 1200); - events.ScheduleEvent(EVENT_SPELL_FLAME_DART, 3000); - events.RescheduleEvent(EVENT_SPELL_DARKNESS, 16000); // will be delayed by 29 secs - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH85, 0); - break; + phase = PHASE_SACRIFICE; + events2.CancelEventGroup(EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH41, 8000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH42, 18000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH43, 20200, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH44, 25000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH45, 28000, EVENT_GROUP_SPEACH); + events2.ScheduleEvent(EVENT_TEXT_SPEACH46, 30000, EVENT_GROUP_SPEACH); + events2.RescheduleEvent(EVENT_EMPOWER_ORBS3, 61000); + + events.CancelEvent(EVENT_SUMMON_ORBS); + events.DelayEvents(4000); + events.ScheduleEvent(EVENT_SPELL_SINISTER_REFLECTION, 500); + events.ScheduleEvent(EVENT_SPELL_SHADOW_SPIKE, 1200); + events.RescheduleEvent(EVENT_SPELL_DARKNESS, 15000); // will be delayed by 29 secs + events.ScheduleEvent(EVENT_SPELL_ARMAGEDDON, 1500); + break; + } + events.ScheduleEvent(EVENT_CHECK_HEALTH25, 0); + break; + case EVENT_SPELL_SOUL_FLAY: + me->CastSpell(me->GetVictim(), SPELL_SOUL_FLAY, false); + events.ScheduleEvent(EVENT_SPELL_SOUL_FLAY, urand(4000, 5000)); + break; + case EVENT_SPELL_LEGION_LIGHTNING: + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 40.0f, true)) + me->CastSpell(target, SPELL_LEGION_LIGHTNING, false); + events.ScheduleEvent(EVENT_SPELL_LEGION_LIGHTNING, phase == PHASE_SACRIFICE ? 15000 : 30000); + events.RescheduleEvent(EVENT_SPELL_SOUL_FLAY, 2000); + break; + case EVENT_SPELL_FIRE_BLOOM: + me->CastCustomSpell(SPELL_FIRE_BLOOM, SPELLVALUE_MAX_TARGETS, 5, me, TRIGGERED_NONE); + me->SetTarget(me->GetVictim()->GetGUID()); + events.ScheduleEvent(EVENT_SPELL_FIRE_BLOOM, phase == PHASE_SACRIFICE ? 20000 : 40000); + events.RescheduleEvent(EVENT_SPELL_SOUL_FLAY, 1500); + break; + case EVENT_SUMMON_ORBS: + for (uint8 i = 1; i < phase; ++i) + { + float x = me->GetPositionX() + 18.0f * cos((i * 2.0f - 1.0f) * M_PI / 3.0f); + float y = me->GetPositionY() + 18.0f * std::sin((i * 2.0f - 1.0f) * M_PI / 3.0f); + if (Creature* orb = me->SummonCreature(NPC_SHIELD_ORB, x, y, 40.0f, 0, TEMPSUMMON_CORPSE_DESPAWN)) + { + Movement::PointsArray movementArray; + movementArray.push_back(G3D::Vector3(x, y, 40.0f)); - case EVENT_CHECK_HEALTH55: - if (me->HealthBelowPct(55)) + // generate movement array + for (uint8 j = 1; j < 20; ++j) { - phase = PHASE_ARMAGEDDON; - events2.CancelEventGroup(EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH31, 16000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH32, 22000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH33, 28000, EVENT_GROUP_SPEACH); - events2.RescheduleEvent(EVENT_EMPOWER_ORBS2, 35000); - - events.DelayEvents(2000); - events.ScheduleEvent(EVENT_SPELL_SINISTER_REFLECTION, 500); - events.ScheduleEvent(EVENT_SPELL_SHADOW_SPIKE, 1200); - events.RescheduleEvent(EVENT_SPELL_DARKNESS, 15000); // will be delayed by 29 secs - events.ScheduleEvent(EVENT_SPELL_ARMAGEDDON, 10000); - break; + x = me->GetPositionX() + 18.0f * cos(((i * 2.0f - 1.0f) * M_PI / 3.0f) + (j / 20.0f * 2 * M_PI)); + y = me->GetPositionY() + 18.0f * std::sin(((i * 2.0f - 1.0f) * M_PI / 3.0f) + (j / 20.0f * 2 * M_PI)); + movementArray.push_back(G3D::Vector3(x, y, 40.0f)); } - events.ScheduleEvent(EVENT_CHECK_HEALTH55, 0); - break; - case EVENT_CHECK_HEALTH25: - if (me->HealthBelowPct(25)) - { - phase = PHASE_SACRIFICE; - events2.CancelEventGroup(EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH41, 8000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH42, 18000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH43, 20200, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH44, 25000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH45, 28000, EVENT_GROUP_SPEACH); - events2.ScheduleEvent(EVENT_TEXT_SPEACH46, 30000, EVENT_GROUP_SPEACH); - events2.RescheduleEvent(EVENT_EMPOWER_ORBS3, 61000); - - events.CancelEvent(EVENT_SUMMON_ORBS); - events.DelayEvents(4000); - events.ScheduleEvent(EVENT_SPELL_SINISTER_REFLECTION, 500); - events.ScheduleEvent(EVENT_SPELL_SHADOW_SPIKE, 1200); - events.RescheduleEvent(EVENT_SPELL_DARKNESS, 15000); // will be delayed by 29 secs - events.ScheduleEvent(EVENT_SPELL_ARMAGEDDON, 1500); - break; - } - events.ScheduleEvent(EVENT_CHECK_HEALTH25, 0); - break; - case EVENT_SPELL_SOUL_FLAY: - me->CastSpell(me->GetVictim(), SPELL_SOUL_FLAY, false); - events.ScheduleEvent(EVENT_SPELL_SOUL_FLAY, urand(4000, 5000)); - break; - case EVENT_SPELL_LEGION_LIGHTNING: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 40.0f, true)) - me->CastSpell(target, SPELL_LEGION_LIGHTNING, false); - events.ScheduleEvent(EVENT_SPELL_LEGION_LIGHTNING, phase == PHASE_SACRIFICE ? 15000 : 30000); - events.RescheduleEvent(EVENT_SPELL_SOUL_FLAY, 2000); - break; - case EVENT_SPELL_FIRE_BLOOM: - me->CastCustomSpell(SPELL_FIRE_BLOOM, SPELLVALUE_MAX_TARGETS, 5, me, TRIGGERED_NONE); - me->SetTarget(me->GetVictim()->GetGUID()); - events.ScheduleEvent(EVENT_SPELL_FIRE_BLOOM, phase == PHASE_SACRIFICE ? 20000 : 40000); - events.RescheduleEvent(EVENT_SPELL_SOUL_FLAY, 1500); - break; - case EVENT_SUMMON_ORBS: - for (uint8 i = 1; i < phase; ++i) - { - float x = me->GetPositionX() + 18.0f * cos((i * 2.0f - 1.0f) * M_PI / 3.0f); - float y = me->GetPositionY() + 18.0f * std::sin((i * 2.0f - 1.0f) * M_PI / 3.0f); - if (Creature* orb = me->SummonCreature(NPC_SHIELD_ORB, x, y, 40.0f, 0, TEMPSUMMON_CORPSE_DESPAWN)) - { - Movement::PointsArray movementArray; - movementArray.push_back(G3D::Vector3(x, y, 40.0f)); - - // generate movement array - for (uint8 j = 1; j < 20; ++j) - { - x = me->GetPositionX() + 18.0f * cos(((i * 2.0f - 1.0f) * M_PI / 3.0f) + (j / 20.0f * 2 * M_PI)); - y = me->GetPositionY() + 18.0f * std::sin(((i * 2.0f - 1.0f) * M_PI / 3.0f) + (j / 20.0f * 2 * M_PI)); - movementArray.push_back(G3D::Vector3(x, y, 40.0f)); - } - - Movement::MoveSplineInit init(orb); - init.MovebyPath(movementArray); - init.SetCyclic(); - init.Launch(); - } - } - events.ScheduleEvent(EVENT_SUMMON_ORBS, 40000); - break; - case EVENT_SPELL_SHADOW_SPIKE: - events.DelayEvents(27000); - me->CastSpell(me, SPELL_SHADOW_SPIKE, false); - break; - case EVENT_SPELL_SINISTER_REFLECTION: - Talk(SAY_KJ_REFLECTION); - me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); - me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); - me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); - me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); - break; - case EVENT_SPELL_FLAME_DART: - me->CastSpell(me, SPELL_FLAME_DART, false); - events.ScheduleEvent(EVENT_SPELL_FLAME_DART, 10000); - break; - case EVENT_SPELL_DARKNESS: - Talk(EMOTE_KJ_DARKNESS); - me->CastSpell(me, SPELL_DARKNESS_OF_A_THOUSAND_SOULS, false); - events.ScheduleEvent(EVENT_SPELL_DARKNESS, phase == PHASE_SACRIFICE ? 20000 : 45000); - events.DelayEvents(8000); - break; - case EVENT_SPELL_ARMAGEDDON: - me->CastSpell(me, SPELL_ARMAGEDDON_PERIODIC, true); - events.ScheduleEvent(EVENT_SPELL_ARMAGEDDON, phase == PHASE_SACRIFICE ? 20000 : 40000); - break; + Movement::MoveSplineInit init(orb); + init.MovebyPath(movementArray); + init.SetCyclic(); + init.Launch(); + } } - - DoMeleeAttackIfReady(); + events.ScheduleEvent(EVENT_SUMMON_ORBS, 40000); + break; + case EVENT_SPELL_SHADOW_SPIKE: + events.DelayEvents(27000); + me->CastSpell(me, SPELL_SHADOW_SPIKE, false); + break; + case EVENT_SPELL_SINISTER_REFLECTION: + Talk(SAY_KJ_REFLECTION); + me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); + me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); + me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); + me->CastCustomSpell(SPELL_SINISTER_REFLECTION, SPELLVALUE_MAX_TARGETS, 1, me, TRIGGERED_NONE); + break; + case EVENT_SPELL_FLAME_DART: + me->CastSpell(me, SPELL_FLAME_DART, false); + events.ScheduleEvent(EVENT_SPELL_FLAME_DART, 10000); + break; + case EVENT_SPELL_DARKNESS: + Talk(EMOTE_KJ_DARKNESS); + me->CastSpell(me, SPELL_DARKNESS_OF_A_THOUSAND_SOULS, false); + events.ScheduleEvent(EVENT_SPELL_DARKNESS, phase == PHASE_SACRIFICE ? 20000 : 45000); + events.DelayEvents(8000); + break; + case EVENT_SPELL_ARMAGEDDON: + me->CastSpell(me, SPELL_ARMAGEDDON_PERIODIC, true); + events.ScheduleEvent(EVENT_SPELL_ARMAGEDDON, phase == PHASE_SACRIFICE ? 20000 : 40000); + break; } - void EmpowerOrb(bool empowerAll) + DoMeleeAttackIfReady(); + } + + void EmpowerOrb(bool empowerAll) + { + for (uint8 i = 0; i < 4; ++i) { - for (uint8 i = 0; i < 4; ++i) + if (GameObject* orb = ObjectAccessor::GetGameObject(*me, instance->GetGuidData(DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 + i))) { - if (GameObject* orb = ObjectAccessor::GetGameObject(*me, instance->GetGuidData(DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 + i))) + if (orb->HasGameObjectFlag(GO_FLAG_NOT_SELECTABLE)) { - if (orb->HasGameObjectFlag(GO_FLAG_NOT_SELECTABLE)) + orb->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE); + if (Creature* trigger = me->SummonTrigger(orb->GetPositionX(), orb->GetPositionY(), orb->GetPositionZ(), 0, 10 * MINUTE * IN_MILLISECONDS)) { - orb->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE); - if (Creature* trigger = me->SummonTrigger(orb->GetPositionX(), orb->GetPositionY(), orb->GetPositionZ(), 0, 10 * MINUTE * IN_MILLISECONDS)) - { - trigger->CastSpell(trigger, SPELL_RING_OF_BLUE_FLAMES, true, nullptr, nullptr, trigger->GetGUID()); - if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KILJAEDEN_CONTROLLER))) - controller->AI()->JustSummoned(trigger); - } - - if (!empowerAll) - break; + trigger->CastSpell(trigger, SPELL_RING_OF_BLUE_FLAMES, true, nullptr, nullptr, trigger->GetGUID()); + if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KILJAEDEN_CONTROLLER))) + controller->AI()->JustSummoned(trigger); } + + if (!empowerAll) + break; } } } - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); } }; @@ -772,262 +750,251 @@ class FixOrientation : public BasicEvent Creature* _owner; }; -class npc_kalecgos_kj : public CreatureScript +struct npc_kalecgos_kj : public NullCreatureAI { -public: - npc_kalecgos_kj() : CreatureScript("npc_kalecgos_kj") { } - - CreatureAI* GetAI(Creature* creature) const override + npc_kalecgos_kj(Creature* creature) : NullCreatureAI(creature), summons(me) { - return GetSunwellPlateauAI(creature); + instance = creature->GetInstanceScript(); } - struct npc_kalecgos_kjAI : public NullCreatureAI - { - npc_kalecgos_kjAI(Creature* creature) : NullCreatureAI(creature), summons(me) - { - instance = creature->GetInstanceScript(); - } + EventMap events; + InstanceScript* instance; + SummonList summons; - EventMap events; - InstanceScript* instance; - SummonList summons; + void Reset() override + { + events.Reset(); + summons.DespawnAll(); + } - void Reset() override + void DoAction(int32 param) override + { + if (param == ACTION_START_POST_EVENT) { - events.Reset(); - summons.DespawnAll(); + me->SetCanFly(false); + me->SetDisableGravity(false); + me->CastSpell(me, SPELL_TELEPORT_AND_TRANSFORM, true); + events.ScheduleEvent(EVENT_SCENE_01, 35000); } + } - void DoAction(int32 param) override + void JustSummoned(Creature* summon) override + { + summons.Summon(summon); + if (summon->GetEntry() == NPC_SHATTERED_SUN_RIFTWAKER) { - if (param == ACTION_START_POST_EVENT) + summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); + Movement::MoveSplineInit init(summon); + if (summons.size() == 1) + { + init.MoveTo(1727.08f, 656.82f, 28.37f, false, true); + init.SetFacing(5.14f); + } + else { - me->SetCanFly(false); - me->SetDisableGravity(false); - me->CastSpell(me, SPELL_TELEPORT_AND_TRANSFORM, true); - events.ScheduleEvent(EVENT_SCENE_01, 35000); + init.MoveTo(1738.84f, 627.32f, 28.26f, false, true); + init.SetFacing(2.0f); } + init.Launch(); } + else if (summon->GetEntry() == NPC_SHATTRATH_PORTAL_DUMMY) + { + if (Creature* riftwaker = summon->FindNearestCreature(NPC_SHATTERED_SUN_RIFTWAKER, 10.0f)) + riftwaker->CastSpell(summon, SPELL_OPEN_PORTAL_FROM_SHATTRATH, false); + summon->SetWalk(true); + summon->GetMotionMaster()->MovePoint(0, summon->GetPositionX(), summon->GetPositionY(), summon->GetPositionZ() + 30.0f, false, true); + } + else if (summon->GetEntry() == NPC_INERT_PORTAL) + summon->CastSpell(summon, SPELL_BOSS_ARCANE_PORTAL_STATE, true); + else if (summon->GetEntry() == NPC_SHATTERED_SUN_SOLDIER) + summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); + else if (summon->GetEntry() == NPC_LADY_LIADRIN) + { + summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); + summon->SetWalk(true); + } + else if (summon->GetEntry() == NPC_PROPHET_VELEN) + { + summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); + summon->SetWalk(true); + summon->GetMotionMaster()->MovePoint(0, 1710.15f, 639.23f, 27.311f, false, true); + } + else if (summon->GetEntry() == NPC_THE_CORE_OF_ENTROPIUS) + summon->GetMotionMaster()->MovePoint(0, summon->GetPositionX(), summon->GetPositionY(), 30.0f); + } - void JustSummoned(Creature* summon) override + void UpdateAI(uint32 diff) override + { + events.Update(diff); + switch (uint32 eventId = events.ExecuteEvent()) { - summons.Summon(summon); - if (summon->GetEntry() == NPC_SHATTERED_SUN_RIFTWAKER) + case EVENT_SCENE_01: + Talk(SAY_KALECGOS_GOODBYE); + events.ScheduleEvent(eventId + 1, 15000); + break; + case EVENT_SCENE_02: + me->SummonCreature(NPC_SHATTERED_SUN_RIFTWAKER, 1688.42f, 641.82f, 27.60f, 0.67f); + me->SummonCreature(NPC_SHATTERED_SUN_RIFTWAKER, 1712.58f, 616.29f, 27.78f, 0.76f); + events.ScheduleEvent(eventId + 1, 6000); + break; + case EVENT_SCENE_03: + me->SummonCreature(NPC_SHATTRATH_PORTAL_DUMMY, 1727.08f + cos(5.14f), 656.82f + std::sin(5.14f), 28.37f + 2.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN, 10000); + me->SummonCreature(NPC_SHATTRATH_PORTAL_DUMMY, 1738.84f + cos(2.0f), 627.32f + std::sin(2.0f), 28.26f + 2.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN, 10000); + events.ScheduleEvent(eventId + 1, 11000); + break; + case EVENT_SCENE_04: + me->SummonCreature(NPC_INERT_PORTAL, 1734.96f, 642.43f, 28.06f, 3.49f); + events.ScheduleEvent(eventId + 1, 4000); + break; + case EVENT_SCENE_05: + if (Creature* first = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f, 640.49f, 28.06f, 3.49f)) { - summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); - Movement::MoveSplineInit init(summon); - if (summons.size() == 1) - { - init.MoveTo(1727.08f, 656.82f, 28.37f, false, true); - init.SetFacing(5.14f); - } - else - { - init.MoveTo(1738.84f, 627.32f, 28.26f, false, true); - init.SetFacing(2.0f); - } - init.Launch(); + first->m_Events.AddEvent(new MoveDelayed(first, 1718.70f, 607.78f, 28.06f, 2.323f), first->m_Events.CalculateTime(5000)); + first->m_Events.AddEvent(new FixOrientation(first), first->m_Events.CalculateTime(12000)); + for (uint8 i = 0; i < 9; ++i) + if (Creature* follower = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f + 5 * cos(i * 2.0f * M_PI / 9), 640.49f + 5 * std::sin(i * 2.0f * M_PI / 9), 28.06f, 3.49f)) + follower->GetMotionMaster()->MoveFollow(first, 3.0f, follower->GetAngle(first)); } - else if (summon->GetEntry() == NPC_SHATTRATH_PORTAL_DUMMY) + events.ScheduleEvent(eventId + 1, 10000); + break; + case EVENT_SCENE_06: + if (Creature* first = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f, 640.49f, 28.06f, 3.49f)) { - if (Creature* riftwaker = summon->FindNearestCreature(NPC_SHATTERED_SUN_RIFTWAKER, 10.0f)) - riftwaker->CastSpell(summon, SPELL_OPEN_PORTAL_FROM_SHATTRATH, false); - summon->SetWalk(true); - summon->GetMotionMaster()->MovePoint(0, summon->GetPositionX(), summon->GetPositionY(), summon->GetPositionZ() + 30.0f, false, true); + first->m_Events.AddEvent(new MoveDelayed(first, 1678.69f, 649.27f, 28.06f, 5.46f), first->m_Events.CalculateTime(5000)); + first->m_Events.AddEvent(new FixOrientation(first), first->m_Events.CalculateTime(14500)); + for (uint8 i = 0; i < 9; ++i) + if (Creature* follower = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f + 5 * cos(i * 2.0f * M_PI / 9), 640.49f + 5 * std::sin(i * 2.0f * M_PI / 9), 28.06f, 3.49f)) + follower->GetMotionMaster()->MoveFollow(first, 3.0f, follower->GetAngle(first)); } - else if (summon->GetEntry() == NPC_INERT_PORTAL) - summon->CastSpell(summon, SPELL_BOSS_ARCANE_PORTAL_STATE, true); - else if (summon->GetEntry() == NPC_SHATTERED_SUN_SOLDIER) - summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); - else if (summon->GetEntry() == NPC_LADY_LIADRIN) + events.ScheduleEvent(eventId + 1, 12000); + break; + case EVENT_SCENE_07: + me->SummonCreature(NPC_LADY_LIADRIN, 1719.87f, 644.265f, 28.06f, 3.83f); + me->SummonCreature(NPC_PROPHET_VELEN, 1717.97f, 646.44f, 28.06f, 3.94f); + events.ScheduleEvent(eventId + 1, 7000); + break; + case EVENT_SCENE_08: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_01); + events.ScheduleEvent(eventId + 1, 25000); + break; + case EVENT_SCENE_09: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_02); + events.ScheduleEvent(eventId + 1, 14500); + break; + case EVENT_SCENE_10: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_03); + events.ScheduleEvent(eventId + 1, 12500); + break; + case EVENT_SCENE_11: + me->SummonCreature(NPC_THE_CORE_OF_ENTROPIUS, 1698.86f, 628.73f, 92.83f, 0.0f); + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->CastSpell(velen, SPELL_CALL_ENTROPIUS, false); + events.ScheduleEvent(eventId + 1, 8000); + break; + case EVENT_SCENE_12: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) { - summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); - summon->SetWalk(true); + velen->InterruptNonMeleeSpells(false); + velen->AI()->Talk(SAY_VELEN_04); } - else if (summon->GetEntry() == NPC_PROPHET_VELEN) + events.ScheduleEvent(eventId + 1, 20000); + break; + case EVENT_SCENE_13: + if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) + liadrin->GetMotionMaster()->MovePoint(0, 1711.28f, 637.29f, 27.29f); + events.ScheduleEvent(eventId + 1, 6000); + break; + case EVENT_SCENE_14: + if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) + liadrin->AI()->Talk(SAY_LIADRIN_01); + events.ScheduleEvent(eventId + 1, 10000); + break; + case EVENT_SCENE_15: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_05); + events.ScheduleEvent(eventId + 1, 14000); + break; + case EVENT_SCENE_16: + if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) + liadrin->AI()->Talk(SAY_LIADRIN_02); + events.ScheduleEvent(eventId + 1, 2000); + break; + case EVENT_SCENE_17: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_06); + events.ScheduleEvent(eventId + 1, 3000); + break; + case EVENT_SCENE_18: + if (Creature* core = summons.GetCreatureWithEntry(NPC_THE_CORE_OF_ENTROPIUS)) { - summon->CastSpell(summon, SPELL_TELEPORT_VISUAL, true); - summon->SetWalk(true); - summon->GetMotionMaster()->MovePoint(0, 1710.15f, 639.23f, 27.311f, false, true); + core->RemoveAllAuras(); + core->CastSpell(core, SPELL_BLAZE_TO_LIGHT, true); } - else if (summon->GetEntry() == NPC_THE_CORE_OF_ENTROPIUS) - summon->GetMotionMaster()->MovePoint(0, summon->GetPositionX(), summon->GetPositionY(), 30.0f); - } - - void UpdateAI(uint32 diff) override - { - events.Update(diff); - switch (uint32 eventId = events.ExecuteEvent()) + events.ScheduleEvent(eventId + 1, 8000); + break; + case EVENT_SCENE_19: + if (Creature* core = summons.GetCreatureWithEntry(NPC_THE_CORE_OF_ENTROPIUS)) { - case EVENT_SCENE_01: - Talk(SAY_KALECGOS_GOODBYE); - events.ScheduleEvent(eventId + 1, 15000); - break; - case EVENT_SCENE_02: - me->SummonCreature(NPC_SHATTERED_SUN_RIFTWAKER, 1688.42f, 641.82f, 27.60f, 0.67f); - me->SummonCreature(NPC_SHATTERED_SUN_RIFTWAKER, 1712.58f, 616.29f, 27.78f, 0.76f); - events.ScheduleEvent(eventId + 1, 6000); - break; - case EVENT_SCENE_03: - me->SummonCreature(NPC_SHATTRATH_PORTAL_DUMMY, 1727.08f + cos(5.14f), 656.82f + std::sin(5.14f), 28.37f + 2.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN, 10000); - me->SummonCreature(NPC_SHATTRATH_PORTAL_DUMMY, 1738.84f + cos(2.0f), 627.32f + std::sin(2.0f), 28.26f + 2.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN, 10000); - events.ScheduleEvent(eventId + 1, 11000); - break; - case EVENT_SCENE_04: - me->SummonCreature(NPC_INERT_PORTAL, 1734.96f, 642.43f, 28.06f, 3.49f); - events.ScheduleEvent(eventId + 1, 4000); - break; - case EVENT_SCENE_05: - if (Creature* first = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f, 640.49f, 28.06f, 3.49f)) - { - first->m_Events.AddEvent(new MoveDelayed(first, 1718.70f, 607.78f, 28.06f, 2.323f), first->m_Events.CalculateTime(5000)); - first->m_Events.AddEvent(new FixOrientation(first), first->m_Events.CalculateTime(12000)); - for (uint8 i = 0; i < 9; ++i) - if (Creature* follower = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f + 5 * cos(i * 2.0f * M_PI / 9), 640.49f + 5 * std::sin(i * 2.0f * M_PI / 9), 28.06f, 3.49f)) - follower->GetMotionMaster()->MoveFollow(first, 3.0f, follower->GetAngle(first)); - } - events.ScheduleEvent(eventId + 1, 10000); - break; - case EVENT_SCENE_06: - if (Creature* first = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f, 640.49f, 28.06f, 3.49f)) - { - first->m_Events.AddEvent(new MoveDelayed(first, 1678.69f, 649.27f, 28.06f, 5.46f), first->m_Events.CalculateTime(5000)); - first->m_Events.AddEvent(new FixOrientation(first), first->m_Events.CalculateTime(14500)); - for (uint8 i = 0; i < 9; ++i) - if (Creature* follower = me->SummonCreature(NPC_SHATTERED_SUN_SOLDIER, 1729.48f + 5 * cos(i * 2.0f * M_PI / 9), 640.49f + 5 * std::sin(i * 2.0f * M_PI / 9), 28.06f, 3.49f)) - follower->GetMotionMaster()->MoveFollow(first, 3.0f, follower->GetAngle(first)); - } - events.ScheduleEvent(eventId + 1, 12000); - break; - case EVENT_SCENE_07: - me->SummonCreature(NPC_LADY_LIADRIN, 1719.87f, 644.265f, 28.06f, 3.83f); - me->SummonCreature(NPC_PROPHET_VELEN, 1717.97f, 646.44f, 28.06f, 3.94f); - events.ScheduleEvent(eventId + 1, 7000); - break; - case EVENT_SCENE_08: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_01); - events.ScheduleEvent(eventId + 1, 25000); - break; - case EVENT_SCENE_09: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_02); - events.ScheduleEvent(eventId + 1, 14500); - break; - case EVENT_SCENE_10: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_03); - events.ScheduleEvent(eventId + 1, 12500); - break; - case EVENT_SCENE_11: - me->SummonCreature(NPC_THE_CORE_OF_ENTROPIUS, 1698.86f, 628.73f, 92.83f, 0.0f); - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->CastSpell(velen, SPELL_CALL_ENTROPIUS, false); - events.ScheduleEvent(eventId + 1, 8000); - break; - case EVENT_SCENE_12: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - { - velen->InterruptNonMeleeSpells(false); - velen->AI()->Talk(SAY_VELEN_04); - } - events.ScheduleEvent(eventId + 1, 20000); - break; - case EVENT_SCENE_13: - if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) - liadrin->GetMotionMaster()->MovePoint(0, 1711.28f, 637.29f, 27.29f); - events.ScheduleEvent(eventId + 1, 6000); - break; - case EVENT_SCENE_14: - if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) - liadrin->AI()->Talk(SAY_LIADRIN_01); - events.ScheduleEvent(eventId + 1, 10000); - break; - case EVENT_SCENE_15: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_05); - events.ScheduleEvent(eventId + 1, 14000); - break; - case EVENT_SCENE_16: - if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) - liadrin->AI()->Talk(SAY_LIADRIN_02); - events.ScheduleEvent(eventId + 1, 2000); - break; - case EVENT_SCENE_17: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_06); - events.ScheduleEvent(eventId + 1, 3000); - break; - case EVENT_SCENE_18: - if (Creature* core = summons.GetCreatureWithEntry(NPC_THE_CORE_OF_ENTROPIUS)) - { - core->RemoveAllAuras(); - core->CastSpell(core, SPELL_BLAZE_TO_LIGHT, true); - } - events.ScheduleEvent(eventId + 1, 8000); - break; - case EVENT_SCENE_19: - if (Creature* core = summons.GetCreatureWithEntry(NPC_THE_CORE_OF_ENTROPIUS)) - { - core->SetObjectScale(0.75f); - core->GetMotionMaster()->MovePoint(0, core->GetPositionX(), core->GetPositionY(), 28.0f); - } - events.ScheduleEvent(eventId + 1, 2000); - break; - case EVENT_SCENE_20: - if (Creature* core = summons.GetCreatureWithEntry(NPC_THE_CORE_OF_ENTROPIUS)) - core->CastSpell(core, SPELL_SUNWELL_IGNITION, true); - events.ScheduleEvent(eventId + 1, 3000); - break; - case EVENT_SCENE_21: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_07); - events.ScheduleEvent(eventId + 1, 15000); - break; - case EVENT_SCENE_22: - if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) - liadrin->AI()->Talk(SAY_LIADRIN_03); - events.ScheduleEvent(eventId + 1, 20000); - break; - case EVENT_SCENE_23: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_08); - if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) - liadrin->SetStandState(UNIT_STAND_STATE_KNEEL); - events.ScheduleEvent(eventId + 1, 8000); - break; - case EVENT_SCENE_24: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) - velen->AI()->Talk(SAY_VELEN_09); - events.ScheduleEvent(eventId + 1, 5000); - break; - case EVENT_SCENE_25: - if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + core->SetObjectScale(0.75f); + core->GetMotionMaster()->MovePoint(0, core->GetPositionX(), core->GetPositionY(), 28.0f); + } + events.ScheduleEvent(eventId + 1, 2000); + break; + case EVENT_SCENE_20: + if (Creature* core = summons.GetCreatureWithEntry(NPC_THE_CORE_OF_ENTROPIUS)) + core->CastSpell(core, SPELL_SUNWELL_IGNITION, true); + events.ScheduleEvent(eventId + 1, 3000); + break; + case EVENT_SCENE_21: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_07); + events.ScheduleEvent(eventId + 1, 15000); + break; + case EVENT_SCENE_22: + if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) + liadrin->AI()->Talk(SAY_LIADRIN_03); + events.ScheduleEvent(eventId + 1, 20000); + break; + case EVENT_SCENE_23: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_08); + if (Creature* liadrin = summons.GetCreatureWithEntry(NPC_LADY_LIADRIN)) + liadrin->SetStandState(UNIT_STAND_STATE_KNEEL); + events.ScheduleEvent(eventId + 1, 8000); + break; + case EVENT_SCENE_24: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + velen->AI()->Talk(SAY_VELEN_09); + events.ScheduleEvent(eventId + 1, 5000); + break; + case EVENT_SCENE_25: + if (Creature* velen = summons.GetCreatureWithEntry(NPC_PROPHET_VELEN)) + { + velen->GetMotionMaster()->MovePoint(0, 1739.38f, 643.79f, 28.06f); + velen->DespawnOrUnsummon(5000); + } + events.ScheduleEvent(eventId + 1, 3000); + break; + case EVENT_SCENE_26: + for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr) + if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr)) + if (summon->GetEntry() == NPC_SHATTERED_SUN_SOLDIER) { - velen->GetMotionMaster()->MovePoint(0, 1739.38f, 643.79f, 28.06f); - velen->DespawnOrUnsummon(5000); + summon->GetMotionMaster()->MovePoint(0, 1739.38f, 643.79f, 28.06f); + summon->DespawnOrUnsummon(summon->GetExactDist2d(1734.96f, 642.43f) * 100); } - events.ScheduleEvent(eventId + 1, 3000); - break; - case EVENT_SCENE_26: - for (SummonList::const_iterator itr = summons.begin(); itr != summons.end(); ++itr) - if (Creature* summon = ObjectAccessor::GetCreature(*me, *itr)) - if (summon->GetEntry() == NPC_SHATTERED_SUN_SOLDIER) - { - summon->GetMotionMaster()->MovePoint(0, 1739.38f, 643.79f, 28.06f); - summon->DespawnOrUnsummon(summon->GetExactDist2d(1734.96f, 642.43f) * 100); - } - events.ScheduleEvent(eventId + 1, 7000); - break; - case EVENT_SCENE_27: - me->setActive(false); - summons.DespawnEntry(NPC_INERT_PORTAL); - summons.DespawnEntry(NPC_SHATTERED_SUN_RIFTWAKER); - break; - } + events.ScheduleEvent(eventId + 1, 7000); + break; + case EVENT_SCENE_27: + me->setActive(false); + summons.DespawnEntry(NPC_INERT_PORTAL); + summons.DespawnEntry(NPC_SHATTERED_SUN_RIFTWAKER); + break; } - }; + } }; class spell_kiljaeden_shadow_spike_aura : public AuraScript @@ -1248,9 +1215,9 @@ class spell_kiljaeden_dragon_breath : public SpellScript void AddSC_boss_kiljaeden() { - new npc_kiljaeden_controller(); - new boss_kiljaeden(); - new npc_kalecgos_kj(); + RegisterSunwellPlateauCreatureAI(npc_kiljaeden_controller); + RegisterSunwellPlateauCreatureAI(boss_kiljaeden); + RegisterSunwellPlateauCreatureAI(npc_kalecgos_kj); RegisterSpellScript(spell_kiljaeden_shadow_spike_aura); RegisterSpellScript(spell_kiljaeden_sinister_reflection); RegisterSpellScript(spell_kiljaeden_sinister_reflection_clone); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp index ade6501fa9e159..a53becd5f067f4 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp @@ -72,260 +72,227 @@ enum Misc DATA_NEGATIVE_ENERGY_TARGETS = 2 }; -class boss_muru : public CreatureScript +struct boss_muru : public BossAI { -public: - boss_muru() : CreatureScript("boss_muru") { } + boss_muru(Creature* creature) : BossAI(creature, DATA_MURU) { } - struct boss_muruAI : public BossAI + void Reset() override { - boss_muruAI(Creature* creature) : BossAI(creature, DATA_MURU) { } - - void Reset() override - { - BossAI::Reset(); - me->SetReactState(REACT_AGGRESSIVE); - me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - me->SetVisible(true); - } + BossAI::Reset(); + me->SetReactState(REACT_AGGRESSIVE); + me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + me->SetVisible(true); + } - void JustEngagedWith(Unit* who) override - { - BossAI::JustEngagedWith(who); - me->CastSpell(me, SPELL_NEGATIVE_ENERGY, true); - me->CastSpell(me, SPELL_SUMMON_BLOOD_ELVES_PERIODIC, true); - me->CastSpell(me, SPELL_OPEN_PORTAL_PERIODIC, true); - me->CastSpell(me, SPELL_DARKNESS_PERIODIC, true); + void JustEngagedWith(Unit* who) override + { + BossAI::JustEngagedWith(who); + me->CastSpell(me, SPELL_NEGATIVE_ENERGY, true); + me->CastSpell(me, SPELL_SUMMON_BLOOD_ELVES_PERIODIC, true); + me->CastSpell(me, SPELL_OPEN_PORTAL_PERIODIC, true); + me->CastSpell(me, SPELL_DARKNESS_PERIODIC, true); - events.ScheduleEvent(EVENT_SPELL_ENRAGE, 600000); - } + events.ScheduleEvent(EVENT_SPELL_ENRAGE, 600000); + } - void DamageTaken(Unit*, uint32& damage, DamageEffectType, SpellSchoolMask) override + void DamageTaken(Unit*, uint32& damage, DamageEffectType, SpellSchoolMask) override + { + if (damage >= me->GetHealth()) { - if (damage >= me->GetHealth()) + damage = 0; + if (!me->HasUnitFlag(UNIT_FLAG_NOT_SELECTABLE)) { - damage = 0; - if (!me->HasUnitFlag(UNIT_FLAG_NOT_SELECTABLE)) - { - me->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - me->RemoveAllAuras(); - me->CastSpell(me, SPELL_OPEN_ALL_PORTALS, true); - events.ScheduleEvent(EVENT_SUMMON_ENTROPIUS, 7000); - } + me->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + me->RemoveAllAuras(); + me->CastSpell(me, SPELL_OPEN_ALL_PORTALS, true); + events.ScheduleEvent(EVENT_SUMMON_ENTROPIUS, 7000); } } + } - void JustSummoned(Creature* summon) override + void JustSummoned(Creature* summon) override + { + if (summon->GetEntry() == NPC_ENTROPIUS) + summon->AI()->SetData(DATA_ENRAGE_TIMER, events.GetNextEventTime(EVENT_SPELL_ENRAGE)); + else { - if (summon->GetEntry() == NPC_ENTROPIUS) - summon->AI()->SetData(DATA_ENRAGE_TIMER, events.GetNextEventTime(EVENT_SPELL_ENRAGE)); - else - { - if (!summon->IsTrigger()) - summon->SetInCombatWithZone(); - summons.Summon(summon); - } + if (!summon->IsTrigger()) + summon->SetInCombatWithZone(); + summons.Summon(summon); } + } - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SUMMON_ENTROPIUS: - me->CastSpell(me, SPELL_SUMMON_ENTROPIUS, false); - events.ScheduleEvent(EVENT_SET_INVISIBLE, 1000); - break; - case EVENT_SET_INVISIBLE: - me->SetVisible(false); - break; - } + switch (events.ExecuteEvent()) + { + case EVENT_SPELL_ENRAGE: + me->CastSpell(me, SPELL_ENRAGE, true); + break; + case EVENT_SUMMON_ENTROPIUS: + me->CastSpell(me, SPELL_SUMMON_ENTROPIUS, false); + events.ScheduleEvent(EVENT_SET_INVISIBLE, 1000); + break; + case EVENT_SET_INVISIBLE: + me->SetVisible(false); + break; } - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); } }; -class boss_entropius : public CreatureScript +struct boss_entropius : public ScriptedAI { -public: - boss_entropius() : CreatureScript("boss_entropius") { } + boss_entropius(Creature* creature) : ScriptedAI(creature) { } - struct boss_entropiusAI : public ScriptedAI - { - boss_entropiusAI(Creature* creature) : ScriptedAI(creature) { } + EventMap events; + EventMap events2; - EventMap events; - EventMap events2; + void Reset() override + { + events.Reset(); + events2.Reset(); + events2.ScheduleEvent(EVENT_ENTROPIUS_AURAS, 0); + events2.ScheduleEvent(EVENT_ENTROPIUS_COMBAT, 3000); + me->SetReactState(REACT_PASSIVE); + } - void Reset() override - { - events.Reset(); - events2.Reset(); - events2.ScheduleEvent(EVENT_ENTROPIUS_AURAS, 0); - events2.ScheduleEvent(EVENT_ENTROPIUS_COMBAT, 3000); - me->SetReactState(REACT_PASSIVE); - } + void EnterEvadeMode(EvadeReason why) override + { + if (InstanceScript* instance = me->GetInstanceScript()) + if (Creature* muru = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MURU))) + if (!muru->IsInEvadeMode()) + muru->AI()->EnterEvadeMode(why); - void EnterEvadeMode(EvadeReason why) override - { - if (InstanceScript* instance = me->GetInstanceScript()) - if (Creature* muru = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MURU))) - if (!muru->IsInEvadeMode()) - muru->AI()->EnterEvadeMode(why); + me->DespawnOrUnsummon(); + } - me->DespawnOrUnsummon(); - } + void JustEngagedWith(Unit* /*who*/) override + { + events.ScheduleEvent(EVENT_SPAWN_BLACK_HOLE, 15000); + events.ScheduleEvent(EVENT_SPAWN_DARKNESS, 10000); + } - void JustEngagedWith(Unit* /*who*/) override - { - events.ScheduleEvent(EVENT_SPAWN_BLACK_HOLE, 15000); - events.ScheduleEvent(EVENT_SPAWN_DARKNESS, 10000); - } + void SetData(uint32 type, uint32 data) override + { + if (type == DATA_ENRAGE_TIMER) + events.ScheduleEvent(EVENT_SPELL_ENRAGE, data); + } - void SetData(uint32 type, uint32 data) override - { - if (type == DATA_ENRAGE_TIMER) - events.ScheduleEvent(EVENT_SPELL_ENRAGE, data); - } + uint32 GetData(uint32 type) const override + { + if (type == DATA_NEGATIVE_ENERGY_TARGETS) + return 1 + uint32(events.GetTimer() / 12000); + return 0; + } - uint32 GetData(uint32 type) const override - { - if (type == DATA_NEGATIVE_ENERGY_TARGETS) - return 1 + uint32(events.GetTimer() / 12000); - return 0; - } + void JustDied(Unit* /*killer*/) override + { + if (InstanceScript* instance = me->GetInstanceScript()) + if (Creature* muru = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MURU))) + Unit::Kill(muru, muru); + } - void JustDied(Unit* /*killer*/) override + void UpdateAI(uint32 diff) override + { + events2.Update(diff); + switch (events2.ExecuteEvent()) { - if (InstanceScript* instance = me->GetInstanceScript()) - if (Creature* muru = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MURU))) - Unit::Kill(muru, muru); + case EVENT_ENTROPIUS_AURAS: + me->CastSpell(me, SPELL_ENTROPIUS_COSMETIC_SPAWN, false); + me->CastSpell(me, SPELL_NEGATIVE_ENERGY_PERIODIC, true); + break; + case EVENT_ENTROPIUS_COMBAT: + me->SetReactState(REACT_AGGRESSIVE); + me->SetInCombatWithZone(); + AttackStart(SelectTargetFromPlayerList(50.0f)); + break; } - void UpdateAI(uint32 diff) override - { - events2.Update(diff); - switch (events2.ExecuteEvent()) - { - case EVENT_ENTROPIUS_AURAS: - me->CastSpell(me, SPELL_ENTROPIUS_COSMETIC_SPAWN, false); - me->CastSpell(me, SPELL_NEGATIVE_ENERGY_PERIODIC, true); - break; - case EVENT_ENTROPIUS_COMBAT: - me->SetReactState(REACT_AGGRESSIVE); - me->SetInCombatWithZone(); - AttackStart(SelectTargetFromPlayerList(50.0f)); - break; - } - - if (!events2.Empty()) - return; - - if (!UpdateVictim()) - return; + if (!events2.Empty()) + return; - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + if (!UpdateVictim()) + return; - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SPAWN_DARKNESS: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) - me->CastSpell(target, SPELL_DARKNESS, true); - events.ScheduleEvent(EVENT_SPAWN_DARKNESS, 15000); - break; - case EVENT_SPAWN_BLACK_HOLE: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) - me->CastSpell(target, SPELL_BLACK_HOLE, true); - events.ScheduleEvent(EVENT_SPAWN_BLACK_HOLE, 15000); - break; - } + events.Update(diff); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; - DoMeleeAttackIfReady(); + switch (events.ExecuteEvent()) + { + case EVENT_SPELL_ENRAGE: + me->CastSpell(me, SPELL_ENRAGE, true); + break; + case EVENT_SPAWN_DARKNESS: + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) + me->CastSpell(target, SPELL_DARKNESS, true); + events.ScheduleEvent(EVENT_SPAWN_DARKNESS, 15000); + break; + case EVENT_SPAWN_BLACK_HOLE: + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) + me->CastSpell(target, SPELL_BLACK_HOLE, true); + events.ScheduleEvent(EVENT_SPAWN_BLACK_HOLE, 15000); + break; } - }; - CreatureAI* GetAI(Creature* creature) const override - { - return GetSunwellPlateauAI(creature); + DoMeleeAttackIfReady(); } }; -class npc_singularity : public CreatureScript +struct npc_singularity : public NullCreatureAI { -public: - npc_singularity() : CreatureScript("npc_singularity") { } - - CreatureAI* GetAI(Creature* creature) const override + npc_singularity(Creature* creature) : NullCreatureAI(creature) { - return GetSunwellPlateauAI(creature); } - struct npc_singularityAI : public NullCreatureAI - { - npc_singularityAI(Creature* creature) : NullCreatureAI(creature) - { - } + EventMap events; - EventMap events; + void Reset() override + { + me->DespawnOrUnsummon(18000); + me->CastSpell(me, SPELL_BLACK_HOLE_SUMMON_VISUAL, true); + me->CastSpell(me, SPELL_BLACK_HOLE_SUMMON_VISUAL2, true); + events.ScheduleEvent(EVENT_START_BLACK_HOLE, 3500); + events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 5000); + events.ScheduleEvent(EVENT_SINGULARITY_DEATH, 17000); + } - void Reset() override + void UpdateAI(uint32 diff) override + { + events.Update(diff); + switch (events.ExecuteEvent()) { - me->DespawnOrUnsummon(18000); - me->CastSpell(me, SPELL_BLACK_HOLE_SUMMON_VISUAL, true); - me->CastSpell(me, SPELL_BLACK_HOLE_SUMMON_VISUAL2, true); - events.ScheduleEvent(EVENT_START_BLACK_HOLE, 3500); - events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 5000); - events.ScheduleEvent(EVENT_SINGULARITY_DEATH, 17000); - } - - void UpdateAI(uint32 diff) override + case EVENT_SINGULARITY_DEATH: + me->KillSelf(); + break; + case EVENT_START_BLACK_HOLE: + me->RemoveAurasDueToSpell(SPELL_BLACK_HOLE_SUMMON_VISUAL2); + me->CastSpell(me, SPELL_BLACK_HOLE_VISUAL2, true); + me->CastSpell(me, SPELL_BLACK_HOLE_PASSIVE, true); + break; + case EVENT_SWITCH_BLACK_HOLE_TARGET: { - events.Update(diff); - switch (events.ExecuteEvent()) - { - case EVENT_SINGULARITY_DEATH: - me->KillSelf(); - break; - case EVENT_START_BLACK_HOLE: - me->RemoveAurasDueToSpell(SPELL_BLACK_HOLE_SUMMON_VISUAL2); - me->CastSpell(me, SPELL_BLACK_HOLE_VISUAL2, true); - me->CastSpell(me, SPELL_BLACK_HOLE_PASSIVE, true); - break; - case EVENT_SWITCH_BLACK_HOLE_TARGET: + Map::PlayerList const& players = me->GetMap()->GetPlayers(); + for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) + if (Player* player = itr->GetSource()) + if (me->GetDistance2d(player) < 15.0f && player->GetPositionZ() < 72.0f && player->IsAlive() && !player->HasAura(SPELL_BLACK_HOLE_EFFECT)) { - Map::PlayerList const& players = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) - if (Player* player = itr->GetSource()) - if (me->GetDistance2d(player) < 15.0f && player->GetPositionZ() < 72.0f && player->IsAlive() && !player->HasAura(SPELL_BLACK_HOLE_EFFECT)) - { - me->GetMotionMaster()->MovePoint(0, player->GetPositionX(), player->GetPositionY(), player->GetPositionZ(), false, true); - events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 5000); - return; - } - events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 500); - break; + me->GetMotionMaster()->MovePoint(0, player->GetPositionX(), player->GetPositionY(), player->GetPositionZ(), false, true); + events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 5000); + return; } - } + events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 500); + break; } - }; + } + } }; class spell_muru_summon_blood_elves_periodic_aura : public AuraScript @@ -475,9 +442,9 @@ class spell_entropius_black_hole_effect : public SpellScript void AddSC_boss_muru() { - new boss_muru(); - new boss_entropius(); - new npc_singularity(); + RegisterSunwellPlateauCreatureAI(boss_muru); + RegisterSunwellPlateauCreatureAI(boss_entropius); + RegisterSunwellPlateauCreatureAI(npc_singularity); RegisterSpellScript(spell_muru_summon_blood_elves_periodic_aura); RegisterSpellScript(spell_muru_darkness_aura); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h index d9a3af6302982c..e6e993d6495e1b 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h @@ -105,4 +105,6 @@ inline AI* GetSunwellPlateauAI(T* obj) return GetInstanceAI(obj, SWPScriptName); } +#define RegisterSunwellPlateauCreatureAI(ai_name) RegisterCreatureAIWithFactory(ai_name, GetSunwellPlateauAI) + #endif // SUNWELL_PLATEAU_H From b16a61078949eaeb2624e27543324e4c3ea71a1d Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 15:45:17 -0300 Subject: [PATCH 025/105] fix(Scripts/SSC): Improve Tainted Elemental combat behaviour (#20505) * fix(Scripts/SSC): Improve Tainted Elemental combat behaviour * Update boss_lady_vashj.cpp --- .../rev_1731220503708811500.sql | 8 +++ .../SerpentShrine/boss_lady_vashj.cpp | 72 +++---------------- 2 files changed, 18 insertions(+), 62 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731220503708811500.sql diff --git a/data/sql/updates/pending_db_world/rev_1731220503708811500.sql b/data/sql/updates/pending_db_world/rev_1731220503708811500.sql new file mode 100644 index 00000000000000..81d5ae11556330 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731220503708811500.sql @@ -0,0 +1,8 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 22009; + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 22009) AND (`source_type` = 0) AND (`id` IN (0, 1, 2)); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(22009, 0, 0, 1, 25, 0, 100, 0, 0, 0, 0, 0, 0, 0, 38, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Tainted Elemental - On Reset - Set In Combat With Zone'), +(22009, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 41, 15000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Tainted Elemental - On Reset - Despawn In 15000 ms'), +(22009, 0, 2, 0, 0, 0, 100, 0, 1000, 2000, 2350, 2650, 0, 0, 11, 38253, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Tainted Elemental - In Combat - Cast \'Poison Bolt\''); diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp index bcfbcc0e6e2cfa..d631825a7fce35 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp @@ -58,17 +58,13 @@ enum Spells SPELL_SUMMON_SPOREBAT2 = 38490, SPELL_SUMMON_SPOREBAT3 = 38492, SPELL_SUMMON_SPOREBAT4 = 38493, - SPELL_TOXIC_SPORES = 38574, - - SPELL_POISON_BOLT = 38253 + SPELL_TOXIC_SPORES = 38574 }; enum Misc { ITEM_TAINTED_CORE = 31088, - POINT_HOME = 1, - NPC_TRIGGER = 15384 }; @@ -125,29 +121,29 @@ struct boss_lady_vashj : public BossAI BossAI::JustEngagedWith(who); Talk(SAY_AGGRO); DoCastSelf(SPELL_REMOVE_TAINTED_CORES, true); - ScheduleSpells(); } void JustSummoned(Creature* summon) override { summons.Summon(summon); - switch (summon->GetEntry()) { - case(WORLD_TRIGGER): + switch (summon->GetEntry()) + { + case WORLD_TRIGGER: summon->CastSpell(summon, SPELL_MAGIC_BARRIER); break; - case(NPC_ENCHANTED_ELEMENTAL): + case NPC_ENCHANTED_ELEMENTAL: summon->GetMotionMaster()->MoveFollow(me, 0.0f, 0.0f, MOTION_SLOT_ACTIVE, false); summon->SetWalk(true); summon->SetReactState(REACT_PASSIVE); break; - case(NPC_TAINTED_ELEMENTAL): + case NPC_TAINTED_ELEMENTAL: break; - case(NPC_TOXIC_SPOREBAT): + case NPC_TOXIC_SPOREBAT: summon->GetMotionMaster()->MoveRandom(30.0f); break; default: - summon->GetMotionMaster()->MovePoint(POINT_HOME, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), true, true); + summon->GetMotionMaster()->MovePoint(POINT_HOME, me->GetPosition()); } } @@ -182,9 +178,8 @@ struct boss_lady_vashj : public BossAI void MovementInform(uint32 type, uint32 id) override { if (type != POINT_MOTION_TYPE || id != POINT_HOME) - { return; - } + me->AddUnitState(UNIT_STATE_ROOT); me->SetFacingTo(me->GetHomePosition().GetOrientation()); instance->SetData(DATA_ACTIVATE_SHIELD, 0); @@ -232,9 +227,7 @@ struct boss_lady_vashj : public BossAI }); } else - { context.Repeat(1s); - } }); } @@ -246,19 +239,15 @@ struct boss_lady_vashj : public BossAI scheduler.Update(diff); if (me->GetReactState() != REACT_AGGRESSIVE || !me->isAttackReady()) - { return; - } if (!me->IsWithinMeleeRange(me->GetVictim())) { me->resetAttackTimer(); me->SetSheath(SHEATH_STATE_RANGED); - me->CastSpell(me->GetVictim(), roll_chance_i(33) ? SPELL_MULTI_SHOT : SPELL_SHOOT, false); + DoCastVictim(roll_chance_i(33) ? SPELL_MULTI_SHOT : SPELL_SHOOT); if (roll_chance_i(15)) - { Talk(SAY_BOWSHOT); - } } else { @@ -280,42 +269,6 @@ struct boss_lady_vashj : public BossAI std::chrono::seconds _batTimer; }; -struct npc_tainted_elemental : public ScriptedAI -{ - npc_tainted_elemental(Creature* creature) : ScriptedAI(creature) { } - - void Reset() override - { - scheduler.CancelAll(); - me->SetInCombatWithZone(); - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - { - me->AddThreat(target, 1000.0f); - } - } - - void JustEngagedWith(Unit* /*who*/) override - { - scheduler.Schedule(100ms, 500ms, [this](TaskContext context) - { - DoCastVictim(SPELL_POISON_BOLT); - context.Repeat(2350ms, 2650ms); - }).Schedule(15s, [this](TaskContext) - { - me->DespawnOrUnsummon(); - }); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - scheduler.Update(diff); - } - -}; - class spell_lady_vashj_magic_barrier : public AuraScript { PrepareAuraScript(spell_lady_vashj_magic_barrier); @@ -339,9 +292,7 @@ class spell_lady_vashj_remove_tainted_cores : public SpellScript { PreventHitDefaultEffect(effIndex); if (Player* target = GetHitPlayer()) - { target->DestroyItemCount(ITEM_TAINTED_CORE, -1, true); - } } void Register() override @@ -374,9 +325,7 @@ class spell_lady_vashj_spore_drop_effect : public SpellScript { PreventHitDefaultEffect(effIndex); if (Unit* target = GetHitUnit()) - { target->CastSpell(target, SPELL_TOXIC_SPORES, true, nullptr, nullptr, GetCaster()->GetGUID()); - } } void Register() override @@ -455,7 +404,6 @@ class spell_lady_vashj_summons : public SpellScript void AddSC_boss_lady_vashj() { RegisterSerpentShrineAI(boss_lady_vashj); - RegisterSerpentShrineAI(npc_tainted_elemental); RegisterSpellScript(spell_lady_vashj_magic_barrier); RegisterSpellScript(spell_lady_vashj_remove_tainted_cores); RegisterSpellScript(spell_lady_vashj_summon_sporebat); From 64ab05df37876d4c7ba135ea633570c3a1d14a33 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 10 Nov 2024 18:45:31 +0000 Subject: [PATCH 026/105] chore(DB): import pending files Referenced commit(s): bf925eda3c94b5dfd099a740fee33e9c04071867 --- .../rev_1731220503708811500.sql => db_world/2024_11_10_03.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731220503708811500.sql => db_world/2024_11_10_03.sql} (96%) diff --git a/data/sql/updates/pending_db_world/rev_1731220503708811500.sql b/data/sql/updates/db_world/2024_11_10_03.sql similarity index 96% rename from data/sql/updates/pending_db_world/rev_1731220503708811500.sql rename to data/sql/updates/db_world/2024_11_10_03.sql index 81d5ae11556330..f0d4eb915dd51e 100644 --- a/data/sql/updates/pending_db_world/rev_1731220503708811500.sql +++ b/data/sql/updates/db_world/2024_11_10_03.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_10_02 -> 2024_11_10_03 -- UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 22009; From 4470891310c54a4b9fd47a246e25c217096dfdec Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 15:51:28 -0300 Subject: [PATCH 027/105] fix(Scripts/MagisterTerrace): Add all spells to SpellDifficulty dbc (#20502) --- .../rev_1731215535134824600.sql | 26 +++++ .../boss_felblood_kaelthas.cpp | 7 +- .../boss_priestess_delrissa.cpp | 97 ++++++++----------- .../MagistersTerrace/boss_selin_fireheart.cpp | 5 +- .../MagistersTerrace/boss_vexallus.cpp | 10 +- 5 files changed, 73 insertions(+), 72 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731215535134824600.sql diff --git a/data/sql/updates/pending_db_world/rev_1731215535134824600.sql b/data/sql/updates/pending_db_world/rev_1731215535134824600.sql new file mode 100644 index 00000000000000..f8b41f55cefb6d --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731215535134824600.sql @@ -0,0 +1,26 @@ +-- +DELETE FROM `spelldifficulty_dbc` WHERE `ID` IN (44318, 44319, 44294, 44174, 44291, 14032, 15657, 44267, 12471, 14875, 11428, 44178, 44176, 12611, 15043, 15620, 21401, 44256, 44272, 44137, 46024, 44189); +INSERT INTO `spelldifficulty_dbc` (`ID`, `DifficultySpellID_1`, `DifficultySpellID_2`, `DifficultySpellID_3`, `DifficultySpellID_4`) VALUES +(44318, 44318, 46380, 0, 0), +(44319, 44319, 46381, 0, 0), +(44294, 44294, 46155, 0, 0), +(44174, 44174, 46192, 0, 0), +(44291, 44291, 46193, 0, 0), +(14032, 14032, 15654, 0, 0), +(27611, 27611, 46189, 0, 0), +(15657, 15657, 15582, 0, 0), +(44267, 44267, 46191, 0, 0), +(12471, 12471, 15232, 0, 0), +(14875, 14875, 46190, 0, 0), +(11428, 11428, 46183, 0, 0), +(44178, 44178, 46195, 0, 0), +(44176, 44176, 46194, 0, 0), +(12611, 12611, 38384, 0, 0), +(15043, 15043, 15530, 0, 0), +(15620, 15620, 22907, 0, 0), +(21401, 21401, 46180, 0, 0), +(44256, 44256, 46181, 0, 0), +(44272, 44272, 46186, 0, 0), +(44137, 44137, 46187, 0, 0), +(46024, 46024, 46184, 0, 0), +(44189, 44189, 46164, 0, 0); diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp index 24fc0c42adb55e..b66ba4e60ffff5 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp @@ -37,8 +37,7 @@ enum Says enum Spells { // Phase 1 - SPELL_FIREBALL_N = 44189, - SPELL_FIREBALL_H = 46164, + SPELL_FIREBALL = 44189, SPELL_FLAMESTRIKE_SUMMON = 44192, SPELL_PHOENIX = 44194, SPELL_SHOCK_BARRIER = 46165, @@ -122,9 +121,7 @@ struct boss_felblood_kaelthas : public ScriptedAI summons.DespawnAll(); if (GameObject* orb = instance->GetGameObject(DATA_ESCAPE_ORB)) - { orb->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE); - } } void JustEngagedWith(Unit* /*who*/) override @@ -219,7 +216,7 @@ struct boss_felblood_kaelthas : public ScriptedAI switch (uint32 eventId = events.ExecuteEvent()) { case EVENT_SPELL_FIREBALL: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_FIREBALL_N, SPELL_FIREBALL_H), false); + me->CastSpell(me->GetVictim(), SPELL_FIREBALL, false); events.ScheduleEvent(EVENT_SPELL_FIREBALL, urand(3000, 4500)); break; case EVENT_SPELL_FLAMESTRIKE: diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp index e93336e13d2a2e..28be3faf6d2865 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp @@ -32,12 +32,9 @@ enum Spells SPELL_MEDALION_OF_IMMUNITY = 46227, SPELL_DISPEL_MAGIC = 27609, SPELL_FLASH_HEAL = 17843, - SPELL_SHADOW_WORD_PAIN_N = 14032, - SPELL_SHADOW_WORD_PAIN_H = 15654, - SPELL_POWER_WORD_SHIELD_N = 44291, - SPELL_POWER_WORD_SHIELD_H = 46193, - SPELL_RENEW_N = 44174, - SPELL_RENEW_H = 46192, + SPELL_SHADOW_WORD_PAIN = 14032, + SPELL_POWER_WORD_SHIELD = 44291, + SPELL_RENEW = 44174 }; enum Misc @@ -196,14 +193,14 @@ struct boss_priestess_delrissa : public ScriptedAI break; case EVENT_SPELL_RENEW: if (Unit* target = DoSelectLowestHpFriendly(40.0f, 1000)) - me->CastSpell(target, DUNGEON_MODE(SPELL_RENEW_N, SPELL_RENEW_H), false); + me->CastSpell(target, SPELL_RENEW, false); events.ScheduleEvent(EVENT_SPELL_RENEW, 7000); break; case EVENT_SPELL_PW_SHIELD: { - std::list cList = DoFindFriendlyMissingBuff(40.0f, DUNGEON_MODE(SPELL_POWER_WORD_SHIELD_N, SPELL_POWER_WORD_SHIELD_H)); + std::list cList = DoFindFriendlyMissingBuff(40.0f, SPELL_POWER_WORD_SHIELD); if (Unit* target = Acore::Containers::SelectRandomContainerElement(cList)) - me->CastSpell(target, DUNGEON_MODE(SPELL_POWER_WORD_SHIELD_N, SPELL_POWER_WORD_SHIELD_H), false); + me->CastSpell(target, SPELL_POWER_WORD_SHIELD, false); events.ScheduleEvent(EVENT_SPELL_PW_SHIELD, 10000); break; } @@ -239,7 +236,7 @@ struct boss_priestess_delrissa : public ScriptedAI break; case EVENT_SPELL_SW_PAIN: if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 30.0f)) - me->CastSpell(target, DUNGEON_MODE(SPELL_SHADOW_WORD_PAIN_N, SPELL_SHADOW_WORD_PAIN_H), false); + me->CastSpell(target, SPELL_SHADOW_WORD_PAIN, false); events.ScheduleEvent(EVENT_SPELL_SW_PAIN, 10000); break; } @@ -397,10 +394,8 @@ enum RogueEnum SPELL_VANISH = 44290, SPELL_GOUGE = 12540, SPELL_KICK = 27613, - SPELL_BACKSTAB_N = 15657, - SPELL_BACKSTAB_H = 15582, - SPELL_EVISCERATE_N = 27611, - SPELL_EVISCERATE_H = 46189, + SPELL_BACKSTAB = 15657, + SPELL_EVISCERATE = 27611, EVENT_SPELL_GOUGE = 1, EVENT_SPELL_KICK = 2, @@ -461,13 +456,13 @@ struct boss_kagani_nightstrike : public boss_priestess_lackey_commonAI events.ScheduleEvent(EVENT_SPELL_KICK, 1000); break; case EVENT_SPELL_EVISCERATE: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_EVISCERATE_N, SPELL_EVISCERATE_H), false); + me->CastSpell(me->GetVictim(), SPELL_EVISCERATE, false); events.ScheduleEvent(EVENT_SPELL_EVISCERATE, 10000); break; case EVENT_SPELL_BACKSTAB: if (!me->GetVictim()->HasInArc(static_cast(M_PI), me)) { - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_BACKSTAB_N, SPELL_BACKSTAB_H), false); + me->CastSpell(me->GetVictim(), SPELL_BACKSTAB, false); events.ScheduleEvent(EVENT_SPELL_BACKSTAB, 5000); } else @@ -481,12 +476,9 @@ struct boss_kagani_nightstrike : public boss_priestess_lackey_commonAI enum WarlockEnum { - SPELL_IMMOLATE_N = 44267, - SPELL_IMMOLATE_H = 46191, - SPELL_SHADOW_BOLT_N = 12471, - SPELL_SHADOW_BOLT_H = 15232, - SPELL_CURSE_OF_AGONY_N = 14875, - SPELL_CURSE_OF_AGONY_H = 46190, + SPELL_IMMOLATE = 44267, + SPELL_SHADOW_BOLT = 12471, + SPELL_CURSE_OF_AGONY = 14875, SPELL_SEED_OF_CORRUPTION = 44141, SPELL_FEAR = 38595, SPELL_SUMMON_IMP = 44163, @@ -525,11 +517,11 @@ struct boss_ellris_duskhallow : public boss_priestess_lackey_commonAI { case EVENT_SPELL_IMMOLATE: if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 30.0f)) - me->CastSpell(target, DUNGEON_MODE(SPELL_IMMOLATE_N, SPELL_IMMOLATE_H), false); + me->CastSpell(target, SPELL_IMMOLATE, false); events.ScheduleEvent(EVENT_SPELL_IMMOLATE, 12000); break; case EVENT_SPELL_SHADOW_BOLT: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_SHADOW_BOLT_N, SPELL_SHADOW_BOLT_H), false); + me->CastSpell(me->GetVictim(), SPELL_SHADOW_BOLT, false); events.ScheduleEvent(EVENT_SPELL_SHADOW_BOLT, 5000); break; case EVENT_SPELL_SEED_OF_CORRUPTION: @@ -539,7 +531,7 @@ struct boss_ellris_duskhallow : public boss_priestess_lackey_commonAI break; case EVENT_SPELL_CURSE_OF_AGONY: if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 30.0f)) - me->CastSpell(target, DUNGEON_MODE(SPELL_CURSE_OF_AGONY_N, SPELL_CURSE_OF_AGONY_H), false); + me->CastSpell(target, SPELL_CURSE_OF_AGONY, false); events.ScheduleEvent(EVENT_SPELL_CURSE_OF_AGONY, 13000); break; case EVENT_SPELL_FEAR: @@ -555,8 +547,7 @@ struct boss_ellris_duskhallow : public boss_priestess_lackey_commonAI enum MonkEnum { - SPELL_KNOCKDOWN_N = 11428, - SPELL_KNOCKDOWN_H = 46183, + SPELL_KNOCKDOWN = 11428, SPELL_SNAP_KICK = 46182, SPELL_FISTS_OF_ARCANE = 44120, @@ -588,7 +579,7 @@ struct boss_eramas_brightblaze : public boss_priestess_lackey_commonAI switch (actualEventId) { case EVENT_SPELL_KNOCKDOWN: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_KNOCKDOWN_N, SPELL_KNOCKDOWN_H), false); + me->CastSpell(me->GetVictim(), SPELL_KNOCKDOWN, false); events.ScheduleEvent(EVENT_SPELL_KNOCKDOWN, 10000); break; case EVENT_SPELL_SNAP_KICK: @@ -609,14 +600,10 @@ enum MageEnum { SPELL_POLYMORPH = 13323, SPELL_ICE_BLOCK = 27619, - SPELL_BLIZZARD_N = 44178, - SPELL_BLIZZARD_H = 46195, - SPELL_ICE_LANCE_N = 44176, - SPELL_ICE_LANCE_H = 46194, - SPELL_CONE_OF_COLD_N = 38384, - SPELL_CONE_OF_COLD_H = 12611, - SPELL_FROSTBOLT_N = 15043, - SPELL_FROSTBOLT_H = 15530, + SPELL_BLIZZARD = 44178, + SPELL_ICE_LANCE = 44176, + SPELL_CONE_OF_COLD = 12611, + SPELL_FROSTBOLT = 15043, SPELL_BLINK = 14514, EVENT_SPELL_POLYMORPH = 1, @@ -669,19 +656,19 @@ struct boss_yazzai : public boss_priestess_lackey_commonAI break; case EVENT_SPELL_BLIZZARD: if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - me->CastSpell(target, DUNGEON_MODE(SPELL_BLIZZARD_N, SPELL_BLIZZARD_H), false); + me->CastSpell(target, SPELL_BLIZZARD, false); events.ScheduleEvent(EVENT_SPELL_BLIZZARD, 20000); break; case EVENT_SPELL_ICE_LANCE: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_ICE_LANCE_N, SPELL_ICE_LANCE_H), false); + me->CastSpell(me->GetVictim(), SPELL_ICE_LANCE, false); events.ScheduleEvent(EVENT_SPELL_ICE_LANCE, 12000); break; case EVENT_SPELL_COC: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_CONE_OF_COLD_N, SPELL_CONE_OF_COLD_H), false); + me->CastSpell(me->GetVictim(), SPELL_CONE_OF_COLD, false); events.ScheduleEvent(EVENT_SPELL_COC, 10000); break; case EVENT_SPELL_FROSTBOLT: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_FROSTBOLT_N, SPELL_FROSTBOLT_H), false); + me->CastSpell(me->GetVictim(), SPELL_FROSTBOLT, false); events.ScheduleEvent(EVENT_SPELL_FROSTBOLT, 8000); break; case EVENT_SPELL_BLINK: @@ -784,8 +771,7 @@ struct boss_warlord_salaris : public boss_priestess_lackey_commonAI enum HunterEnum { SPELL_AIMED_SHOT = 44271, - SPELL_SHOOT_N = 15620, - SPELL_SHOOT_H = 22907, + SPELL_SHOOT = 15620, SPELL_CONCUSSIVE_SHOT = 27634, SPELL_MULTI_SHOT = 31942, SPELL_WING_CLIP = 44286, @@ -848,7 +834,7 @@ struct boss_garaxxas : public boss_priestess_lackey_commonAI events.ScheduleEvent(EVENT_SPELL_MULTI_SHOT, 10000); break; case EVENT_SPELL_SHOOT: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_SHOOT_N, SPELL_SHOOT_H), false); + me->CastSpell(me->GetVictim(), SPELL_SHOOT, false); events.ScheduleEvent(EVENT_SPELL_SHOOT, 2500); break; } @@ -864,10 +850,8 @@ enum ShamanEnum SPELL_EARTHBIND_TOTEM = 15786, SPELL_WAR_STOMP = 46026, SPELL_PURGE = 27626, - SPELL_LESSER_HEALING_WAVE_N = 44256, - SPELL_LESSER_HEALING_WAVE_H = 46181, - SPELL_FROST_SHOCK_N = 21401, - SPELL_FROST_SHOCK_H = 46180, + SPELL_LESSER_HEALING_WAVE = 44256, + SPELL_FROST_SHOCK = 21401, EVENT_SPELL_TOTEM1 = 1, EVENT_SPELL_TOTEM2 = 2, @@ -933,12 +917,12 @@ struct boss_apoko : public boss_priestess_lackey_commonAI events.ScheduleEvent(EVENT_SPELL_PURGE, 15000); break; case EVENT_SPELL_FROST_SHOCK: - me->CastSpell(me, DUNGEON_MODE(SPELL_FROST_SHOCK_N, SPELL_FROST_SHOCK_H), false); + me->CastSpell(me, SPELL_FROST_SHOCK, false); events.ScheduleEvent(EVENT_SPELL_FROST_SHOCK, 12000); break; case EVENT_SPELL_HEALING_WAVE: if (Unit* target = DoSelectLowestHpFriendly(40.0f, 1000)) - me->CastSpell(target, DUNGEON_MODE(SPELL_LESSER_HEALING_WAVE_N, SPELL_LESSER_HEALING_WAVE_H), false); + me->CastSpell(target, SPELL_LESSER_HEALING_WAVE, false); events.ScheduleEvent(EVENT_SPELL_HEALING_WAVE, 12000); break; } @@ -949,12 +933,9 @@ struct boss_apoko : public boss_priestess_lackey_commonAI enum EngineerEnum { - SPELL_GOBLIN_DRAGON_GUN_N = 44272, - SPELL_GOBLIN_DRAGON_GUN_H = 46186, - SPELL_ROCKET_LAUNCH_N = 44137, - SPELL_ROCKET_LAUNCH_H = 46187, - SPELL_FEL_IRON_BOMB_N = 46024, - SPELL_FEL_IRON_BOMB_H = 46184, + SPELL_GOBLIN_DRAGON_GUN = 44272, + SPELL_ROCKET_LAUNCH = 44137, + SPELL_FEL_IRON_BOMB = 46024, SPELL_RECOMBOBULATE = 44274, SPELL_HIGH_EXPLOSIVE_SHEEP = 44276, @@ -990,16 +971,16 @@ struct boss_zelfan : public boss_priestess_lackey_commonAI switch (actualEventId) { case EVENT_SPELL_DRAGON_GUN: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_GOBLIN_DRAGON_GUN_N, SPELL_GOBLIN_DRAGON_GUN_H), false); + me->CastSpell(me->GetVictim(), SPELL_GOBLIN_DRAGON_GUN, false); events.ScheduleEvent(EVENT_SPELL_DRAGON_GUN, 20000); break; case EVENT_SPELL_ROCKET_LAUNCH: - me->CastSpell(me->GetVictim(), DUNGEON_MODE(SPELL_ROCKET_LAUNCH_N, SPELL_ROCKET_LAUNCH_H), false); + me->CastSpell(me->GetVictim(), SPELL_ROCKET_LAUNCH, false); events.ScheduleEvent(EVENT_SPELL_ROCKET_LAUNCH, 20000); break; case EVENT_SPELL_IRON_BOMB: if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 15.0f)) - me->CastSpell(target, DUNGEON_MODE(SPELL_FEL_IRON_BOMB_N, SPELL_FEL_IRON_BOMB_H), false); + me->CastSpell(target, SPELL_FEL_IRON_BOMB, false); events.ScheduleEvent(EVENT_SPELL_IRON_BOMB, 20000); break; case EVENT_SPELL_RECOMBOBULATE: diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp index 22593395651845..93d30adddc5af2 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp @@ -36,8 +36,7 @@ enum Spells SPELL_MANA_RAGE_TRIGGER = 44321, //Selin's spells - SPELL_DRAIN_LIFE_N = 44294, - SPELL_DRAIN_LIFE_H = 46155, + SPELL_DRAIN_LIFE = 44294, SPELL_FEL_EXPLOSION = 44314, SPELL_DRAIN_MANA = 46153 }; @@ -181,7 +180,7 @@ struct boss_selin_fireheart : public ScriptedAI { case EVENT_SPELL_DRAIN_LIFE: if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - me->CastSpell(target, DUNGEON_MODE(SPELL_DRAIN_LIFE_N, SPELL_DRAIN_LIFE_H), false); + me->CastSpell(target, SPELL_DRAIN_LIFE, false); events.ScheduleEvent(EVENT_SPELL_DRAIN_LIFE, 10000, 1); return; case EVENT_SPELL_DRAIN_MANA: diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp index 6dbf562d7c7bff..241be976717651 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp @@ -35,11 +35,9 @@ enum Spells SPELL_ENERGY_FEEDBACK = 44335, // Vexallus spell info - SPELL_CHAIN_LIGHTNING_N = 44318, - SPELL_CHAIN_LIGHTNING_H = 46380, + SPELL_CHAIN_LIGHTNING = 44318, SPELL_OVERLOAD = 44352, - SPELL_ARCANE_SHOCK_N = 44319, - SPELL_ARCANE_SHOCK_H = 46381, + SPELL_ARCANE_SHOCK = 44319, SPELL_SUMMON_PURE_ENERGY_N = 44322, SPELL_SUMMON_PURE_ENERGY_H1 = 46154, @@ -93,12 +91,12 @@ struct boss_vexallus : public BossAI ScheduleTimedEvent(8s, [&] { - DoCastRandomTarget(DUNGEON_MODE(SPELL_CHAIN_LIGHTNING_N, SPELL_CHAIN_LIGHTNING_H)); + DoCastRandomTarget(SPELL_CHAIN_LIGHTNING); }, 8s, 8s); ScheduleTimedEvent(5s, [&] { - DoCastRandomTarget(DUNGEON_MODE(SPELL_ARCANE_SHOCK_N, SPELL_ARCANE_SHOCK_H)); + DoCastRandomTarget(SPELL_ARCANE_SHOCK); }, 8s, 8s); } From aede0020cb90013673e5ad26391b2ee5bb2ef4e9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 10 Nov 2024 18:52:23 +0000 Subject: [PATCH 028/105] chore(DB): import pending files Referenced commit(s): 4470891310c54a4b9fd47a246e25c217096dfdec --- .../rev_1731215535134824600.sql => db_world/2024_11_10_04.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731215535134824600.sql => db_world/2024_11_10_04.sql} (95%) diff --git a/data/sql/updates/pending_db_world/rev_1731215535134824600.sql b/data/sql/updates/db_world/2024_11_10_04.sql similarity index 95% rename from data/sql/updates/pending_db_world/rev_1731215535134824600.sql rename to data/sql/updates/db_world/2024_11_10_04.sql index f8b41f55cefb6d..ab5b9c2016bd4d 100644 --- a/data/sql/updates/pending_db_world/rev_1731215535134824600.sql +++ b/data/sql/updates/db_world/2024_11_10_04.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_10_03 -> 2024_11_10_04 -- DELETE FROM `spelldifficulty_dbc` WHERE `ID` IN (44318, 44319, 44294, 44174, 44291, 14032, 15657, 44267, 12471, 14875, 11428, 44178, 44176, 12611, 15043, 15620, 21401, 44256, 44272, 44137, 46024, 44189); INSERT INTO `spelldifficulty_dbc` (`ID`, `DifficultySpellID_1`, `DifficultySpellID_2`, `DifficultySpellID_3`, `DifficultySpellID_4`) VALUES From 7f558f4e382302abd85505fab9d982890d58ce26 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Sun, 10 Nov 2024 20:58:51 -0300 Subject: [PATCH 029/105] refactor(Scripts/MagisterTerrace): Move Kalecgos script to SAI (#20495) * refactor(Scripts/MagisterTerrace): Move Kalecgos script to SAI * Update instance_magisters_terrace.cpp --- .../rev_1731187917937110400.sql | 16 +++++ .../instance_magisters_terrace.cpp | 62 +------------------ .../MagistersTerrace/magisters_terrace.h | 8 +-- 3 files changed, 19 insertions(+), 67 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731187917937110400.sql diff --git a/data/sql/updates/pending_db_world/rev_1731187917937110400.sql b/data/sql/updates/pending_db_world/rev_1731187917937110400.sql new file mode 100644 index 00000000000000..91478e22cc5b34 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731187917937110400.sql @@ -0,0 +1,16 @@ +-- +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 24844; + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 24844) AND (`source_type` = 0) AND (`id` IN (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10)); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(24844, 0, 0, 1, 34, 0, 100, 0, 0, 6, 0, 0, 0, 0, 5, 293, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Reached Point 6 - Play Emote 293'), +(24844, 0, 1, 2, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 207, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Reached Point 6 - Set hover 0'), +(24844, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 67, 0, 2000, 2000, 0, 0, 100, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Reached Point 6 - Create Timed Event'), +(24844, 0, 3, 4, 59, 0, 100, 0, 0, 0, 0, 0, 0, 0, 11, 44762, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Timed Event 0 Triggered - Cast \'Camera Shake - Med\''), +(24844, 0, 4, 5, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 227, 0.6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Timed Event 0 Triggered - Set Scale to 0.6%'), +(24844, 0, 5, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 67, 1, 1000, 1000, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Timed Event 0 Triggered - Create Timed Event'), +(24844, 0, 6, 7, 59, 0, 100, 0, 1, 0, 0, 0, 0, 0, 11, 46307, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Timed Event 1 Triggered - Cast \'Scrying Orb Kill Credit\''), +(24844, 0, 7, 8, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 11, 24085, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Timed Event 1 Triggered - Cast \'Transform Visual\''), +(24844, 0, 8, 9, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 11, 44670, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Timed Event 1 Triggered - Cast \'KalecgosTransform into Kalec\''), +(24844, 0, 9, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 36, 24848, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Timed Event 1 Triggered - Update Template To \'Kalecgos\''), +(24844, 0, 10, 0, 25, 0, 100, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Kalecgos - On Reset - Say Line 0'); diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp index fb72da90ee9049..8b91165d02d809 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp @@ -23,6 +23,7 @@ ObjectData const creatureData[] = { + { NPC_KAEL_THAS, DATA_KAELTHAS }, { NPC_KALECGOS, DATA_KALECGOS }, { 0, 0 } }; @@ -59,27 +60,19 @@ class instance_magisters_terrace : public InstanceMapScript LoadDoorData(doorData); } - ObjectGuid EscapeOrbGUID; - ObjectGuid DelrissaGUID; - ObjectGuid KaelGUID; void ProcessEvent(WorldObject* /*obj*/, uint32 eventId) override { if (eventId == EVENT_SPAWN_KALECGOS) - { if (!GetCreature(DATA_KALECGOS) && !scheduler.IsGroupScheduled(DATA_KALECGOS)) { scheduler.Schedule(1min, 1min, DATA_KALECGOS,[this](TaskContext) { if (Creature* kalecgos = instance->SummonCreature(NPC_KALECGOS, KalecgosSpawnPos)) - { kalecgos->GetMotionMaster()->MovePath(PATH_KALECGOS_FLIGHT, false); - kalecgos->AI()->Talk(SAY_KALECGOS_SPAWN); - } }); } - } } void OnCreatureCreate(Creature* creature) override @@ -89,12 +82,9 @@ class instance_magisters_terrace : public InstanceMapScript case NPC_DELRISSA: DelrissaGUID = creature->GetGUID(); break; - case NPC_KAEL_THAS: - KaelGUID = creature->GetGUID(); - break; case NPC_PHOENIX: case NPC_PHOENIX_EGG: - if (Creature* kael = instance->GetCreature(KaelGUID)) + if (Creature* kael = GetCreature(DATA_KAELTHAS)) kael->AI()->JustSummoned(creature); break; } @@ -105,9 +95,7 @@ class instance_magisters_terrace : public InstanceMapScript ObjectGuid GetGuidData(uint32 identifier) const override { if (identifier == NPC_DELRISSA) - { return DelrissaGUID; - } return ObjectGuid::Empty; } @@ -119,53 +107,7 @@ class instance_magisters_terrace : public InstanceMapScript } }; -enum Spells -{ - SPELL_KALECGOS_TRANSFORM = 44670, - SPELL_TRANSFORM_VISUAL = 24085, - SPELL_CAMERA_SHAKE = 44762, - SPELL_ORB_KILL_CREDIT = 46307 -}; - -enum MovementPoints -{ - POINT_ID_PREPARE_LANDING = 6 -}; - -struct npc_kalecgos : public ScriptedAI -{ - npc_kalecgos(Creature* creature) : ScriptedAI(creature) { } - - void MovementInform(uint32 type, uint32 pointId) override - { - if (type != WAYPOINT_MOTION_TYPE) - return; - - if (pointId == POINT_ID_PREPARE_LANDING) - { - me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); - me->SetDisableGravity(false); - me->SetHover(false); - - me->m_Events.AddEventAtOffset([this]() - { - DoCastAOE(SPELL_CAMERA_SHAKE); - me->SetObjectScale(0.6f); - - me->m_Events.AddEventAtOffset([this]() - { - DoCastSelf(SPELL_ORB_KILL_CREDIT, true); - DoCastSelf(SPELL_TRANSFORM_VISUAL); - DoCastSelf(SPELL_KALECGOS_TRANSFORM); - me->UpdateEntry(NPC_HUMAN_KALECGOS); - }, 1s); - }, 2s); - } - } -}; - void AddSC_instance_magisters_terrace() { new instance_magisters_terrace(); - RegisterMagistersTerraceCreatureAI(npc_kalecgos); } diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h index f914a1d919d09d..933c6758d5662c 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h @@ -42,8 +42,7 @@ enum MTCreatures NPC_KAEL_THAS = 24664, NPC_PHOENIX = 21362, NPC_PHOENIX_EGG = 21364, - NPC_KALECGOS = 24844, - NPC_HUMAN_KALECGOS = 24848 + NPC_KALECGOS = 24844 }; enum MTGameObjects @@ -61,11 +60,6 @@ enum InstanceEventIds EVENT_SPAWN_KALECGOS = 16547 }; -enum InstanceText -{ - SAY_KALECGOS_SPAWN = 0 -}; - enum MovementData { PATH_KALECGOS_FLIGHT = 248440 From d817f6765855cf8981af756c613e1e598a3ee2e1 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 10 Nov 2024 23:59:43 +0000 Subject: [PATCH 030/105] chore(DB): import pending files Referenced commit(s): 7f558f4e382302abd85505fab9d982890d58ce26 --- .../rev_1731187917937110400.sql => db_world/2024_11_10_05.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731187917937110400.sql => db_world/2024_11_10_05.sql} (98%) diff --git a/data/sql/updates/pending_db_world/rev_1731187917937110400.sql b/data/sql/updates/db_world/2024_11_10_05.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1731187917937110400.sql rename to data/sql/updates/db_world/2024_11_10_05.sql index 91478e22cc5b34..8cae4834711ece 100644 --- a/data/sql/updates/pending_db_world/rev_1731187917937110400.sql +++ b/data/sql/updates/db_world/2024_11_10_05.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_10_04 -> 2024_11_10_05 -- UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 24844; From e741a9a87f9a6af8efe1a2e6c856f2100e90ac25 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Mon, 11 Nov 2024 00:22:03 -0300 Subject: [PATCH 031/105] =?UTF-8?q?feat(Core/Scripting):=20Implement=20Set?= =?UTF-8?q?Invincibility()=20to=20prevent=20creatur=E2=80=A6=20(#20508)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../game/AI/ScriptedAI/ScriptedCreature.cpp | 11 +++++++- .../game/AI/ScriptedAI/ScriptedCreature.h | 7 ++++- .../BlackrockSpire/boss_gyth.cpp | 27 ++++++------------- 3 files changed, 24 insertions(+), 21 deletions(-) diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp index 5c6387d0662f48..86240a1a876420 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp @@ -194,6 +194,7 @@ ScriptedAI::ScriptedAI(Creature* creature) : CreatureAI(creature), { _isHeroic = me->GetMap()->IsHeroic(); _difficulty = Difficulty(me->GetMap()->GetSpawnMode()); + _invincible = false; } void ScriptedAI::AttackStartNoMove(Unit* who) @@ -222,6 +223,12 @@ void ScriptedAI::UpdateAI(uint32 /*diff*/) DoMeleeAttackIfReady(); } +void ScriptedAI::DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damagetype*/, SpellSchoolMask /*damageSchoolMask*/) +{ + if (IsInvincible() && damage >= me->GetHealth()) + damage = me->GetHealth() - 1; +} + void ScriptedAI::DoStartMovement(Unit* victim, float distance, float angle) { if (victim) @@ -732,8 +739,10 @@ void BossAI::UpdateAI(uint32 diff) DoMeleeAttackIfReady(); } -void BossAI::DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damagetype*/, SpellSchoolMask /*damageSchoolMask*/) +void BossAI::DamageTaken(Unit* attacker, uint32& damage, DamageEffectType damagetype, SpellSchoolMask damageSchoolMask) { + ScriptedAI::DamageTaken(attacker, damage, damagetype, damageSchoolMask); + if (_nextHealthCheck._valid) if (me->HealthBelowPctDamaged(_nextHealthCheck._healthPct, damage)) { diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.h b/src/server/game/AI/ScriptedAI/ScriptedCreature.h index f7e55f32efba42..0fd1c861b3783a 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedCreature.h +++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.h @@ -198,7 +198,7 @@ struct ScriptedAI : public CreatureAI void AttackStartNoMove(Unit* target); // Called at any Damage from any attacker (before damage apply) - void DamageTaken(Unit* /*attacker*/, uint32& /*damage*/, DamageEffectType /*damagetype*/, SpellSchoolMask /*damageSchoolMask*/) override {} + void DamageTaken(Unit* /*attacker*/, uint32& /*damage*/, DamageEffectType /*damagetype*/, SpellSchoolMask /*damageSchoolMask*/) override; //Called at World update tick void UpdateAI(uint32 diff) override; @@ -438,9 +438,14 @@ struct ScriptedAI : public CreatureAI Player* SelectTargetFromPlayerList(float maxdist, uint32 excludeAura = 0, bool mustBeInLOS = false) const; + // Allows dropping to 1 HP but prevents creature from dying. + void SetInvincibility(bool apply) { _invincible = apply; }; + [[nodiscard]] bool IsInvincible() const { return _invincible; }; + private: Difficulty _difficulty; bool _isHeroic; + bool _invincible; std::unordered_set _uniqueTimedEvents; }; diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp index ed9445b77d8fde..2beaacff3dcf74 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp @@ -62,13 +62,20 @@ class boss_gyth : public CreatureScript void Reset() override { - _summonedRend = false; if (instance->GetBossState(DATA_GYTH) == IN_PROGRESS) { instance->SetBossState(DATA_GYTH, NOT_STARTED); summons.DespawnAll(); me->DespawnOrUnsummon(); } + + SetInvincibility(true); // Don't let boss die before summoning Rend. + + ScheduleHealthCheckEvent(25, [&] { + DoCastAOE(SPELL_SUMMON_REND, true); + me->RemoveAura(SPELL_REND_MOUNTS); + SetInvincibility(false); + }); } void JustEngagedWith(Unit* /*who*/) override @@ -104,21 +111,6 @@ class boss_gyth : public CreatureScript instance->SetBossState(DATA_GYTH, DONE); } - void DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*type*/, SpellSchoolMask /*school*/) override - { - if (!_summonedRend && me->HealthBelowPctDamaged(25, damage)) - { - if (damage >= me->GetHealth()) - { - // Let creature fall to 1 HP but prevent it from dying before boss is summoned. - damage = me->GetHealth() - 1; - } - DoCast(me, SPELL_SUMMON_REND, true); - me->RemoveAura(SPELL_REND_MOUNTS); - _summonedRend = true; - } - } - void UpdateAI(uint32 diff) override { if (!UpdateVictim()) @@ -173,9 +165,6 @@ class boss_gyth : public CreatureScript } DoMeleeAttackIfReady(); } - - private: - bool _summonedRend; }; CreatureAI* GetAI(Creature* creature) const override From 0ce15f0f5a15401dabf6358ecf8a7aae05542d0c Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Mon, 11 Nov 2024 02:56:27 -0300 Subject: [PATCH 032/105] =?UTF-8?q?refactor(Scripts/SunwellPlateau):=20Ref?= =?UTF-8?q?actor=20areatriggers=20to=20OnlyOnceAr=E2=80=A6=20(#20515)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit refactor(Scripts/SunwellPlateau): Refactor areatriggers to OnlyOnceAreatrigger --- .../SunwellPlateau/boss_brutallus.cpp | 23 ++++------ .../SunwellPlateau/boss_eredar_twins.cpp | 22 ++++----- .../instance_sunwell_plateau.cpp | 46 +++++-------------- .../SunwellPlateau/sunwell_plateau.h | 25 ++++++---- 4 files changed, 46 insertions(+), 70 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp index e8e46a03f33351..96e15eb4f292c4 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp @@ -109,7 +109,7 @@ struct boss_brutallus : public BossAI Talk(YELL_DEATH); me->CastSpell(me, SPELL_SUMMON_BRUTALLUS_DEATH_CLOUD, true); - if (Creature* madrigosa = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MADRIGOSA))) + if (Creature* madrigosa = instance->GetCreature(DATA_MADRIGOSA)) madrigosa->AI()->DoAction(ACTION_SPAWN_FELMYST); } @@ -204,10 +204,11 @@ struct npc_madrigosa : public NullCreatureAI npc_madrigosa(Creature* creature) : NullCreatureAI(creature) { instance = creature->GetInstanceScript(); - bool appear = instance->GetBossState(DATA_BRUTALLUS) != DONE && instance->GetBossState(DATA_MADRIGOSA) == DONE; - creature->SetVisible(appear); creature->SetStandState(UNIT_STAND_STATE_DEAD); creature->SetDynamicFlag(UNIT_DYNFLAG_DEAD); + + if (instance->IsBossDone(DATA_BRUTALLUS)) + creature->SetVisible(false); } EventMap events; @@ -475,21 +476,17 @@ class spell_brutallus_burn : public SpellScript } }; -class AreaTrigger_at_sunwell_madrigosa : public AreaTriggerScript +class at_sunwell_madrigosa : public OnlyOnceAreaTriggerScript { public: - AreaTrigger_at_sunwell_madrigosa() : AreaTriggerScript("at_sunwell_madrigosa") {} + at_sunwell_madrigosa() : OnlyOnceAreaTriggerScript("at_sunwell_madrigosa") {} - bool OnTrigger(Player* player, AreaTrigger const* /*trigger*/) override + bool _OnTrigger(Player* player, AreaTrigger const* /*trigger*/) override { if (InstanceScript* instance = player->GetInstanceScript()) - if (instance->GetBossState(DATA_MADRIGOSA) != DONE) - { - instance->SetBossState(DATA_MADRIGOSA, NOT_STARTED); - instance->SetBossState(DATA_MADRIGOSA, DONE); - if (Creature* creature = ObjectAccessor::GetCreature(*player, instance->GetGuidData(NPC_MADRIGOSA))) + if (!instance->IsBossDone(DATA_BRUTALLUS)) + if (Creature* creature = instance->GetCreature(DATA_MADRIGOSA)) creature->AI()->DoAction(ACTION_START_EVENT); - } return true; } @@ -502,5 +499,5 @@ void AddSC_boss_brutallus() RegisterSpellScript(spell_madrigosa_activate_barrier); RegisterSpellScript(spell_madrigosa_deactivate_barrier); RegisterSpellScript(spell_brutallus_burn); - new AreaTrigger_at_sunwell_madrigosa(); + new at_sunwell_madrigosa(); } diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp index b3751e4278d3bc..6b2cef92b5c008 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp @@ -451,22 +451,20 @@ class spell_eredar_twins_blaze : public SpellScript } }; -class AreaTrigger_at_sunwell_eredar_twins : public AreaTriggerScript +class at_sunwell_eredar_twins : public OnlyOnceAreaTriggerScript { public: - AreaTrigger_at_sunwell_eredar_twins() : AreaTriggerScript("at_sunwell_eredar_twins") {} + at_sunwell_eredar_twins() : OnlyOnceAreaTriggerScript("at_sunwell_eredar_twins") {} - bool OnTrigger(Player* player, AreaTrigger const* /*trigger*/) override + bool _OnTrigger(Player* player, AreaTrigger const* /*trigger*/) override { if (InstanceScript* instance = player->GetInstanceScript()) - if (instance->GetBossState(DATA_EREDAR_TWINS_INTRO) != DONE) - { - instance->SetBossState(DATA_EREDAR_TWINS_INTRO, DONE); - if (Creature* creature = ObjectAccessor::GetCreature(*player, instance->GetGuidData(NPC_LADY_SACROLASH))) - creature->AI()->Talk(YELL_INTRO_SAC); - if (Creature* creature = ObjectAccessor::GetCreature(*player, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) - creature->AI()->Talk(YELL_INTRO_ALY); - } + { + if (Creature* creature = instance->GetCreature(DATA_SACROLASH)) + creature->AI()->Talk(YELL_INTRO_SAC); + if (Creature* creature = instance->GetCreature(DATA_ALYTHESS)) + creature->AI()->Talk(YELL_INTRO_ALY); + } return true; } @@ -480,5 +478,5 @@ void AddSC_boss_eredar_twins() RegisterSpellScript(spell_eredar_twins_apply_flame_touched); RegisterSpellScript(spell_eredar_twins_handle_touch); RegisterSpellScript(spell_eredar_twins_blaze); - new AreaTrigger_at_sunwell_eredar_twins(); + new at_sunwell_eredar_twins(); } diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp index 20ef8f39bd11a8..9c51e79c185e0c 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp @@ -33,6 +33,14 @@ DoorData const doorData[] = { 0, 0, DOOR_TYPE_ROOM } // END }; +ObjectData const creatureData[] = +{ + { NPC_LADY_SACROLASH, DATA_SACROLASH }, + { NPC_GRAND_WARLOCK_ALYTHESS, DATA_ALYTHESS }, + { NPC_MADRIGOSA, DATA_MADRIGOSA }, + { 0, 0, } +}; + class instance_sunwell_plateau : public InstanceMapScript { public: @@ -45,6 +53,7 @@ class instance_sunwell_plateau : public InstanceMapScript SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); + LoadObjectData(creatureData, nullptr); } void OnPlayerEnter(Player* player) override @@ -90,18 +99,9 @@ class instance_sunwell_plateau : public InstanceMapScript case NPC_BRUTALLUS: BrutallusGUID = creature->GetGUID(); break; - case NPC_MADRIGOSA: - MadrigosaGUID = creature->GetGUID(); - break; case NPC_FELMYST: FelmystGUID = creature->GetGUID(); break; - case NPC_GRAND_WARLOCK_ALYTHESS: - AlythessGUID = creature->GetGUID(); - break; - case NPC_LADY_SACROLASH: - SacrolashGUID = creature->GetGUID(); - break; case NPC_MURU: MuruGUID = creature->GetGUID(); break; @@ -144,6 +144,8 @@ class instance_sunwell_plateau : public InstanceMapScript default: break; } + + InstanceScript::OnCreatureCreate(creature); } void OnGameObjectCreate(GameObject* go) override @@ -179,23 +181,6 @@ class instance_sunwell_plateau : public InstanceMapScript } } - void OnGameObjectRemove(GameObject* go) override - { - switch (go->GetEntry()) - { - case GO_FIRE_BARRIER: - case GO_MURUS_GATE_1: - case GO_MURUS_GATE_2: - case GO_BOSS_COLLISION_1: - case GO_BOSS_COLLISION_2: - case GO_FORCE_FIELD: - RemoveDoor(go); - break; - default: - break; - } - } - ObjectGuid GetGuidData(uint32 id) const override { switch (id) @@ -206,14 +191,8 @@ class instance_sunwell_plateau : public InstanceMapScript return SathrovarrGUID; case NPC_BRUTALLUS: return BrutallusGUID; - case NPC_MADRIGOSA: - return MadrigosaGUID; case NPC_FELMYST: return FelmystGUID; - case NPC_GRAND_WARLOCK_ALYTHESS: - return AlythessGUID; - case NPC_LADY_SACROLASH: - return SacrolashGUID; case NPC_MURU: return MuruGUID; case NPC_ANVEENA: @@ -240,10 +219,7 @@ class instance_sunwell_plateau : public InstanceMapScript ObjectGuid KalecgosDragonGUID; ObjectGuid SathrovarrGUID; ObjectGuid BrutallusGUID; - ObjectGuid MadrigosaGUID; ObjectGuid FelmystGUID; - ObjectGuid AlythessGUID; - ObjectGuid SacrolashGUID; ObjectGuid MuruGUID; ObjectGuid KilJaedenGUID; ObjectGuid KilJaedenControllerGUID; diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h index e6e993d6495e1b..74969b0bb2f127 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h @@ -24,18 +24,23 @@ #define SWPScriptName "instance_sunwell_plateau" -enum DataTypes +enum BossIds { DATA_KALECGOS = 0, - DATA_MADRIGOSA = 1, - DATA_BRUTALLUS = 2, - DATA_FELMYST = 3, - DATA_FELMYST_DOORS = 4, - DATA_EREDAR_TWINS_INTRO = 5, - DATA_EREDAR_TWINS = 6, - DATA_MURU = 7, - DATA_KILJAEDEN = 8, - MAX_ENCOUNTERS = 9, + DATA_BRUTALLUS = 1, + DATA_FELMYST = 2, + DATA_FELMYST_DOORS = 3, + DATA_EREDAR_TWINS = 4, + DATA_MURU = 5, + DATA_KILJAEDEN = 6, + MAX_ENCOUNTERS +}; + +enum DataTypes +{ + DATA_SACROLASH = 0, + DATA_ALYTHESS = 1, + DATA_MADRIGOSA = 2, // GameObject GUIDs DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 = 10, From abde8ef5a8e488d0860f026f4cf6b4cbfff476fe Mon Sep 17 00:00:00 2001 From: avarishd <46330494+avarishd@users.noreply.github.com> Date: Mon, 11 Nov 2024 08:58:15 +0200 Subject: [PATCH 033/105] fix(DB/Loot): Humbert's set (#20451) * fix(DB/Loot): Humbert's set * . --- .../updates/pending_db_world/rev_1730825421243583400.sql | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1730825421243583400.sql diff --git a/data/sql/updates/pending_db_world/rev_1730825421243583400.sql b/data/sql/updates/pending_db_world/rev_1730825421243583400.sql new file mode 100644 index 00000000000000..488a326ddcaa11 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730825421243583400.sql @@ -0,0 +1,8 @@ +-- Humbert's set +DELETE FROM `reference_loot_template` WHERE `Item` IN (3053,4723,4724); + +DELETE FROM `creature_loot_template` WHERE `Entry`=14275 AND `Item`=3053; +DELETE FROM `creature_loot_template` WHERE `Entry`=2346 AND `Item`=4723; +INSERT INTO `creature_loot_template` (`Entry`, `Item`, `Reference`, `Chance`, `QuestRequired`, `LootMode`, `GroupId`, `MinCount`, `MaxCount`, `Comment`) VALUES +(14275, 3053, 0, 1.5, 0, 1, 0, 1, 1, 'Tamra Stormpike - Humbert\'s Chestpiece'), +(2346, 4723, 0, 3, 0, 1, 0, 1, 1, 'Dun Garok Priest - Humbert\'s Pants'); From 31d988a8b6dca13016226f6afa8c69d6f4f11b0b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 11 Nov 2024 06:59:11 +0000 Subject: [PATCH 034/105] chore(DB): import pending files Referenced commit(s): abde8ef5a8e488d0860f026f4cf6b4cbfff476fe --- .../rev_1730825421243583400.sql => db_world/2024_11_11_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1730825421243583400.sql => db_world/2024_11_11_00.sql} (92%) diff --git a/data/sql/updates/pending_db_world/rev_1730825421243583400.sql b/data/sql/updates/db_world/2024_11_11_00.sql similarity index 92% rename from data/sql/updates/pending_db_world/rev_1730825421243583400.sql rename to data/sql/updates/db_world/2024_11_11_00.sql index 488a326ddcaa11..dc1f6986bb505a 100644 --- a/data/sql/updates/pending_db_world/rev_1730825421243583400.sql +++ b/data/sql/updates/db_world/2024_11_11_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_10_05 -> 2024_11_11_00 -- Humbert's set DELETE FROM `reference_loot_template` WHERE `Item` IN (3053,4723,4724); From fec7c88b51e9335e6ab4b00f21b185449e5532da Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Mon, 11 Nov 2024 05:58:44 -0300 Subject: [PATCH 035/105] =?UTF-8?q?fix(Scripts/ZulAman):=20Amani=20Hatcher?= =?UTF-8?q?s=20should=20hatch=20eggs=20at=20increasing=20=E2=80=A6=20(#204?= =?UTF-8?q?97)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../rev_1731194758257727900.sql | 15 ++ .../EasternKingdoms/ZulAman/boss_janalai.cpp | 153 ++++++------------ 2 files changed, 68 insertions(+), 100 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731194758257727900.sql diff --git a/data/sql/updates/pending_db_world/rev_1731194758257727900.sql b/data/sql/updates/pending_db_world/rev_1731194758257727900.sql new file mode 100644 index 00000000000000..9473c09a942ac8 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731194758257727900.sql @@ -0,0 +1,15 @@ +-- +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 13 AND `SourceEntry` = 43734; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 43734, 0, 0, 31, 0, 3, 23817, 0, 0, 0, 0, '', 'Hatch Eggs can only hit Dragonhawk Egg'); + +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 23817; + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 23817) AND (`source_type` = 0) AND (`id` IN (0, 1)); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(23817, 0, 0, 0, 8, 0, 100, 0, 42471, 0, 0, 0, 0, 0, 11, 42493, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Dragonhawk Egg - On Spellhit \'Hatch Eggs\' - Cast \'Summon Dragonhawk Hatchling\''), +(23817, 0, 1, 0, 8, 0, 100, 0, 43734, 0, 0, 0, 0, 0, 11, 42493, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Dragonhawk Egg - On Spellhit \'Hatch Eggs\' - Cast \'Summon Dragonhawk Hatchling\''); + +DELETE FROM `creature_template_movement` WHERE `CreatureId` = 23598; +INSERT INTO `creature_template_movement` (`CreatureId`, `Ground`, `Flight`) VALUES +(23598, 1, 1); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp index 0fd4a8334b7b3c..ae7651914e9bf4 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp @@ -15,13 +15,6 @@ * with this program. If not, see . */ -/* ScriptData -SDName: Boss_Janalai -SD%Complete: 100 -SDComment: -SDCategory: Zul'Aman -EndScriptData */ - #include "CellImpl.h" #include "CreatureScript.h" #include "GridNotifiers.h" @@ -125,7 +118,13 @@ enum Misc struct boss_janalai : public BossAI { - boss_janalai(Creature* creature) : BossAI(creature, DATA_JANALAI) { } + boss_janalai(Creature* creature) : BossAI(creature, DATA_JANALAI) + { + scheduler.SetValidator([this] + { + return !me->HasUnitState(UNIT_STATE_CASTING); + }); + } void Reset() override { @@ -134,18 +133,17 @@ struct boss_janalai : public BossAI _isBombing = false; _isFlameBreathing = false; - ScheduleHealthCheckEvent(25, [&]{ - DoCastSelf(SPELL_ENRAGE, true); - }); - ScheduleHealthCheckEvent(35, [&]{ Talk(SAY_ALL_EGGS); me->AttackStop(); me->GetMotionMaster()->Clear(); me->SetPosition(janalainPos); me->StopMovingOnCurrentPos(); - DoCastSelf(SPELL_HATCH_ALL); - HatchAllEggs(HATCH_ALL); + DoCastAOE(SPELL_HATCH_ALL); + }); + + ScheduleHealthCheckEvent(25, [&] { + DoCastSelf(SPELL_ENRAGE, true); }); } @@ -209,19 +207,19 @@ struct boss_janalai : public BossAI return false; if (hatchAction == HATCH_RESET) + { for (Creature* egg : eggList) egg->Respawn(); - else if (hatchAction == HATCH_ALL) - DoCastSelf(SPELL_HATCH_EGG_ALL); - if (hatchAction == HATCH_RESET) - { std::list hatchlingList; me->GetCreaturesWithEntryInRange(hatchlingList, 100.0f, NPC_HATCHLING); for (Creature* hatchling : hatchlingList) hatchling->DespawnOrUnsummon(); hatchlingList.clear(); } + else if (hatchAction == HATCH_ALL) + DoCastSelf(SPELL_HATCH_EGG_ALL); + eggList.clear(); return true; } @@ -239,9 +237,7 @@ struct boss_janalai : public BossAI : me->SummonCreature(NPC_FIRE_BOMB, fireWallCoords[i].GetPositionX() - 2 + 4 * j, fireWallCoords[i].GetPositionY(), fireWallCoords[i].GetPositionZ(), fireWallCoords[i].GetOrientation(), TEMPSUMMON_TIMED_DESPAWN, 15000); if (wall) - { wall->AI()->DoCastSelf(SPELL_FIRE_WALL, true); - } } } } @@ -259,18 +255,16 @@ struct boss_janalai : public BossAI void Boom() { - std::list fireBombs; - me->GetCreaturesWithEntryInRange(fireBombs, 100.0f, NPC_FIRE_BOMB); - - if (fireBombs.empty()) - return; - - for (Creature* bomb : fireBombs) - { - bomb->AI()->DoCastSelf(SPELL_FIRE_BOMB_DAMAGE, true); - bomb->RemoveAllAuras(); - } - fireBombs.clear(); + summons.DoForAllSummons([&](WorldObject* summon) { + if (summon->GetEntry() == NPC_FIRE_BOMB) + { + if (Creature* bomb = summon->ToCreature()) + { + bomb->AI()->DoCastSelf(SPELL_FIRE_BOMB_DAMAGE, true); + bomb->RemoveAllAuras(); + } + } + }); } void StartBombing() @@ -286,14 +280,11 @@ struct boss_janalai : public BossAI SpawnBombs(); _isBombing = true; - if (Map* map = me->GetMap()) + me->GetMap()->DoForAllPlayers([&](Player* player) { - map->DoForAllPlayers([&](Player* player) - { - if (player->IsAlive()) - DoTeleportPlayer(player, janalainPos.GetPositionX() - 5 + rand() % 10, janalainPos.GetPositionY() - 5 + rand() % 10, janalainPos.GetPositionZ(), 0.0f); - }); - } + if (player->IsAlive()) + DoTeleportPlayer(player, janalainPos.GetPositionX() - 5 + rand() % 10, janalainPos.GetPositionY() - 5 + rand() % 10, janalainPos.GetPositionZ(), 0.0f); + }); //DoCast(Temp, SPELL_SUMMON_PLAYERS, true) // core bug, spell does not work if too far ThrowBombs(); @@ -308,20 +299,23 @@ struct boss_janalai : public BossAI void ThrowBombs() { - std::list fireBombs; std::chrono::milliseconds bombTimer = 100ms; - me->GetCreaturesWithEntryInRange(fireBombs, 100.0f, NPC_FIRE_BOMB); - for (Creature* bomb : fireBombs) - { - scheduler.Schedule(bombTimer, [this, bomb](TaskContext) + + summons.DoForAllSummons([this, &bombTimer](WorldObject* summon) { + if (summon->GetEntry() == NPC_FIRE_BOMB) { - bomb->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - DoCast(bomb, SPELL_FIRE_BOMB_THROW, true); - bomb->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - }); - bombTimer = bombTimer + 100ms; - } - fireBombs.clear(); + if (Creature* bomb = summon->ToCreature()) + { + bomb->m_Events.AddEventAtOffset([this, bomb] { + bomb->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + DoCast(bomb, SPELL_FIRE_BOMB_THROW, true); + bomb->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + }, bombTimer); + } + + bombTimer += 100ms; + } + }); } bool CheckEvadeIfOutOfCombatArea() const override @@ -335,10 +329,7 @@ struct boss_janalai : public BossAI struct npc_janalai_hatcher : public ScriptedAI { - npc_janalai_hatcher(Creature* creature) : ScriptedAI(creature) - { - _instance = creature->GetInstanceScript(); - } + npc_janalai_hatcher(Creature* creature) : ScriptedAI(creature) { } void Reset() override { @@ -347,7 +338,6 @@ struct npc_janalai_hatcher : public ScriptedAI _side = (me->GetPositionY() < 1150); _waypoint = 0; _isHatching = false; - _hasChangedSide = false; me->GetMotionMaster()->Clear(); me->GetMotionMaster()->MovePoint(0, hatcherway[_side][0]); } @@ -357,29 +347,13 @@ struct npc_janalai_hatcher : public ScriptedAI if (_waypoint == 5) { _isHatching = true; - std::list eggList; - me->GetCreaturesWithEntryInRange(eggList, 50.0f, NPC_EGG); - scheduler.Schedule(1500ms, SCHEDULER_GROUP_HATCHING, [this, eggList](TaskContext context) + + scheduler.Schedule(1500ms, SCHEDULER_GROUP_HATCHING, [this](TaskContext context) { - std::list unhatchedEggs; - for (Creature* egg : eggList) - { - if (egg->IsAlive()) - unhatchedEggs.emplace_front(egg); - } - Acore::Containers::RandomResize(unhatchedEggs, 1); - if (Creature* egg = unhatchedEggs.front()) - egg->AI()->DoCastSelf(SPELL_HATCH_EGG_SINGULAR); - else if (!_hasChangedSide) - { - _side = _side ? 0 : 1; - _isHatching = false; - _waypoint = 3; - MoveToNewWaypoint(_waypoint); - _hasChangedSide = true; - context.CancelGroup(SCHEDULER_GROUP_HATCHING); - } - context.Repeat(1500ms); + me->CastCustomSpell(SPELL_HATCH_EGG_ALL, SPELLVALUE_MAX_TARGETS, context.GetRepeatCounter() + 1); + + if (me->FindNearestCreature(NPC_EGG, 100.0f)) + context.Repeat(4s); }); } else @@ -411,19 +385,14 @@ struct npc_janalai_hatcher : public ScriptedAI void MoveInLineOfSight(Unit* /*who*/) override { } private: - InstanceScript* _instance; uint8 _side; uint8 _waypoint; bool _isHatching; - bool _hasChangedSide; }; struct npc_janalai_hatchling : public ScriptedAI { - npc_janalai_hatchling(Creature* creature) : ScriptedAI(creature) - { - _instance = creature->GetInstanceScript(); - } + npc_janalai_hatchling(Creature* creature) : ScriptedAI(creature) { } void Reset() override { @@ -433,7 +402,6 @@ struct npc_janalai_hatchling : public ScriptedAI else me->GetMotionMaster()->MovePoint(0, hatcherway[1][3].GetPositionX() + rand() % 4 - 2, 1150.0f + rand() % 4 - 2, hatcherway[1][3].GetPositionY()); - me->SetDisableGravity(true); me->SetInCombatWithZone(); } @@ -454,20 +422,6 @@ struct npc_janalai_hatchling : public ScriptedAI DoMeleeAttackIfReady(); } - -private: - InstanceScript* _instance; -}; - -struct npc_janalai_egg : public NullCreatureAI -{ - npc_janalai_egg(Creature* creature) : NullCreatureAI(creature) { } - - void SpellHit(Unit* /*caster*/, SpellInfo const* spell) override - { - if (spell->Id == SPELL_HATCH_EGG_ALL || spell->Id == SPELL_HATCH_EGG_SINGULAR) - DoCastSelf(SPELL_SUMMON_HATCHLING); - } }; void AddSC_boss_janalai() @@ -475,5 +429,4 @@ void AddSC_boss_janalai() RegisterZulAmanCreatureAI(boss_janalai); RegisterZulAmanCreatureAI(npc_janalai_hatcher); RegisterZulAmanCreatureAI(npc_janalai_hatchling); - RegisterZulAmanCreatureAI(npc_janalai_egg); } From 09352d8b912194993e82efcbe399f63e851e737b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 11 Nov 2024 08:59:40 +0000 Subject: [PATCH 036/105] chore(DB): import pending files Referenced commit(s): fec7c88b51e9335e6ab4b00f21b185449e5532da --- .../rev_1731194758257727900.sql => db_world/2024_11_11_01.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731194758257727900.sql => db_world/2024_11_11_01.sql} (97%) diff --git a/data/sql/updates/pending_db_world/rev_1731194758257727900.sql b/data/sql/updates/db_world/2024_11_11_01.sql similarity index 97% rename from data/sql/updates/pending_db_world/rev_1731194758257727900.sql rename to data/sql/updates/db_world/2024_11_11_01.sql index 9473c09a942ac8..89e8577519727d 100644 --- a/data/sql/updates/pending_db_world/rev_1731194758257727900.sql +++ b/data/sql/updates/db_world/2024_11_11_01.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_11_00 -> 2024_11_11_01 -- DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 13 AND `SourceEntry` = 43734; INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES From 519daf9cc7ccaf64293e29cad030f9c98a73b092 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Mon, 11 Nov 2024 06:09:08 -0300 Subject: [PATCH 037/105] refactor(Scripts/SunwellPlateau): Modernize Eredar Twins script (#20516) --- .../SunwellPlateau/boss_eredar_twins.cpp | 292 +++++++----------- 1 file changed, 109 insertions(+), 183 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp index 6b2cef92b5c008..a47d16bda5b1d3 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp @@ -70,29 +70,20 @@ enum Spells enum Misc { ACTION_SISTER_DIED = 1, - - EVENT_SPELL_SHADOW_BLADES = 1, - EVENT_SPELL_SHADOW_NOVA = 2, - EVENT_SPELL_CONFOUNDING_BLOW = 3, - EVENT_SHADOW_IMAGE = 4, - EVENT_SPELL_ENRAGE = 5, - EVENT_SPELL_CONFLAGRATION = 6, - EVENT_SPELL_BLAZE = 7, - EVENT_SPELL_PYROGENICS = 8, - EVENT_SPELL_FLAME_SEAR = 9 + GROUP_SPECIAL_ABILITY = 1 }; struct boss_sacrolash : public BossAI { - boss_sacrolash(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS) {} + boss_sacrolash(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS), _isSisterDead(false) {} - bool sisterDied; void Reset() override { - me->CastSpell(me, SPELL_SHADOWFORM, true); - sisterDied = false; + DoCastSelf(SPELL_SHADOWFORM, true); + _isSisterDead = false; BossAI::Reset(); me->SetLootMode(0); + me->m_Events.KillAllEvents(false); } void DoAction(int32 param) override @@ -100,20 +91,24 @@ struct boss_sacrolash : public BossAI if (param == ACTION_SISTER_DIED) { me->ResetLootMode(); - sisterDied = true; + _isSisterDead = true; Talk(YELL_SISTER_ALYTHESS_DEAD); me->CastSpell(me, SPELL_EMPOWER, true); - uint32 timer = events.GetNextEventTime(EVENT_SPELL_SHADOW_NOVA); - events.CancelEvent(EVENT_SPELL_SHADOW_NOVA); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, timer - events.GetTimer()); + scheduler.CancelGroup(GROUP_SPECIAL_ABILITY); + ScheduleTimedEvent(20s, [&] { + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + me->CastSpell(target, SPELL_CONFLAGRATION, false); + }, 30s, 35s); } } void EnterEvadeMode(EvadeReason why) override { BossAI::EnterEvadeMode(why); - if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) + if (Creature* alythess = instance->GetCreature(DATA_ALYTHESS)) { if (!alythess->IsAlive()) alythess->Respawn(true); @@ -125,15 +120,36 @@ struct boss_sacrolash : public BossAI void JustEngagedWith(Unit* who) override { BossAI::JustEngagedWith(who); - if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) + if (Creature* alythess = instance->GetCreature(DATA_ALYTHESS)) if (alythess->IsAlive() && !alythess->IsInCombat()) alythess->AI()->AttackStart(who); - events.ScheduleEvent(EVENT_SPELL_SHADOW_BLADES, 10000); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, 36000); - events.ScheduleEvent(EVENT_SPELL_CONFOUNDING_BLOW, 25000); - events.ScheduleEvent(EVENT_SHADOW_IMAGE, 20000); - events.ScheduleEvent(EVENT_SPELL_ENRAGE, 360000); + me->m_Events.AddEventAtOffset([&] { + Talk(YELL_BERSERK); + DoCastSelf(SPELL_ENRAGE, true); + }, 6min); + + ScheduleTimedEvent(10s, [&] { + DoCastSelf(SPELL_SHADOW_BLADES); + }, 10s); + + ScheduleTimedEvent(25s, [&] { + DoCastVictim(SPELL_CONFOUNDING_BLOW); + }, 20s, 25s); + + ScheduleTimedEvent(20s, [&] { + me->SummonCreature(NPC_SHADOW_IMAGE, me->GetPosition(), TEMPSUMMON_TIMED_DESPAWN, 12000); + }, 6s); + + scheduler.Schedule(36s, GROUP_SPECIAL_ABILITY, [this](TaskContext context) { + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + Talk(EMOTE_SHADOW_NOVA, target); + Talk(YELL_SHADOW_NOVA); + DoCast(target, SPELL_SHADOW_NOVA); + context.Repeat(30s, 35s); + }); } void KilledUnit(Unit* victim) override @@ -144,15 +160,14 @@ struct boss_sacrolash : public BossAI void JustDied(Unit* /*killer*/) override { - events.Reset(); summons.DespawnAll(); - if (sisterDied) + if (_isSisterDead) { Talk(YELL_SAC_DEAD); instance->SetBossState(DATA_EREDAR_TWINS, DONE); } - else if (Creature* alythess = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_GRAND_WARLOCK_ALYTHESS))) + else if (Creature* alythess = instance->GetCreature(DATA_ALYTHESS)) alythess->AI()->DoAction(ACTION_SISTER_DIED); } @@ -166,70 +181,21 @@ struct boss_sacrolash : public BossAI } } - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - Talk(YELL_ENRAGE); - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SPELL_CONFOUNDING_BLOW: - me->CastSpell(me->GetVictim(), SPELL_CONFOUNDING_BLOW, false); - events.ScheduleEvent(EVENT_SPELL_CONFOUNDING_BLOW, urand(20000, 25000)); - break; - case EVENT_SPELL_SHADOW_BLADES: - me->CastSpell(me, SPELL_SHADOW_BLADES, false); - events.ScheduleEvent(EVENT_SPELL_SHADOW_BLADES, 10000); - break; - case EVENT_SPELL_SHADOW_NOVA: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - Talk(EMOTE_SHADOW_NOVA, target); - Talk(YELL_SHADOW_NOVA); - me->CastSpell(target, SPELL_SHADOW_NOVA, false); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, urand(30000, 35000)); - break; - } - case EVENT_SHADOW_IMAGE: - me->SummonCreature(NPC_SHADOW_IMAGE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation(), TEMPSUMMON_TIMED_DESPAWN, 12000); - events.ScheduleEvent(EVENT_SHADOW_IMAGE, 6000); - break; - case EVENT_SPELL_CONFLAGRATION: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - me->CastSpell(target, SPELL_CONFLAGRATION, false); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, urand(30000, 35000)); - break; - } - } - - DoMeleeAttackIfReady(); - } + private: + bool _isSisterDead; }; struct boss_alythess : public BossAI { - boss_alythess(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS) { } + boss_alythess(Creature* creature) : BossAI(creature, DATA_EREDAR_TWINS), _isSisterDead(false) { } - bool sisterDied; void Reset() override { - me->CastSpell(me, SPELL_FIREFORM, true); - sisterDied = false; + DoCastSelf(SPELL_FIREFORM, true); + _isSisterDead = false; BossAI::Reset(); me->SetLootMode(0); + me->m_Events.KillAllEvents(false); } void DoAction(int32 param) override @@ -237,40 +203,65 @@ struct boss_alythess : public BossAI if (param == ACTION_SISTER_DIED) { me->ResetLootMode(); - sisterDied = true; + _isSisterDead = true; Talk(YELL_SISTER_SACROLASH_DEAD); me->CastSpell(me, SPELL_EMPOWER, true); - uint32 timer = events.GetNextEventTime(EVENT_SPELL_CONFLAGRATION); - events.CancelEvent(EVENT_SPELL_CONFLAGRATION); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, timer - events.GetTimer()); + scheduler.CancelGroup(GROUP_SPECIAL_ABILITY); + ScheduleTimedEvent(20s, [&] { + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + DoCast(target, SPELL_SHADOW_NOVA); + }, 30s, 35s); } } void EnterEvadeMode(EvadeReason why) override { BossAI::EnterEvadeMode(why); - if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) + if (Creature* sacrolash = instance->GetCreature(DATA_SACROLASH)) { - if (!scorlash->IsAlive()) - scorlash->Respawn(true); - else if (!scorlash->IsInEvadeMode()) - scorlash->AI()->EnterEvadeMode(why); + if (!sacrolash->IsAlive()) + sacrolash->Respawn(true); + else if (!sacrolash->IsInEvadeMode()) + sacrolash->AI()->EnterEvadeMode(why); } } void JustEngagedWith(Unit* who) override { BossAI::JustEngagedWith(who); - if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) - if (scorlash->IsAlive() && !scorlash->IsInCombat()) - scorlash->AI()->AttackStart(who); - - events.ScheduleEvent(EVENT_SPELL_BLAZE, 100); - events.ScheduleEvent(EVENT_SPELL_PYROGENICS, 15000); - events.ScheduleEvent(EVENT_SPELL_FLAME_SEAR, 20000); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, 30000); - events.ScheduleEvent(EVENT_SPELL_ENRAGE, 360000); + if (Creature* sacrolash = instance->GetCreature(DATA_SACROLASH)) + if (sacrolash->IsAlive() && !sacrolash->IsInCombat()) + sacrolash->AI()->AttackStart(who); + + me->m_Events.AddEventAtOffset([&] { + Talk(YELL_BERSERK); + DoCastSelf(SPELL_ENRAGE, true); + }, 6min); + + ScheduleTimedEvent(1s, [&] { + DoCastVictim(SPELL_BLAZE); + }, 3800ms); + + ScheduleTimedEvent(15s, [&] { + DoCastSelf(SPELL_PYROGENICS); + }, 15s); + + ScheduleTimedEvent(20s, [&] { + me->CastCustomSpell(SPELL_FLAME_SEAR, SPELLVALUE_MAX_TARGETS, 5, me, TRIGGERED_NONE); + }, 15s); + + scheduler.Schedule(20s, GROUP_SPECIAL_ABILITY, [this](TaskContext context) { + Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); + if (!target) + target = me->GetVictim(); + Talk(EMOTE_CONFLAGRATION, target); + Talk(YELL_CANFLAGRATION); + DoCast(target, SPELL_CONFLAGRATION); + context.Repeat(30s, 35s); + }); } void KilledUnit(Unit* victim) override @@ -281,111 +272,46 @@ struct boss_alythess : public BossAI void JustDied(Unit* /*killer*/) override { - events.Reset(); summons.DespawnAll(); - if (sisterDied) + if (_isSisterDead) { Talk(YELL_SAC_DEAD); instance->SetBossState(DATA_EREDAR_TWINS, DONE); } - else if (Creature* scorlash = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_LADY_SACROLASH))) - scorlash->AI()->DoAction(ACTION_SISTER_DIED); + else if (Creature* sacrolash = instance->GetCreature(DATA_SACROLASH)) + sacrolash->AI()->DoAction(ACTION_SISTER_DIED); } - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - Talk(YELL_BERSERK); - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SPELL_PYROGENICS: - me->CastSpell(me, SPELL_PYROGENICS, false); - events.ScheduleEvent(EVENT_SPELL_PYROGENICS, 15000); - break; - case EVENT_SPELL_FLAME_SEAR: - me->CastCustomSpell(SPELL_FLAME_SEAR, SPELLVALUE_MAX_TARGETS, 5, me, TRIGGERED_NONE); - events.ScheduleEvent(EVENT_SPELL_FLAME_SEAR, 15000); - break; - case EVENT_SPELL_BLAZE: - me->CastSpell(me->GetVictim(), SPELL_BLAZE, false); - events.ScheduleEvent(EVENT_SPELL_BLAZE, 3800); - break; - case EVENT_SPELL_SHADOW_NOVA: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - me->CastSpell(target, SPELL_SHADOW_NOVA, false); - events.ScheduleEvent(EVENT_SPELL_SHADOW_NOVA, urand(30000, 35000)); - break; - } - case EVENT_SPELL_CONFLAGRATION: - { - Unit* target = SelectTarget(SelectTargetMethod::MaxThreat, 1, 100.0f); - if (!target) - target = me->GetVictim(); - Talk(EMOTE_CONFLAGRATION, target); - Talk(YELL_CANFLAGRATION); - me->CastSpell(target, SPELL_CONFLAGRATION, false); - events.ScheduleEvent(EVENT_SPELL_CONFLAGRATION, urand(30000, 35000)); - break; - } - } - - DoMeleeAttackIfReady(); - } + private: + bool _isSisterDead; }; -class spell_eredar_twins_apply_dark_touched : public SpellScript +class spell_eredar_twins_apply_touch : public SpellScript { - PrepareSpellScript(spell_eredar_twins_apply_dark_touched); - - bool Validate(SpellInfo const* /*spellInfo*/) override - { - return ValidateSpellInfo({ SPELL_DARK_TOUCHED }); - } - - void HandleApplyTouch() - { - if (Player* target = GetHitPlayer()) - target->CastSpell(target, SPELL_DARK_TOUCHED, true); - } - - void Register() override - { - AfterHit += SpellHitFn(spell_eredar_twins_apply_dark_touched::HandleApplyTouch); - } -}; + PrepareSpellScript(spell_eredar_twins_apply_touch); -class spell_eredar_twins_apply_flame_touched : public SpellScript -{ - PrepareSpellScript(spell_eredar_twins_apply_flame_touched); +public: + spell_eredar_twins_apply_touch(uint32 touchSpell) : SpellScript(), _touchSpell(touchSpell) { } bool Validate(SpellInfo const* /*spellInfo*/) override { - return ValidateSpellInfo({ SPELL_FLAME_TOUCHED }); + return ValidateSpellInfo({ _touchSpell }); } void HandleApplyTouch() { if (Player* target = GetHitPlayer()) - target->CastSpell(target, SPELL_FLAME_TOUCHED, true); + target->CastSpell(target, _touchSpell, true); } void Register() override { - AfterHit += SpellHitFn(spell_eredar_twins_apply_flame_touched::HandleApplyTouch); + AfterHit += SpellHitFn(spell_eredar_twins_apply_touch::HandleApplyTouch); } + +private: + uint32 _touchSpell; }; class spell_eredar_twins_handle_touch : public SpellScript @@ -474,8 +400,8 @@ void AddSC_boss_eredar_twins() { RegisterSunwellPlateauCreatureAI(boss_sacrolash); RegisterSunwellPlateauCreatureAI(boss_alythess); - RegisterSpellScript(spell_eredar_twins_apply_dark_touched); - RegisterSpellScript(spell_eredar_twins_apply_flame_touched); + RegisterSpellScriptWithArgs(spell_eredar_twins_apply_touch, "spell_eredar_twins_apply_dark_touched", SPELL_DARK_TOUCHED); + RegisterSpellScriptWithArgs(spell_eredar_twins_apply_touch, "spell_eredar_twins_apply_flame_touched", SPELL_FLAME_TOUCHED); RegisterSpellScript(spell_eredar_twins_handle_touch); RegisterSpellScript(spell_eredar_twins_blaze); new at_sunwell_eredar_twins(); From 28ebd46d15a2000f4dd658980929b6466e3b4f1e Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Mon, 11 Nov 2024 07:32:29 -0300 Subject: [PATCH 038/105] =?UTF-8?q?fix(DB/Creature):=20Fix=20Hexlord=20Mal?= =?UTF-8?q?acrass=20spawn=20position=20and=20remove=20Har=E2=80=A6=20(#205?= =?UTF-8?q?20)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix(DB/Creature): Fix Hexlord Malacrass spawn position and remove Harrison Jones guid script Co-authored-by: sudlud --- .../sql/updates/pending_db_world/rev_1731318072739017900.sql | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731318072739017900.sql diff --git a/data/sql/updates/pending_db_world/rev_1731318072739017900.sql b/data/sql/updates/pending_db_world/rev_1731318072739017900.sql new file mode 100644 index 00000000000000..e79e48023a7b48 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731318072739017900.sql @@ -0,0 +1,5 @@ +-- +UPDATE `creature` SET `ScriptName` = '' WHERE `guid` = 320 AND `id1` = 24358; +DELETE FROM `creature` WHERE `guid` = 89357 AND `id1` = 24239; +INSERT INTO `creature` (`guid`, `id1`, `map`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `ScriptName`, `VerifiedBuild`, `CreateObject`, `Comment`) VALUES +(89357, 24239, 568, 1, 1, 0, 117.363067626953125, 923.568603515625, 33.97257232666015625, 1.588249564170837402, 604800 , 0, 0, 0, 0, 0, "", 50375, 1, NULL); From 40707b5b29008d443de298938da1ae232e136748 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 11 Nov 2024 10:33:25 +0000 Subject: [PATCH 039/105] chore(DB): import pending files Referenced commit(s): 28ebd46d15a2000f4dd658980929b6466e3b4f1e --- .../rev_1731318072739017900.sql => db_world/2024_11_11_02.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731318072739017900.sql => db_world/2024_11_11_02.sql} (93%) diff --git a/data/sql/updates/pending_db_world/rev_1731318072739017900.sql b/data/sql/updates/db_world/2024_11_11_02.sql similarity index 93% rename from data/sql/updates/pending_db_world/rev_1731318072739017900.sql rename to data/sql/updates/db_world/2024_11_11_02.sql index e79e48023a7b48..8c218eb51e3cd1 100644 --- a/data/sql/updates/pending_db_world/rev_1731318072739017900.sql +++ b/data/sql/updates/db_world/2024_11_11_02.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_11_01 -> 2024_11_11_02 -- UPDATE `creature` SET `ScriptName` = '' WHERE `guid` = 320 AND `id1` = 24358; DELETE FROM `creature` WHERE `guid` = 89357 AND `id1` = 24239; From d9b4cc6047012e713ad25e08f2aa8920a2dbe05c Mon Sep 17 00:00:00 2001 From: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> Date: Mon, 11 Nov 2024 14:14:58 -0500 Subject: [PATCH 040/105] fix(DB/Creature): Adjust Harrison Jones's movement type. (#20523) Init. --- data/sql/updates/pending_db_world/harrison-jones-hack.sql | 1 + 1 file changed, 1 insertion(+) create mode 100644 data/sql/updates/pending_db_world/harrison-jones-hack.sql diff --git a/data/sql/updates/pending_db_world/harrison-jones-hack.sql b/data/sql/updates/pending_db_world/harrison-jones-hack.sql new file mode 100644 index 00000000000000..c72efcba47e256 --- /dev/null +++ b/data/sql/updates/pending_db_world/harrison-jones-hack.sql @@ -0,0 +1 @@ +UPDATE `creature` SET `MovementType` = 0 WHERE `guid` = 320 AND `id1` = 24358; From 6cfa6dd4e9aa9f3fb8f51295a609a109df85c2fb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 11 Nov 2024 19:15:54 +0000 Subject: [PATCH 041/105] chore(DB): import pending files Referenced commit(s): d9b4cc6047012e713ad25e08f2aa8920a2dbe05c --- .../harrison-jones-hack.sql => db_world/2024_11_11_03.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/harrison-jones-hack.sql => db_world/2024_11_11_03.sql} (64%) diff --git a/data/sql/updates/pending_db_world/harrison-jones-hack.sql b/data/sql/updates/db_world/2024_11_11_03.sql similarity index 64% rename from data/sql/updates/pending_db_world/harrison-jones-hack.sql rename to data/sql/updates/db_world/2024_11_11_03.sql index c72efcba47e256..b58b94d3559a37 100644 --- a/data/sql/updates/pending_db_world/harrison-jones-hack.sql +++ b/data/sql/updates/db_world/2024_11_11_03.sql @@ -1 +1,2 @@ +-- DB update 2024_11_11_02 -> 2024_11_11_03 UPDATE `creature` SET `MovementType` = 0 WHERE `guid` = 320 AND `id1` = 24358; From 5f7d1d302f83f5b80cbdb2c1319a9ac589a0b78d Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Mon, 11 Nov 2024 20:53:07 +0100 Subject: [PATCH 042/105] fix(Scripts/BoreanTundra): make Escape from the Winterfin Caverns group completable (#20359) Group instead of Area --- src/server/scripts/Northrend/zone_borean_tundra.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/scripts/Northrend/zone_borean_tundra.cpp b/src/server/scripts/Northrend/zone_borean_tundra.cpp index 8798a5691c8bdb..dcc760e74eed4e 100644 --- a/src/server/scripts/Northrend/zone_borean_tundra.cpp +++ b/src/server/scripts/Northrend/zone_borean_tundra.cpp @@ -431,7 +431,7 @@ class npc_lurgglbr : public CreatureScript case 6: if (Player* player = GetPlayerForEscort()) - player->AreaExploredOrEventHappens(QUEST_ESCAPE_WINTERFIN_CAVERNS); + player->GroupEventHappens(QUEST_ESCAPE_WINTERFIN_CAVERNS, me); IntroPhase = 7; IntroTimer = 2500; break; From 8da3b83d745a6535f7244e924665f7f69c56a864 Mon Sep 17 00:00:00 2001 From: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> Date: Mon, 11 Nov 2024 14:53:41 -0500 Subject: [PATCH 043/105] fix(DB/Spell): Link triggered Unstable flask effects to flask aura and proper area. (#20353) Init. --- .../pending_db_world/unstable-flasks.sql | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 data/sql/updates/pending_db_world/unstable-flasks.sql diff --git a/data/sql/updates/pending_db_world/unstable-flasks.sql b/data/sql/updates/pending_db_world/unstable-flasks.sql new file mode 100644 index 00000000000000..55784ac5abc391 --- /dev/null +++ b/data/sql/updates/pending_db_world/unstable-flasks.sql @@ -0,0 +1,29 @@ +DELETE FROM `spell_linked_spell` WHERE `spell_trigger` IN (-40568, -40575, -40572, -40567, -40573, -40576); +INSERT INTO `spell_linked_spell` (`spell_trigger`, `spell_effect`, `type`, `comment`) VALUES +(-40568, -40582, 0, 'Unstable Flask of the Elder'), +(-40575, -40587, 0, 'Unstable Flask of the Soldier'), +(-40572, -40580, 0, 'Unstable Flask of the Beast'), +(-40567, -40577, 0, 'Unstable Flask of the Bandit'), +(-40567, -40579, 0, 'Unstable Flask of the Bandit'), +(-40573, -40586, 0, 'Unstable Flask of the Physician'), +(-40576, -40588, 0, 'Unstable Flask of the Sorcerer'), +(-40576, -40763, 0, 'Unstable Flask of the Sorcerer'); + +DELETE FROM `spell_area` WHERE `spell` IN (40567, 40568, 40572, 40573, 40575, 40576, 40577, 40579, 40580, 40582, 40586, 40587, 40588, 40763); +INSERT INTO `spell_area` (`spell`, `area`, `quest_start`, `quest_end`, `aura_spell`, `racemask`, `gender`, `autocast`, `quest_start_status`, `quest_end_status`) VALUES +(40577, 3522, 0, 0, 40567, 0, 2, 1, 0, 0), +(40577, 3923, 0, 0, 40567, 0, 2, 1, 0, 0), +(40579, 3522, 0, 0, 40567, 0, 2, 1, 0, 0), +(40579, 3923, 0, 0, 40567, 0, 2, 1, 0, 0), +(40580, 3522, 0, 0, 40572, 0, 2, 1, 0, 0), +(40580, 3923, 0, 0, 40572, 0, 2, 1, 0, 0), +(40582, 3522, 0, 0, 40568, 0, 2, 1, 0, 0), +(40582, 3923, 0, 0, 40568, 0, 2, 1, 0, 0), +(40586, 3522, 0, 0, 40573, 0, 2, 1, 0, 0), +(40586, 3923, 0, 0, 40573, 0, 2, 1, 0, 0), +(40587, 3522, 0, 0, 40575, 0, 2, 1, 0, 0), +(40587, 3923, 0, 0, 40575, 0, 2, 1, 0, 0), +(40588, 3522, 0, 0, 40576, 0, 2, 1, 0, 0), +(40588, 3923, 0, 0, 40576, 0, 2, 1, 0, 0), +(40763, 3522, 0, 0, 40576, 0, 2, 1, 0, 0), +(40763, 3923, 0, 0, 40576, 0, 2, 1, 0, 0); From 9dbb8781b5ab1dfa6f43c203470875f63d738806 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 11 Nov 2024 19:54:19 +0000 Subject: [PATCH 044/105] chore(DB): import pending files Referenced commit(s): 5f7d1d302f83f5b80cbdb2c1319a9ac589a0b78d --- .../unstable-flasks.sql => db_world/2024_11_11_04.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/unstable-flasks.sql => db_world/2024_11_11_04.sql} (97%) diff --git a/data/sql/updates/pending_db_world/unstable-flasks.sql b/data/sql/updates/db_world/2024_11_11_04.sql similarity index 97% rename from data/sql/updates/pending_db_world/unstable-flasks.sql rename to data/sql/updates/db_world/2024_11_11_04.sql index 55784ac5abc391..743c183e0886ff 100644 --- a/data/sql/updates/pending_db_world/unstable-flasks.sql +++ b/data/sql/updates/db_world/2024_11_11_04.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_11_03 -> 2024_11_11_04 DELETE FROM `spell_linked_spell` WHERE `spell_trigger` IN (-40568, -40575, -40572, -40567, -40573, -40576); INSERT INTO `spell_linked_spell` (`spell_trigger`, `spell_effect`, `type`, `comment`) VALUES (-40568, -40582, 0, 'Unstable Flask of the Elder'), From 156f63463798ba87c4c4bfc694534a4bc489902a Mon Sep 17 00:00:00 2001 From: Grimdhex <176165533+Grimdhex@users.noreply.github.com> Date: Mon, 11 Nov 2024 20:54:32 +0100 Subject: [PATCH 045/105] fix(Build/Deps): Increase minimal Boost versions and remove old compatibilities (#20287) * fix(Core/Common): remove conditions for unsupported boost versions * fix Cmake version requiert acording to wiki --- deps/boost/CMakeLists.txt | 4 ++-- src/common/Asio/DeadlineTimer.h | 10 +--------- src/common/Asio/IoContext.h | 16 ---------------- src/common/Asio/IpAddress.h | 12 ------------ src/common/Asio/IpNetwork.h | 15 --------------- src/common/Asio/Resolver.h | 11 ----------- src/common/Asio/Strand.h | 13 +------------ 7 files changed, 4 insertions(+), 77 deletions(-) diff --git a/deps/boost/CMakeLists.txt b/deps/boost/CMakeLists.txt index 61334ee2ef07f3..dd41c52a90178f 100644 --- a/deps/boost/CMakeLists.txt +++ b/deps/boost/CMakeLists.txt @@ -26,9 +26,9 @@ include (CheckCXXSourceCompiles) if (WIN32) # On windows the requirements are higher according to the wiki. - set(BOOST_REQUIRED_VERSION 1.74) + set(BOOST_REQUIRED_VERSION 1.78) else() - set(BOOST_REQUIRED_VERSION 1.67) + set(BOOST_REQUIRED_VERSION 1.74) endif() find_package(Boost ${BOOST_REQUIRED_VERSION} REQUIRED system filesystem program_options iostreams regex) diff --git a/src/common/Asio/DeadlineTimer.h b/src/common/Asio/DeadlineTimer.h index b287fcb74fff5f..09e377e6d4594f 100644 --- a/src/common/Asio/DeadlineTimer.h +++ b/src/common/Asio/DeadlineTimer.h @@ -20,15 +20,7 @@ #include -#if BOOST_VERSION >= 107000 -#define BasicDeadlineTimerThirdTemplateArg , boost::asio::io_context::executor_type -#elif BOOST_VERSION >= 106600 -#define BasicDeadlineTimerThirdTemplateArg -#else -#define BasicDeadlineTimerThirdTemplateArg , boost::asio::deadline_timer_service> -#endif - -#define DeadlineTimerBase boost::asio::basic_deadline_timer BasicDeadlineTimerThirdTemplateArg> +#define DeadlineTimerBase boost::asio::basic_deadline_timer, boost::asio::io_context::executor_type> namespace Acore::Asio { diff --git a/src/common/Asio/IoContext.h b/src/common/Asio/IoContext.h index 51ee805b97976d..46dfa8516fec60 100644 --- a/src/common/Asio/IoContext.h +++ b/src/common/Asio/IoContext.h @@ -20,16 +20,10 @@ #include -#if BOOST_VERSION >= 106600 #include #include #define IoContextBaseNamespace boost::asio #define IoContextBase io_context -#else -#include -#define IoContextBaseNamespace boost::asio -#define IoContextBase io_service -#endif namespace Acore::Asio { @@ -45,9 +39,7 @@ namespace Acore::Asio std::size_t run() { return _impl.run(); } void stop() { _impl.stop(); } -#if BOOST_VERSION >= 106600 boost::asio::io_context::executor_type get_executor() noexcept { return _impl.get_executor(); } -#endif private: IoContextBaseNamespace::IoContextBase _impl; @@ -56,21 +48,13 @@ namespace Acore::Asio template inline decltype(auto) post(IoContextBaseNamespace::IoContextBase& ioContext, T&& t) { -#if BOOST_VERSION >= 106600 return boost::asio::post(ioContext, std::forward(t)); -#else - return ioContext.post(std::forward(t)); -#endif } template inline decltype(auto) get_io_context(T&& ioObject) { -#if BOOST_VERSION >= 106600 return ioObject.get_executor().context(); -#else - return ioObject.get_io_service(); -#endif } } diff --git a/src/common/Asio/IpAddress.h b/src/common/Asio/IpAddress.h index f8015abf412851..5739615b79f1db 100644 --- a/src/common/Asio/IpAddress.h +++ b/src/common/Asio/IpAddress.h @@ -23,21 +23,9 @@ namespace Acore::Net { -#if BOOST_VERSION >= 106600 using boost::asio::ip::make_address; using boost::asio::ip::make_address_v4; inline uint32 address_to_uint(boost::asio::ip::address_v4 const& address) { return address.to_uint(); } -#else - inline boost::asio::ip::address make_address(char const* str) { return boost::asio::ip::address::from_string(str); } - inline boost::asio::ip::address make_address(char const* str, boost::system::error_code& ec) { return boost::asio::ip::address::from_string(str, ec); } - inline boost::asio::ip::address make_address(std::string const& str) { return boost::asio::ip::address::from_string(str); } - inline boost::asio::ip::address make_address(std::string const& str, boost::system::error_code& ec) { return boost::asio::ip::address::from_string(str, ec); } - inline boost::asio::ip::address_v4 make_address_v4(char const* str) { return boost::asio::ip::address_v4::from_string(str); } - inline boost::asio::ip::address_v4 make_address_v4(char const* str, boost::system::error_code& ec) { return boost::asio::ip::address_v4::from_string(str, ec); } - inline boost::asio::ip::address_v4 make_address_v4(std::string const& str) { return boost::asio::ip::address_v4::from_string(str); } - inline boost::asio::ip::address_v4 make_address_v4(std::string const& str, boost::system::error_code& ec) { return boost::asio::ip::address_v4::from_string(str, ec); } - inline uint32 address_to_uint(boost::asio::ip::address_v4 const& address) { return address.to_ulong(); } -#endif } #endif // IpAddress_h__ diff --git a/src/common/Asio/IpNetwork.h b/src/common/Asio/IpNetwork.h index 7c8128287544f8..30a71b614f26ac 100644 --- a/src/common/Asio/IpNetwork.h +++ b/src/common/Asio/IpNetwork.h @@ -20,24 +20,16 @@ #include "Define.h" #include "IpAddress.h" -#include - -#if BOOST_VERSION >= 106600 #include #include -#endif namespace Acore::Net { inline bool IsInNetwork(boost::asio::ip::address_v4 const& networkAddress, boost::asio::ip::address_v4 const& mask, boost::asio::ip::address_v4 const& clientAddress) { -#if BOOST_VERSION >= 106600 boost::asio::ip::network_v4 network = boost::asio::ip::make_network_v4(networkAddress, mask); boost::asio::ip::address_v4_range hosts = network.hosts(); return hosts.find(clientAddress) != hosts.end(); -#else - return (clientAddress.to_ulong() & mask.to_ulong()) == (networkAddress.to_ulong() & mask.to_ulong()); -#endif } inline boost::asio::ip::address_v4 GetDefaultNetmaskV4(boost::asio::ip::address_v4 const& networkAddress) @@ -59,16 +51,9 @@ namespace Acore::Net inline bool IsInNetwork(boost::asio::ip::address_v6 const& networkAddress, uint16 prefixLength, boost::asio::ip::address_v6 const& clientAddress) { -#if BOOST_VERSION >= 106600 boost::asio::ip::network_v6 network = boost::asio::ip::make_network_v6(networkAddress, prefixLength); boost::asio::ip::address_v6_range hosts = network.hosts(); return hosts.find(clientAddress) != hosts.end(); -#else - (void)networkAddress; - (void)prefixLength; - (void)clientAddress; - return false; -#endif } } diff --git a/src/common/Asio/Resolver.h b/src/common/Asio/Resolver.h index a49b8fcda52794..92033281de85a8 100644 --- a/src/common/Asio/Resolver.h +++ b/src/common/Asio/Resolver.h @@ -35,23 +35,12 @@ namespace Acore::Asio Optional Resolve(boost::asio::ip::tcp const& protocol, std::string const& host, std::string const& service) { boost::system::error_code ec; -#if BOOST_VERSION >= 106600 boost::asio::ip::resolver_base::flags flagsResolver = boost::asio::ip::resolver_base::all_matching; boost::asio::ip::tcp::resolver::results_type results = _impl.resolve(protocol, host, service, flagsResolver, ec); if (results.begin() == results.end() || ec) return {}; return results.begin()->endpoint(); -#else - boost::asio::ip::resolver_query_base::flags flagsQuery = boost::asio::ip::tcp::resolver::query::all_matching; - boost::asio::ip::tcp::resolver::query query(std::move(protocol), std::move(host), std::move(service), flagsQuery); - boost::asio::ip::tcp::resolver::iterator itr = _impl.resolve(query, ec); - boost::asio::ip::tcp::resolver::iterator end; - if (itr == end || ec) - return {}; - - return itr->endpoint(); -#endif } private: diff --git a/src/common/Asio/Strand.h b/src/common/Asio/Strand.h index 4ac36e67d0341b..e580e4ae3797e3 100644 --- a/src/common/Asio/Strand.h +++ b/src/common/Asio/Strand.h @@ -19,11 +19,8 @@ #define Strand_h__ #include "IoContext.h" -#include - -#if BOOST_VERSION >= 106600 #include -#endif +#include namespace Acore::Asio { @@ -36,15 +33,7 @@ namespace Acore::Asio Strand(IoContext& ioContext) : IoContextBaseNamespace::IoContextBase::strand(ioContext) { } }; -#if BOOST_VERSION >= 106600 using boost::asio::bind_executor; -#else - template - inline decltype(auto) bind_executor(Strand& strand, T&& t) - { - return strand.wrap(std::forward(t)); - } -#endif } #endif // Strand_h__ From 1b556c48a17bed09ac7a746f9a414ae82c401467 Mon Sep 17 00:00:00 2001 From: sudlud Date: Tue, 12 Nov 2024 12:20:17 +0100 Subject: [PATCH 046/105] fix(DB/Gameobject): Sniffed Values for 'Zul' Aman Misc' spawns (#20526) * fix(DB/Gameobject): Sniffed Values for 'Zul' Aman Misc' spawns * drop spawn relevant for Zalazane's Fall only --- .../rev_1731354714210375200.sql | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731354714210375200.sql diff --git a/data/sql/updates/pending_db_world/rev_1731354714210375200.sql b/data/sql/updates/pending_db_world/rev_1731354714210375200.sql new file mode 100644 index 00000000000000..d72de6d766abee --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731354714210375200.sql @@ -0,0 +1,21 @@ +-- Update gameobject 'Zul' Aman Misc' with sniffed values +-- updated spawns +DELETE FROM `gameobject` WHERE (`id` IN (186733, 187359)) +AND (`guid` IN (12647, 20584)); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`, `ScriptName`, `VerifiedBuild`, `Comment`) VALUES +-- The Map of Zul'Aman +(12647, 186733, 568, 0, 0, 1, 1, -150.912109375, 1343.1505126953125, 49.78499984741210937, 5.253442287445068359, 0, 0, -0.49242305755615234, 0.870355963706970214, 7200, 255, 1, "", 49345, NULL), +-- Strange Gong +(20584, 187359, 568, 0, 0, 1, 1, 134.0087890625, 1642.7974853515625, 42.08407974243164062, 3.141592741012573242, 0, 0, -1, 0, 7200, 255, 1, "", 49345, NULL); + +-- new spawns +DELETE FROM `gameobject` WHERE (`id` IN (186430, 186748, 186865)) +AND (`guid` BETWEEN 381 AND 384); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`, `ScriptName`, `VerifiedBuild`, `Comment`) VALUES +-- Zungam's Ball and Chain +(381, 186430, 568, 0, 0, 1, 1, 251.4287109375, 996.85614013671875, 10.91197776794433593, 2.111847877502441406, 0, 0, 0.870355606079101562, 0.492423713207244873, 7200, 255, 1, "", 49345, NULL), +-- Harkor's Brew Keg +(382, 186748, 568, 0, 0, 1, 1, 99.88021087646484375, 694.3485107421875, 45.11137771606445312, 0.837757468223571777, 0, 0, 0.406736373901367187, 0.913545548915863037, 7200, 255, 1, "", 53788, NULL), +-- Amani Drum +(383, 186865, 568, 0, 0, 1, 1, 148.782989501953125, 707.01702880859375, 45.11137771606445312, 3.071766138076782226, 0, 0, 0.999390602111816406, 0.034906134009361267, 7200, 255, 1, "", 50375, NULL), +(384, 186865, 568, 0, 0, 1, 1, 92.7647552490234375, 707.51788330078125, 45.11137771606445312, 0.017452461645007133, 0, 0, 0.008726119995117187, 0.999961912631988525, 7200, 255, 1, "", 53788, NULL); From 63f1bd00a3719d975947b10073b11fa1dc8a85cb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 12 Nov 2024 11:21:14 +0000 Subject: [PATCH 047/105] chore(DB): import pending files Referenced commit(s): 1b556c48a17bed09ac7a746f9a414ae82c401467 --- .../rev_1731354714210375200.sql => db_world/2024_11_12_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731354714210375200.sql => db_world/2024_11_12_00.sql} (97%) diff --git a/data/sql/updates/pending_db_world/rev_1731354714210375200.sql b/data/sql/updates/db_world/2024_11_12_00.sql similarity index 97% rename from data/sql/updates/pending_db_world/rev_1731354714210375200.sql rename to data/sql/updates/db_world/2024_11_12_00.sql index d72de6d766abee..9cf4fd36e64c6f 100644 --- a/data/sql/updates/pending_db_world/rev_1731354714210375200.sql +++ b/data/sql/updates/db_world/2024_11_12_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_11_04 -> 2024_11_12_00 -- Update gameobject 'Zul' Aman Misc' with sniffed values -- updated spawns DELETE FROM `gameobject` WHERE (`id` IN (186733, 187359)) From e80b0ce8b80c98599f12d272a5f089b6866d25e4 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Tue, 12 Nov 2024 11:50:09 -0300 Subject: [PATCH 048/105] fix(Scripts/ZulAman): Set Akilzon encounter in progress when engaged (#20531) --- src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp index f2e1c70f1eb171..75d7722d20a00b 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp @@ -85,6 +85,8 @@ class boss_akilzon : public CreatureScript void JustEngagedWith(Unit* /*who*/) override { + _JustEngagedWith(); + ScheduleTimedEvent(10s, 20s, [&]{ Unit* target = SelectTarget(SelectTargetMethod::Random, 1); if (!target) From 3565e4a9eba5475f7377f694838000c8837b9785 Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Tue, 12 Nov 2024 16:15:27 +0100 Subject: [PATCH 049/105] feat(Core/WorldState): improved WorldState scripting (#20141) * implement world state script based on https://github.com/cmangos/mangos-wotlk/commit/0b87ca9d9edf2d4752a3c0f8e9cf85c6689ca861 Co-authored-by: killerwife * refactor to use onleave and onenter instead of spell_area allows players to right click remove adal's buff * add MapMgr.h * refactor: use condition enum instead of uint32, prefix WORLD_STATE where needed * remove lock from WorldState::Update sWorldState->Update() is only called from World::Update * remove unsafe SmartAI action of setWorldState --------- Co-authored-by: killerwife --- .../rev_1727679643827269473.sql | 149 +++++++++ .../game/AI/SmartScripts/SmartScript.cpp | 6 + .../game/AI/SmartScripts/SmartScriptMgr.cpp | 2 + .../game/AI/SmartScripts/SmartScriptMgr.h | 9 +- src/server/game/Conditions/ConditionMgr.cpp | 9 + src/server/game/Conditions/ConditionMgr.h | 4 +- src/server/game/Entities/Player/Player.cpp | 2 + .../game/Entities/Player/PlayerUpdates.cpp | 3 + src/server/game/Globals/ObjectMgr.h | 2 + src/server/game/Scripting/MapScripts.cpp | 6 +- src/server/game/Server/WorldSession.cpp | 2 + .../game/Spells/SpellInfoCorrections.cpp | 12 - src/server/game/World/World.cpp | 6 + src/server/game/World/WorldState.cpp | 293 ++++++++++++++++++ src/server/game/World/WorldState.h | 95 ++++++ .../Outland/zone_hellfire_peninsula.cpp | 22 ++ src/server/scripts/Spells/spell_generic.cpp | 21 -- src/server/scripts/World/transport_zeppelin.h | 68 ++++ .../scripts/World/transport_zeppelins.cpp | 109 +++++++ .../scripts/World/world_script_loader.cpp | 2 + 20 files changed, 785 insertions(+), 37 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1727679643827269473.sql create mode 100644 src/server/game/World/WorldState.cpp create mode 100644 src/server/game/World/WorldState.h create mode 100644 src/server/scripts/World/transport_zeppelin.h create mode 100644 src/server/scripts/World/transport_zeppelins.cpp diff --git a/data/sql/updates/pending_db_world/rev_1727679643827269473.sql b/data/sql/updates/pending_db_world/rev_1727679643827269473.sql new file mode 100644 index 00000000000000..8e3d2ab45a8145 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1727679643827269473.sql @@ -0,0 +1,149 @@ +-- +DELETE FROM `spell_script_names` WHERE `spell_id`=39953 AND `ScriptName`='spell_gen_adals_song_of_battle'; +-- A'dal +UPDATE `smart_scripts` SET `link` = 5 WHERE (`entryorguid` = 18481) AND (`source_type` = 0) AND (`id` = 4); +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 18481) AND (`source_type` = 0) AND (`id` = 5); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18481, 0, 5, 0, 61, 0, 100, 512, 0, 0, 0, 0, 0, 0, 237, 39953, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'A Dal - On Quest Reward 11007 - Run World State Script Event 39953'); + +-- Magtheridon's Head +UPDATE `gameobject_template` SET `ScriptName` = 'go_magtheridons_head' WHERE (`entry` = 184640); + +-- Trollbane +UPDATE `smart_scripts` SET `link` = 4 WHERE (`entryorguid` = 16819) AND (`source_type` = 0) AND (`id` = 2); +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 16819) AND (`source_type` = 0) AND (`id` = 4); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(16819, 0, 4, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 50, 184640, 7200, 0, 0, 0, 0, 8, 0, 0, 0, 0, -732.28, 2670.99, 94.5875, -0.541051, 'Force Commander Danath Trollbane - On Quest \'The Fall of Magtheridon\' Finished - Summon Gameobject \'Magtheridon\'s Head\' Alliance'); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 22) AND (`SourceGroup` = 5) AND (`SourceEntry` = 16819); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(22, 5, 16819, 3, 0, 103, 0, 39911, 0, 0, 1, 0, 0, '', 'if Gameobject \'Magtheridon\'s Head\' Alliance is not already spawned'); + +-- Nazgrel +UPDATE `smart_scripts` SET `link` = 3 WHERE (`entryorguid` = 3230) AND (`source_type` = 0) AND (`id` = 1); +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 3230) AND (`source_type` = 0) AND (`id` = 3); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(3230, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 50, 184640, 7200, 0, 0, 0, 0, 8, 0, 0, 0, 0, 143.417, 2673.36, 85.3014, 3.01941, 'Nazgrel - On Quest \'The Fall of Magtheridon\' Finished - Summon Gameobject \'Magtheridon\'s Head\' Horde'); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 22) AND (`SourceGroup` = 4) AND (`SourceEntry` = 3230); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(22, 4, 3230, 3, 0, 103, 0, 39913, 0, 0, 1, 0, 0, '', 'if Gameobject \'Magtheridon\'s Head\' Horde is not already spawned'); + +-- Zeppelin transports +SET @RADIUS:=24; -- radius unknown +-- arrival events, play zeppelin horn +DELETE FROM `event_scripts` WHERE `command` = 16 and `id` IN (15312, 15314, 15318, 15320, 15322, 15324, 15430, 15431, 19126, 19127, 19137, 19139, 21868, 21870); +INSERT INTO `event_scripts` (`id`, `delay`, `command`, `datalong`, `datalong2`, `dataint`, `x`, `y`, `z`, `o`) VALUES +(15312, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(15314, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(15318, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(15320, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(15322, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(15324, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(15430, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(15431, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(19126, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(19127, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(19137, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(19139, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(21868, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0), +(21870, 0, 16, 11804, 4, @RADIUS, 0.0, 0.0, 0.0, 0.0); + +-- The Iron Eagle - Grom'Gol to Orgrimmar +UPDATE `gameobject_template` SET `ScriptName` = 'go_transport_the_iron_eagle' WHERE (`entry` = 175080); + +-- Snurk Bucksquick Master Orgrimmar The Iron Eagle +DELETE FROM `gossip_menu_option` WHERE `MenuID` = 3841; +INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(3841, 0, 0, 'Where is the zeppelin now?', 22086, 1, 1, 8764, 0, 0, 0, '', 0, 0); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 15) AND (`SourceGroup` = 3841) AND (`SourceEntry` = 0); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 3841, 0, 0, 0, 103, 0, 175080, 15322, 0, 1, 0, 0, '', 'The zeppelin should not have just arrived at Orgrimmar'); + +-- Zez'raz Master Grom'gol The Iron Eagle +DELETE FROM `gossip_menu_option` WHERE `MenuID` = 2441; +INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(2441, 0, 0, 'Where is the zeppelin now?', 22086, 1, 1, 8764, 0, 0, 0, '', 0, 0); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 15) AND (`SourceGroup` = 2441); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 2441, 0, 0, 0, 103, 0, 175080, 15324, 0, 1, 0, 0, '', 'The zeppelin should not have just arrived at Grom\'gol'); + +-- Krixx Engineer Orgrimmar The Iron Eagle, The Thundercaller +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 14) AND (`SourceGroup` = 8764); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(14, 8764, 11167, 0, 0, 103, 0, 175080, 15324, 0, 0, 0, 0, '', 'The zeppelin should have just arrived at Grom\'gol'), +(14, 8764, 11169, 0, 1, 103, 0, 175080, 15322, 0, 0, 0, 0, '', 'The zeppelin should have just arrived at Orgrimmar'), +(14, 8764, 11170, 0, 2, 103, 0, 175080, 15323, 0, 0, 0, 0, '', 'The zeppelin should have just departed from Orgrimmar'), +(14, 8764, 11172, 0, 3, 103, 0, 175080, 15325, 0, 0, 0, 0, '', 'The zeppelin should have just departed from Grom\'gol'), +(14, 8764, 11163, 0, 4, 103, 0, 175080, 0, 0, 0, 0, 0, '', 'I\'m not sure where the zeppelin is right now, actually...'); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 14) AND (`SourceGroup` = 8765); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(14, 8765, 11165, 0, 0, 103, 0, 164871, 15318, 0, 0, 0, 0, '', 'The zeppelin should have just arrived at Orgrimmar'), +(14, 8765, 11173, 0, 1, 103, 0, 164871, 15320, 0, 0, 0, 0, '', 'The zeppelin should have just arrived at Undercity'), +(14, 8765, 11174, 0, 2, 103, 0, 164871, 15319, 0, 0, 0, 0, '', 'The zeppelin should have just departed from Orgrimmar'), +(14, 8765, 11175, 0, 3, 103, 0, 164871, 15321, 0, 0, 0, 0, '', 'The zeppelin should have just departed from Undercity'), +(14, 8765, 11163, 0, 4, 103, 0, 164871, 0, 0, 0, 0, 0, '', 'I\'m not sure where the zeppelin is right now, actually...'); + +-- The Thundercaller - Undercity to Orgrimmar +UPDATE `gameobject_template` SET `ScriptName` = 'go_transport_the_thundercaller' WHERE (`entry` = 164871); + +-- Frezza Master Orgrimmar The Thundercaller +DELETE FROM `gossip_menu_option` WHERE `MenuID` = 1969; +INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(1969, 0, 0, 'Where is the zeppelin now?', 22086, 1, 1, 8765, 0, 0, 0, '', 0, 0); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 15) AND (`SourceGroup` = 1969) AND (`SourceEntry` = 0); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 1969, 0, 0, 0, 103, 0, 164871, 15318, 0, 1, 0, 0, '', 'The zeppelin should not have just arrived at Orgrimmar'); + +-- Zapetta Master Undercity The Thundercaller +DELETE FROM `gossip_menu_option` WHERE `MenuID` = 1971; +INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(1971, 0, 0, 'Where is the zeppelin now?', 22086, 1, 1, 8765, 0, 0, 0, '', 0, 0); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 15) AND (`SourceGroup` = 1971) AND (`SourceEntry` = 0); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 1971, 0, 0, 0, 103, 0, 164871, 15320, 0, 1, 0, 0, '', 'The zeppelin should not have just arrived at Undercity'); +DELETE FROM `creature_text` WHERE (`CreatureID` = 9566) AND (`GroupID` = 1); +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(9566, 1, 0, 'There goes the zeppelin to Orgrimmar. I hope there\'s no explosions this time.', 12, 0, 100, 0, 0, 0, 22080, 0, 'Zapetta - Departure'); +UPDATE `creature_text` SET `comment` = 'Zapetta - Arrival' WHERE (`CreatureID` = 9566) AND (`GroupID` = 0); + +-- The Purple Princess - Grom'Gol to Undercity +UPDATE `gameobject_template` SET `ScriptName` = 'go_transport_the_purple_princess' WHERE (`entry` = 176495); + +-- Hin Denburg Master Undercity The Purple Princess +DELETE FROM `gossip_menu` WHERE `MenuID` = 8766 AND `TextID` IN (11179, 11182); +INSERT INTO `gossip_menu` (`MenuID`, `TextID`) VALUES +(8766, 11179), +(8766, 11182); +DELETE FROM `gossip_menu_option` WHERE `MenuID` = 2101; +INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(2101, 0, 0, 'Where is the zeppelin now?', 22086, 1, 1, 8766, 0, 0, 0, '', 0, 0); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 15) AND (`SourceGroup` = 2101) AND (`SourceEntry` = 0); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 2101, 0, 0, 0, 103, 0, 176495, 15312, 0, 1, 0, 0, '', 'The zeppelin should not have just arrived at Undercity'); + +-- Squibby Overspeck Master Grom'gol The Purple Princess +DELETE FROM `gossip_menu_option` WHERE `MenuID` = 3842; +INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(3842, 0, 0, 'Where is the zeppelin now?', 22086, 1, 1, 8766, 0, 0, 0, '', 0, 0); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 15) AND (`SourceGroup` = 3842) AND (`SourceEntry` = 0) AND (`SourceId` = 0); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 3842, 0, 0, 0, 103, 0, 176495, 15314, 0, 1, 0, 0, '', 'The zeppelin should not have just arrived at Grom\'gol'); + +-- Kraxx Engineer Undercity The Thundercaller, The Purple Princess +DELETE FROM `gossip_menu_option` WHERE `MenuID` = 8786; +INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES +(8786, 0, 0, 'Where is the zeppelin to Orgrimmar right now?', 22185, 1, 1, 8765, 0, 0, 0, '', 0, 0), +(8786, 1, 0, 'Where is the zeppelin to Grom\'gol right now?', 22199, 1, 1, 8766, 0, 0, 0, '', 0, 0); +DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 14) AND (`SourceGroup` = 8766); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(14, 8766, 11179, 0, 0, 103, 0, 176495, 15312, 0, 0, 0, 0, '', 'The zeppelin should have just arrived at Undercity'), +(14, 8766, 11180, 0, 1, 103, 0, 176495, 15314, 0, 0, 0, 0, '', 'The zeppelin should have just arrived at Grom\'gol'), +(14, 8766, 11182, 0, 2, 103, 0, 176495, 15313, 0, 0, 0, 0, '', 'The zeppelin should have just departed from Undercity'), +(14, 8766, 11181, 0, 3, 103, 0, 176495, 15315, 0, 0, 0, 0, '', 'The zeppelin should have just departed from Grom\'gol'), +(14, 8766, 11163, 0, 4, 103, 0, 176495, 0, 0, 0, 0, 0, '', 'I\'m not sure where the zeppelin is right now, actually...'); + +-- I\'m not sure where the zeppelin is right now, actually... +DELETE FROM `gossip_menu` WHERE (`MenuID` IN (8764, 8765, 8766)) and `TextID` = 11163; +INSERT INTO `gossip_menu` (`MenuID`, `TextID`) VALUES +(8764, 11163), +(8765, 11163), +(8766, 11163); diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index 4605b9fba8e947..f2c8412c333a2d 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -35,6 +35,7 @@ #include "SmartAI.h" #include "SpellMgr.h" #include "Vehicle.h" +#include "WorldState.h" /// @todo: this import is not necessary for compilation and marked as unused by the IDE // however, for some reasons removing it would cause a damn linking issue @@ -3269,6 +3270,11 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u break; } + case SMART_ACTION_WORLD_SCRIPT: + { + sWorldState->HandleExternalEvent(static_cast(e.action.worldStateScript.eventId), e.action.worldStateScript.param); + break; + } default: LOG_ERROR("sql.sql", "SmartScript::ProcessAction: Entry {} SourceType {}, Event {}, Unhandled Action type {}", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType()); break; diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp index 69e8e5d743d261..b309f469685726 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp @@ -777,6 +777,7 @@ bool SmartAIMgr::CheckUnusedActionParams(SmartScriptHolder const& e) case SMART_ACTION_MOVEMENT_STOP: return NO_PARAMS; case SMART_ACTION_MOVEMENT_PAUSE: return sizeof(SmartAction::move); case SMART_ACTION_MOVEMENT_RESUME: return sizeof(SmartAction::move); + case SMART_ACTION_WORLD_SCRIPT: return sizeof(SmartAction::worldStateScript); default: LOG_WARN("sql.sql", "SmartAIMgr: entryorguid {} source_type {} id {} action_type {} is using an action with no unused params specified in SmartAIMgr::CheckUnusedActionParams(), please report this.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType()); @@ -1960,6 +1961,7 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e) case SMART_ACTION_MOVEMENT_STOP: case SMART_ACTION_MOVEMENT_PAUSE: case SMART_ACTION_MOVEMENT_RESUME: + case SMART_ACTION_WORLD_SCRIPT: break; default: LOG_ERROR("sql.sql", "SmartAIMgr: Not handled action_type({}), event_type({}), Entry {} SourceType {} Event {}, skipped.", e.GetActionType(), e.GetEventType(), e.entryOrGuid, e.GetScriptType(), e.event_id); diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.h b/src/server/game/AI/SmartScripts/SmartScriptMgr.h index 73212b424db44a..b713054d69d341 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.h +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.h @@ -727,8 +727,9 @@ enum SMART_ACTION SMART_ACTION_MOVEMENT_STOP = 234, // SMART_ACTION_MOVEMENT_PAUSE = 235, // timer SMART_ACTION_MOVEMENT_RESUME = 236, // timerOverride + SMART_ACTION_WORLD_SCRIPT = 237, // eventId, param - SMART_ACTION_AC_END = 237, // placeholder + SMART_ACTION_AC_END = 238, // placeholder }; enum class SmartActionSummonCreatureFlags @@ -1472,6 +1473,12 @@ struct SmartAction { uint32 timer; } move; + + struct + { + uint32 eventId; + uint32 param; + } worldStateScript; //! Note for any new future actions //! All parameters must have type uint32 diff --git a/src/server/game/Conditions/ConditionMgr.cpp b/src/server/game/Conditions/ConditionMgr.cpp index 805fcd06d08402..91e2c1a964e9c7 100644 --- a/src/server/game/Conditions/ConditionMgr.cpp +++ b/src/server/game/Conditions/ConditionMgr.cpp @@ -28,6 +28,7 @@ #include "Spell.h" #include "SpellAuras.h" #include "SpellMgr.h" +#include "WorldState.h" // Checks if object meets the condition // Can have CONDITION_SOURCE_TYPE_NONE && !mReferenceId if called from a special event (ie: eventAI) @@ -570,6 +571,11 @@ bool Condition::Meets(ConditionSourceInfo& sourceInfo) condMeets = unit->IsCharmed(); break; } + case CONDITION_WORLD_SCRIPT: + { + condMeets = sWorldState->IsConditionFulfilled(static_cast(ConditionValue1), static_cast(ConditionValue2)); + break; + } default: condMeets = false; break; @@ -770,6 +776,9 @@ uint32 Condition::GetSearcherTypeMaskForCondition() case CONDITION_CHARMED: mask |= GRID_MAP_TYPE_MASK_CREATURE | GRID_MAP_TYPE_MASK_PLAYER; break; + case CONDITION_WORLD_SCRIPT: + mask |= GRID_MAP_TYPE_MASK_ALL; + break; default: ASSERT(false && "Condition::GetSearcherTypeMaskForCondition - missing condition handling!"); break; diff --git a/src/server/game/Conditions/ConditionMgr.h b/src/server/game/Conditions/ConditionMgr.h index 49620aa3fdfec1..1540fd903a6309 100644 --- a/src/server/game/Conditions/ConditionMgr.h +++ b/src/server/game/Conditions/ConditionMgr.h @@ -86,7 +86,9 @@ enum ConditionTypes CONDITION_AC_START = 100, CONDITION_QUEST_SATISFY_EXCLUSIVE = 101, // quest_id 0 0 true if satisfied exclusive group CONDITION_HAS_AURA_TYPE = 102, // aura_type 0 0 true if has aura type - CONDITION_AC_END = 103 // placeholder + CONDITION_WORLD_SCRIPT = 103, // conditionId state 0 true if WorldState::IsConditionFulfilled returns true + + CONDITION_AC_END = 104 // placeholder }; /*! Documentation on implementing a new ConditionSourceType: diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index d534540111e998..d757f1a1346286 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -83,6 +83,7 @@ #include "World.h" #include "WorldPacket.h" #include "WorldSession.h" +#include "WorldState.h" #include /// @todo: this import is not necessary for compilation and marked as unused by the IDE @@ -1722,6 +1723,7 @@ void Player::RemoveFromWorld() m_session->DoLootRelease(lguid); sOutdoorPvPMgr->HandlePlayerLeaveZone(this, m_zoneUpdateId); sBattlefieldMgr->HandlePlayerLeaveZone(this, m_zoneUpdateId); + sWorldState->HandlePlayerLeaveZone(this, static_cast(m_zoneUpdateId)); } // Remove items from world before self - player must be found in Item::RemoveFromObjectUpdate diff --git a/src/server/game/Entities/Player/PlayerUpdates.cpp b/src/server/game/Entities/Player/PlayerUpdates.cpp index 5dcf409faf3af3..f03de45c755b7b 100644 --- a/src/server/game/Entities/Player/PlayerUpdates.cpp +++ b/src/server/game/Entities/Player/PlayerUpdates.cpp @@ -38,6 +38,7 @@ #include "Vehicle.h" #include "Weather.h" #include "WeatherMgr.h" +#include "WorldState.h" #include "WorldStatePackets.h" /// @todo: this import is not necessary for compilation and marked as unused by the IDE @@ -1215,6 +1216,8 @@ void Player::UpdateZone(uint32 newZone, uint32 newArea) { sOutdoorPvPMgr->HandlePlayerLeaveZone(this, m_zoneUpdateId); sOutdoorPvPMgr->HandlePlayerEnterZone(this, newZone); + sWorldState->HandlePlayerLeaveZone(this, static_cast(m_zoneUpdateId)); + sWorldState->HandlePlayerEnterZone(this, static_cast(newZone)); sBattlefieldMgr->HandlePlayerLeaveZone(this, m_zoneUpdateId); sBattlefieldMgr->HandlePlayerEnterZone(this, newZone); SendInitWorldStates(newZone, diff --git a/src/server/game/Globals/ObjectMgr.h b/src/server/game/Globals/ObjectMgr.h index 16be17fcf77b06..8c25ade400b6c6 100644 --- a/src/server/game/Globals/ObjectMgr.h +++ b/src/server/game/Globals/ObjectMgr.h @@ -180,6 +180,7 @@ enum eScriptFlags // Playsound flags SF_PLAYSOUND_TARGET_PLAYER = 0x1, SF_PLAYSOUND_DISTANCE_SOUND = 0x2, + SF_PLAYSOUND_DISTANCE_RADIUS = 0x4, // Orientation flags SF_ORIENTATION_FACE_TARGET = 0x1, @@ -307,6 +308,7 @@ struct ScriptInfo { uint32 SoundID; // datalong uint32 Flags; // datalong2 + int32 Radius; // dataint } Playsound; struct // SCRIPT_COMMAND_CREATE_ITEM (17) diff --git a/src/server/game/Scripting/MapScripts.cpp b/src/server/game/Scripting/MapScripts.cpp index ebf2d3daa2d415..9cbc20f213d77c 100644 --- a/src/server/game/Scripting/MapScripts.cpp +++ b/src/server/game/Scripting/MapScripts.cpp @@ -730,8 +730,10 @@ void Map::ScriptsProcess() break; } - // Playsound.Flags bitmask: 0/2=without/with distance dependent - if (step.script->Playsound.Flags & SF_PLAYSOUND_DISTANCE_SOUND) + // Playsound.Flags bitmask: 0/2/4=without/with distance dependent/radius + if (step.script->Playsound.Flags & SF_PLAYSOUND_DISTANCE_RADIUS) + object->PlayRadiusSound(step.script->Playsound.SoundID, step.script->Playsound.Radius); + else if (step.script->Playsound.Flags & SF_PLAYSOUND_DISTANCE_SOUND) object->PlayDistanceSound(step.script->Playsound.SoundID, player); else object->PlayDirectSound(step.script->Playsound.SoundID, player); diff --git a/src/server/game/Server/WorldSession.cpp b/src/server/game/Server/WorldSession.cpp index 14182c9ec596e1..769985848b3192 100644 --- a/src/server/game/Server/WorldSession.cpp +++ b/src/server/game/Server/WorldSession.cpp @@ -49,6 +49,7 @@ #include "World.h" #include "WorldPacket.h" #include "WorldSocket.h" +#include "WorldState.h" #include #include "BanMgr.h" @@ -617,6 +618,7 @@ void WorldSession::LogoutPlayer(bool save) _player->RepopAtGraveyard(); sOutdoorPvPMgr->HandlePlayerLeaveZone(_player, _player->GetZoneId()); + sWorldState->HandlePlayerLeaveZone(_player, static_cast(_player->GetZoneId())); // pussywizard: remove from battleground queues on logout for (int i = 0; i < PLAYER_MAX_BATTLEGROUND_QUEUES; ++i) diff --git a/src/server/game/Spells/SpellInfoCorrections.cpp b/src/server/game/Spells/SpellInfoCorrections.cpp index 6863984ceaf3b8..36015f5cf07aed 100644 --- a/src/server/game/Spells/SpellInfoCorrections.cpp +++ b/src/server/game/Spells/SpellInfoCorrections.cpp @@ -1389,18 +1389,6 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->RangeEntry = sSpellRangeStore.LookupEntry(13); // 50000yd }); - // A'dal's Song of Battle - ApplySpellFix({ 39953 }, [](SpellInfo* spellInfo) - { - spellInfo->Effects[EFFECT_0].TargetA = SpellImplicitTargetInfo(TARGET_SRC_CASTER); - spellInfo->Effects[EFFECT_1].TargetA = SpellImplicitTargetInfo(TARGET_SRC_CASTER); - spellInfo->Effects[EFFECT_2].TargetA = SpellImplicitTargetInfo(TARGET_SRC_CASTER); - spellInfo->Effects[EFFECT_0].TargetB = SpellImplicitTargetInfo(TARGET_UNIT_SRC_AREA_ALLY); - spellInfo->Effects[EFFECT_1].TargetB = SpellImplicitTargetInfo(TARGET_UNIT_SRC_AREA_ALLY); - spellInfo->Effects[EFFECT_2].TargetB = SpellImplicitTargetInfo(TARGET_UNIT_SRC_AREA_ALLY); - spellInfo->DurationEntry = sSpellDurationStore.LookupEntry(367); // 2 Hours - }); - ApplySpellFix({ 57607, // WintergraspCatapult - Spell Plague Barrel - EffectRadiusIndex 57619, // WintergraspDemolisher - Spell Hourl Boulder - EffectRadiusIndex diff --git a/src/server/game/World/World.cpp b/src/server/game/World/World.cpp index 01295f5698c8c2..fb910444ec49ba 100644 --- a/src/server/game/World/World.cpp +++ b/src/server/game/World/World.cpp @@ -92,6 +92,7 @@ #include "WhoListCacheMgr.h" #include "WorldPacket.h" #include "WorldSession.h" +#include "WorldState.h" #include #include @@ -2411,6 +2412,11 @@ void World::Update(uint32 diff) sOutdoorPvPMgr->Update(diff); } + { + METRIC_TIMER("world_update_time", METRIC_TAG("type", "Update worldstate")); + sWorldState->Update(diff); + } + { METRIC_TIMER("world_update_time", METRIC_TAG("type", "Update battlefields")); sBattlefieldMgr->Update(diff); diff --git a/src/server/game/World/WorldState.cpp b/src/server/game/World/WorldState.cpp new file mode 100644 index 00000000000000..174e468f4f3214 --- /dev/null +++ b/src/server/game/World/WorldState.cpp @@ -0,0 +1,293 @@ +/* + * This file is part of the AzerothCore Project. See AUTHORS file for Copyright information + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by the + * Free Software Foundation; either version 3 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 Affero 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 "MapMgr.h" +#include "Player.h" +#include "SharedDefines.h" +#include "WorldState.h" + +WorldState* WorldState::instance() +{ + static WorldState instance; + return &instance; +} + +WorldState::WorldState() : _isMagtheridonHeadSpawnedHorde(false), _isMagtheridonHeadSpawnedAlliance(false) +{ + _transportStates[WORLD_STATE_CONDITION_THE_IRON_EAGLE] = WORLD_STATE_CONDITION_STATE_NONE; + _transportStates[WORLD_STATE_CONDITION_THE_PURPLE_PRINCESS] = WORLD_STATE_CONDITION_STATE_NONE; + _transportStates[WORLD_STATE_CONDITION_THE_THUNDERCALLER] = WORLD_STATE_CONDITION_STATE_NONE; +} + +WorldState::~WorldState() +{ +} + +bool WorldState::IsConditionFulfilled(WorldStateCondition conditionId, WorldStateConditionState state) const +{ + switch (conditionId) + { + case WORLD_STATE_CONDITION_TROLLBANES_COMMAND: + return _isMagtheridonHeadSpawnedAlliance; + case WORLD_STATE_CONDITION_NAZGRELS_FAVOR: + return _isMagtheridonHeadSpawnedHorde; + case WORLD_STATE_CONDITION_THE_IRON_EAGLE: + case WORLD_STATE_CONDITION_THE_PURPLE_PRINCESS: + case WORLD_STATE_CONDITION_THE_THUNDERCALLER: + return _transportStates.at(conditionId) == state; + default: + LOG_ERROR("scripts", "WorldState::IsConditionFulfilled: Unhandled WorldStateCondition {}", conditionId); + return false; + } +} + +void WorldState::HandleConditionStateChange(WorldStateCondition conditionId, WorldStateConditionState state) +{ + _transportStates[conditionId] = state; +} + +void WorldState::HandleExternalEvent(WorldStateEvent eventId, uint32 param) +{ + std::lock_guard guard(_mutex); + switch (eventId) + { + case WORLD_STATE_CUSTOM_EVENT_ON_ADALS_SONG_OF_BATTLE: + if (!_adalSongOfBattleTimer) + { + _adalSongOfBattleTimer = 120 * MINUTE * IN_MILLISECONDS; + BuffAdalsSongOfBattle(); + } + break; + case WORLD_STATE_CUSTOM_EVENT_ON_MAGTHERIDON_HEAD_SPAWN: + if (param == TEAM_ALLIANCE) + { + _isMagtheridonHeadSpawnedAlliance = true; + BuffMagtheridonTeam(TEAM_ALLIANCE); + } + else + { + _isMagtheridonHeadSpawnedHorde = true; + BuffMagtheridonTeam(TEAM_HORDE); + } + break; + case WORLD_STATE_CUSTOM_EVENT_ON_MAGTHERIDON_HEAD_DESPAWN: + if (param == TEAM_ALLIANCE) + { + _isMagtheridonHeadSpawnedAlliance = false; + DispelMagtheridonTeam(TEAM_ALLIANCE); + } + else + { + _isMagtheridonHeadSpawnedHorde = false; + DispelMagtheridonTeam(TEAM_HORDE); + } + break; + default: + break; + } +} + +void WorldState::Update(uint32 diff) +{ + if (_adalSongOfBattleTimer) + { + if (_adalSongOfBattleTimer <= diff) + { + _adalSongOfBattleTimer = 0; + DispelAdalsSongOfBattle(); + } + else + { + _adalSongOfBattleTimer -= diff; + } + } +} + +void WorldState::HandlePlayerEnterZone(Player* player, WorldStateZoneId zoneId) +{ + std::lock_guard guard(_mutex); + switch (zoneId) + { + case ZONEID_SHATTRATH: + case ZONEID_BOTANICA: + case ZONEID_MECHANAR: + case ZONEID_ARCATRAZ: + if (_adalSongOfBattleTimer) + player->CastSpell(player, SPELL_ADAL_SONG_OF_BATTLE, true); + break; + case ZONEID_HELLFIRE_PENINSULA: + case ZONEID_HELLFIRE_RAMPARTS: + case ZONEID_HELLFIRE_CITADEL: + case ZONEID_BLOOD_FURNACE: + case ZONEID_SHATTERED_HALLS: + case ZONEID_MAGTHERIDON_LAIR: + if (_isMagtheridonHeadSpawnedAlliance && player->GetTeamId() == TEAM_ALLIANCE) + player->CastSpell(player, SPELL_TROLLBANES_COMMAND, true); + else if (_isMagtheridonHeadSpawnedHorde && player->GetTeamId() == TEAM_HORDE) + player->CastSpell(player, SPELL_NAZGRELS_FAVOR, true); + break; + default: + break; + } +}; +void WorldState::HandlePlayerLeaveZone(Player* player, WorldStateZoneId zoneId) +{ + std::lock_guard guard(_mutex); + switch (zoneId) + { + case ZONEID_SHATTRATH: + case ZONEID_BOTANICA: + case ZONEID_MECHANAR: + case ZONEID_ARCATRAZ: + if (!_adalSongOfBattleTimer) + player->RemoveAurasDueToSpell(SPELL_ADAL_SONG_OF_BATTLE); + break; + case ZONEID_HELLFIRE_PENINSULA: + case ZONEID_HELLFIRE_RAMPARTS: + case ZONEID_HELLFIRE_CITADEL: + case ZONEID_BLOOD_FURNACE: + case ZONEID_SHATTERED_HALLS: + case ZONEID_MAGTHERIDON_LAIR: + if (player->GetTeamId() == TEAM_ALLIANCE) + player->RemoveAurasDueToSpell(SPELL_TROLLBANES_COMMAND); + else if (player->GetTeamId() == TEAM_HORDE) + player->RemoveAurasDueToSpell(SPELL_NAZGRELS_FAVOR); + break; + default: + break; + } +}; + +void WorldState::BuffMagtheridonTeam(TeamId team) +{ + sMapMgr->DoForAllMaps([&](Map* map) -> void + { + switch (map->GetId()) + { + case 530: // Outland + map->DoForAllPlayers([&](Player* player) + { + if (player->GetZoneId() == ZONEID_HELLFIRE_PENINSULA && player->GetTeamId() == TEAM_ALLIANCE && team == TEAM_ALLIANCE) + player->CastSpell(player, SPELL_TROLLBANES_COMMAND, true); + else if (player->GetZoneId() == ZONEID_HELLFIRE_PENINSULA && player->GetTeamId() == TEAM_HORDE && team == TEAM_HORDE) + player->CastSpell(player, SPELL_NAZGRELS_FAVOR, true); + }); + break; + case 540: // The Shattered Halls + case 542: // The Blood Furnace + case 543: // Ramparts + case 544: // Magtheridon's Lair + map->DoForAllPlayers([&](Player* player) + { + if (player->GetTeamId() == TEAM_ALLIANCE && team == TEAM_ALLIANCE) + player->CastSpell(player, SPELL_TROLLBANES_COMMAND, true); + else if (player->GetTeamId() == TEAM_HORDE && team == TEAM_HORDE) + player->CastSpell(player, SPELL_NAZGRELS_FAVOR, true); + }); + break; + default: + break; + } + }); +} + +void WorldState::DispelMagtheridonTeam(TeamId team) +{ + sMapMgr->DoForAllMaps([&](Map* map) -> void + { + switch (map->GetId()) + { + case 530: // Outland + map->DoForAllPlayers([&](Player* player) + { + if (player->GetZoneId() == ZONEID_HELLFIRE_PENINSULA && player->GetTeamId() == TEAM_ALLIANCE && team == TEAM_ALLIANCE) + player->RemoveAurasDueToSpell(SPELL_TROLLBANES_COMMAND); + else if (player->GetZoneId() == ZONEID_HELLFIRE_PENINSULA && player->GetTeamId() == TEAM_HORDE && team == TEAM_HORDE) + player->RemoveAurasDueToSpell(SPELL_NAZGRELS_FAVOR); + }); + break; + case 540: // The Shattered Halls + case 542: // The Blood Furnace + case 543: // Ramparts + case 544: // Magtheridon's Lair + map->DoForAllPlayers([&](Player* player) + { + if (player->GetTeamId() == TEAM_ALLIANCE && team == TEAM_ALLIANCE) + player->RemoveAurasDueToSpell(SPELL_TROLLBANES_COMMAND); + else if (player->GetTeamId() == TEAM_HORDE && team == TEAM_HORDE) + player->RemoveAurasDueToSpell(SPELL_NAZGRELS_FAVOR); + }); + break; + default: + break; + } + }); +} + +void WorldState::BuffAdalsSongOfBattle() +{ + sMapMgr->DoForAllMaps([&](Map* map) -> void + { + switch (map->GetId()) + { + case 530: // Outland + map->DoForAllPlayers([&](Player* player) + { + if (player->GetZoneId() == ZONEID_SHATTRATH) + player->CastSpell(player, SPELL_ADAL_SONG_OF_BATTLE, true); + }); + break; + case 552: // Arcatraz + case 553: // Botanica + case 554: // Mechanar + map->DoForAllPlayers([&](Player* player) + { + player->CastSpell(player, SPELL_ADAL_SONG_OF_BATTLE, true); + }); + break; + default: + break; + } + }); +} + +void WorldState::DispelAdalsSongOfBattle() +{ + sMapMgr->DoForAllMaps([&](Map* map) -> void + { + switch (map->GetId()) + { + case 530: // Outland + map->DoForAllPlayers([&](Player* player) + { + if (player->GetZoneId() == ZONEID_SHATTRATH) + player->RemoveAurasDueToSpell(SPELL_ADAL_SONG_OF_BATTLE); + }); + break; + case 552: // Arcatraz + case 553: // Botanica + case 554: // Mechanar + map->DoForAllPlayers([&](Player* player) + { + player->RemoveAurasDueToSpell(SPELL_ADAL_SONG_OF_BATTLE); + }); + break; + default: + break; + } + }); +} diff --git a/src/server/game/World/WorldState.h b/src/server/game/World/WorldState.h new file mode 100644 index 00000000000000..d708bdcaf471cb --- /dev/null +++ b/src/server/game/World/WorldState.h @@ -0,0 +1,95 @@ +/* + * This file is part of the AzerothCore Project. See AUTHORS file for Copyright information + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by the + * Free Software Foundation; either version 3 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 Affero 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 . + */ + +#ifndef WORLD_STATE_H +#define WORLD_STATE_H + +#include "Player.h" +#include + +enum WorldStateCondition +{ + WORLD_STATE_CONDITION_TROLLBANES_COMMAND = 39911, + WORLD_STATE_CONDITION_NAZGRELS_FAVOR = 39913, + // Zeppelins + WORLD_STATE_CONDITION_THE_THUNDERCALLER = 164871, + WORLD_STATE_CONDITION_THE_IRON_EAGLE = 175080, + WORLD_STATE_CONDITION_THE_PURPLE_PRINCESS = 176495, +}; + +enum WorldStateConditionState +{ + WORLD_STATE_CONDITION_STATE_NONE = 0, +}; + +enum WorldStateEvent +{ + WORLD_STATE_CUSTOM_EVENT_ON_ADALS_SONG_OF_BATTLE = 39953, + WORLD_STATE_CUSTOM_EVENT_ON_MAGTHERIDON_HEAD_SPAWN = 184640, + WORLD_STATE_CUSTOM_EVENT_ON_MAGTHERIDON_HEAD_DESPAWN = 184641, +}; + +enum WorldStateZoneId +{ + ZONEID_SHATTRATH = 3703, + ZONEID_BOTANICA = 3847, + ZONEID_ARCATRAZ = 3848, + ZONEID_MECHANAR = 3849, + + ZONEID_HELLFIRE_PENINSULA = 3483, + ZONEID_HELLFIRE_RAMPARTS = 3562, + ZONEID_HELLFIRE_CITADEL = 3563, + ZONEID_BLOOD_FURNACE = 3713, + ZONEID_SHATTERED_HALLS = 3714, + ZONEID_MAGTHERIDON_LAIR = 3836, +}; + +enum WorldStateSpells +{ + SPELL_ADAL_SONG_OF_BATTLE = 39953, + + SPELL_TROLLBANES_COMMAND = 39911, + SPELL_NAZGRELS_FAVOR = 39913, +}; + +// Intended for implementing server wide scripts, note: all behaviour must be safeguarded towards multithreading +class WorldState +{ + public: + WorldState(); + virtual ~WorldState(); + static WorldState* instance(); + void HandlePlayerEnterZone(Player* player, WorldStateZoneId zoneId); + void HandlePlayerLeaveZone(Player* player, WorldStateZoneId zoneId); + bool IsConditionFulfilled(WorldStateCondition conditionId, WorldStateConditionState state = WORLD_STATE_CONDITION_STATE_NONE) const; + void HandleConditionStateChange(WorldStateCondition conditionId, WorldStateConditionState state); + void HandleExternalEvent(WorldStateEvent eventId, uint32 param); + void Update(uint32 diff); + private: + void BuffAdalsSongOfBattle(); + void DispelAdalsSongOfBattle(); + uint32 _adalSongOfBattleTimer; + void BuffMagtheridonTeam(TeamId team); + void DispelMagtheridonTeam(TeamId team); + bool _isMagtheridonHeadSpawnedHorde; + bool _isMagtheridonHeadSpawnedAlliance; + std::map> _transportStates; // atomic to avoid having to lock + std::mutex _mutex; // all World State operations are threat unsafe +}; + +#define sWorldState WorldState::instance() +#endif diff --git a/src/server/scripts/Outland/zone_hellfire_peninsula.cpp b/src/server/scripts/Outland/zone_hellfire_peninsula.cpp index 7172327427f7c8..8d9b2a5be4b1b5 100644 --- a/src/server/scripts/Outland/zone_hellfire_peninsula.cpp +++ b/src/server/scripts/Outland/zone_hellfire_peninsula.cpp @@ -24,6 +24,7 @@ #include "ScriptedGossip.h" #include "SpellScript.h" #include "SpellScriptLoader.h" +#include "WorldState.h" enum q10935Exorcism { @@ -602,6 +603,26 @@ class go_beacon : public GameObjectScript } }; +struct go_magtheridons_head : public GameObjectAI +{ + go_magtheridons_head(GameObject* gameObject) : GameObjectAI(gameObject) { } + + void InitializeAI() override + { + me->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE); // spawn head on spike + me->SetGameObjectFlag(GO_FLAG_NOT_SELECTABLE); + sWorldState->HandleExternalEvent(WORLD_STATE_CUSTOM_EVENT_ON_MAGTHERIDON_HEAD_SPAWN, me->GetPositionX() > 0.f ? TEAM_HORDE : TEAM_ALLIANCE); + } + + void OnStateChanged(uint32 state, Unit* /*unit*/) override + { + if (state == GO_JUST_DEACTIVATED) + { + sWorldState->HandleExternalEvent(WORLD_STATE_CUSTOM_EVENT_ON_MAGTHERIDON_HEAD_DESPAWN, me->GetPositionX() > 0.f ? TEAM_HORDE : TEAM_ALLIANCE); + } + } +}; + void AddSC_hellfire_peninsula() { // Ours @@ -615,4 +636,5 @@ void AddSC_hellfire_peninsula() new go_beacon(); RegisterCreatureAI(npc_magister_aledis); + RegisterGameObjectAI(go_magtheridons_head); } diff --git a/src/server/scripts/Spells/spell_generic.cpp b/src/server/scripts/Spells/spell_generic.cpp index d139bccd03366c..cd916620eade3d 100644 --- a/src/server/scripts/Spells/spell_generic.cpp +++ b/src/server/scripts/Spells/spell_generic.cpp @@ -554,26 +554,6 @@ class spell_gen_rallying_cry_of_the_dragonslayer : public SpellScript } }; -// 39953 - A'dal's Song of Battle -class spell_gen_adals_song_of_battle : public SpellScript -{ - PrepareSpellScript(spell_gen_adals_song_of_battle); - - void SelectTarget(std::list& targets) - { - targets.clear(); - Map::PlayerList const& pList = GetCaster()->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator itr = pList.begin(); itr != pList.end(); ++itr) - if (itr->GetSource()->GetZoneId() == 3703 /*Shattrath*/) - targets.push_back(itr->GetSource()); - } - - void Register() override - { - OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_gen_adals_song_of_battle::SelectTarget, EFFECT_ALL, TARGET_UNIT_SRC_AREA_ALLY); - } -}; - /* 15366 - Songflower Serenade 22888 - Rallying Cry of the Dragonslayer */ class spell_gen_disabled_above_63 : public AuraScript @@ -5336,7 +5316,6 @@ void AddSC_generic_spell_scripts() RegisterSpellScript(spell_pet_hit_expertise_scalling); RegisterSpellScript(spell_gen_grow_flower_patch); RegisterSpellScript(spell_gen_rallying_cry_of_the_dragonslayer); - RegisterSpellScript(spell_gen_adals_song_of_battle); RegisterSpellScript(spell_gen_disabled_above_63); RegisterSpellScript(spell_gen_black_magic_enchant); RegisterSpellScript(spell_gen_area_aura_select_players); diff --git a/src/server/scripts/World/transport_zeppelin.h b/src/server/scripts/World/transport_zeppelin.h new file mode 100644 index 00000000000000..232e812002f66e --- /dev/null +++ b/src/server/scripts/World/transport_zeppelin.h @@ -0,0 +1,68 @@ +/* + * This file is part of the AzerothCore Project. See AUTHORS file for Copyright information + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by the + * Free Software Foundation; either version 3 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 Affero 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 . + */ + +enum ZeppelinEvent +{ + EVENT_UC_FROM_GROMGOL_ARRIVAL = 15312, + EVENT_GROMGOL_FROM_UC_ARRIVAL = 15314, + EVENT_OG_FROM_UC_ARRIVAL = 15318, + EVENT_UC_FROM_OG_ARRIVAL = 15320, + EVENT_OG_FROM_GROMGOL_ARRIVAL = 15322, + EVENT_GROMGOL_FROM_OG_ARRIVAL = 15324, + EVENT_WK_ARRIVAL = 15431, + EVENT_VL_FROM_UC_ARRIVAL = 19126, + EVENT_UC_FROM_VL_ARRIVAL = 19127, + EVENT_OG_FROM_BT_ARRIVAL = 19137, + EVENT_BT_FROM_OG_ARRIVAL = 19139, + EVENT_OG_FROM_TB_ARRIVAL = 21868, + EVENT_TB_FROM_OG_ARRIVAL = 21870, + EVENT_OG_TO_GROMGOL_DEPARTURE = 15323, + EVENT_GROMGOL_TO_OG_DEPARTURE = 15325, + EVENT_OG_TO_UC_DEPARTURE = 15319, + EVENT_UC_TO_OG_DEPARTURE = 15321, + EVENT_UC_TO_GROMGOL_DEPARTURE = 15313, + EVENT_GROMGOL_TO_UC_DEPARTURE = 15315, +}; + +enum ZeppelinMaster +{ + NPC_NEZRAZ = 3149, + NPC_HINDENBURG = 3150, + NPC_FREZZA = 9564, + NPC_ZAPETTA = 9566, + NPC_SNURK_BUCKSQUICK = 12136, + NPC_SQUIBBY_OVERSPECK = 12137, + NPC_HARROWMEISER = 23823, + NPC_GREEB_RAMROCKET = 26537, + NPC_NARGO_SCREWBORE = 26538, + NPC_MEEFI_FARTHROTTLE = 26539, + NPC_DRENK_SPANNERSPARK = 26540, + NPC_ZELLI_HOTNOZZLE = 34765, + NPC_KRENDLE_BIGPOCKETS = 34766, +}; + +const float SEARCH_RANGE_ZEPPELIN_MASTER = 32.0f; + +enum ZeppelinPassenger +{ + // The Thundercaller + NPC_SKY_CAPTAIN_CLOUDKICKER = 25077, + NPC_CHIEF_OFFICER_COPPERNUT = 25070, + // The Purple Princess + NPC_SKY_CAPTAIN_CABLELAMP = 25105, + NPC_WATCHER_UMJIN = 25107, +}; diff --git a/src/server/scripts/World/transport_zeppelins.cpp b/src/server/scripts/World/transport_zeppelins.cpp new file mode 100644 index 00000000000000..2cb8496921c1fe --- /dev/null +++ b/src/server/scripts/World/transport_zeppelins.cpp @@ -0,0 +1,109 @@ +/* + * This file is part of the AzerothCore Project. See AUTHORS file for Copyright information + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by the + * Free Software Foundation; either version 3 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 Affero 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 "GameObjectAI.h" +#include "GameObjectScript.h" +#include "WorldState.h" +#include "transport_zeppelin.h" + +// 175080 The Iron Eagle - Grom'gol to Orgrimmar +struct go_transport_the_iron_eagle : GameObjectAI +{ + go_transport_the_iron_eagle(GameObject *object) : GameObjectAI(object) { }; + + void EventInform(uint32 eventId) override + { + sWorldState->HandleConditionStateChange(WORLD_STATE_CONDITION_THE_IRON_EAGLE, static_cast(eventId)); + switch (eventId) + { + case EVENT_GROMGOL_FROM_OG_ARRIVAL: + if (Creature *creature = me->FindNearestCreature(NPC_NEZRAZ, SEARCH_RANGE_ZEPPELIN_MASTER)) + creature->AI()->Talk(0); + break; + case EVENT_OG_FROM_GROMGOL_ARRIVAL: + if (Creature *creature = me->FindNearestCreature(NPC_SNURK_BUCKSQUICK, 150.0f)) + creature->AI()->Talk(0); + break; + default: + return; + } + } +}; + +// 164871 The Thundercaller - Undercity to Orgrimmar +struct go_transport_the_thundercaller : GameObjectAI +{ + go_transport_the_thundercaller(GameObject *object) : GameObjectAI(object) { }; + + void EventInform(uint32 eventId) override + { + sWorldState->HandleConditionStateChange(WORLD_STATE_CONDITION_THE_THUNDERCALLER, static_cast(eventId)); + switch (eventId) + { + case EVENT_OG_FROM_UC_ARRIVAL: + if (Creature *creature = me->FindNearestCreature(NPC_FREZZA, SEARCH_RANGE_ZEPPELIN_MASTER)) + creature->AI()->Talk(0); + break; + case EVENT_UC_FROM_OG_ARRIVAL: + if (Creature *creature = me->FindNearestCreature(NPC_ZAPETTA, SEARCH_RANGE_ZEPPELIN_MASTER)) + creature->AI()->Talk(0); + break; + case EVENT_OG_TO_UC_DEPARTURE: + break; + case EVENT_UC_TO_OG_DEPARTURE: + if (Creature *creature = me->FindNearestCreature(NPC_ZAPETTA, SEARCH_RANGE_ZEPPELIN_MASTER)) + creature->AI()->Talk(1); + break; + default: + return; + } + } +}; + +// 176495 The Purple Princess - Grom'Gol to Undercity +struct go_transport_the_purple_princess : GameObjectAI +{ + go_transport_the_purple_princess(GameObject *object) : GameObjectAI(object) { }; + + void EventInform(uint32 eventId) override + { + sWorldState->HandleConditionStateChange(WORLD_STATE_CONDITION_THE_PURPLE_PRINCESS, static_cast(eventId)); + switch (eventId) + { + case EVENT_GROMGOL_FROM_UC_ARRIVAL: + if (Creature *creature = me->FindNearestCreature(NPC_SQUIBBY_OVERSPECK, SEARCH_RANGE_ZEPPELIN_MASTER)) + creature->AI()->Talk(0); + break; + case EVENT_UC_FROM_GROMGOL_ARRIVAL: + if (Creature *creature = me->FindNearestCreature(NPC_HINDENBURG, SEARCH_RANGE_ZEPPELIN_MASTER)) + creature->AI()->Talk(0); + break; + case EVENT_UC_TO_GROMGOL_DEPARTURE: + case EVENT_GROMGOL_TO_UC_DEPARTURE: + break; + default: + return; + } + } +}; + +void AddSC_transport_zeppelins() +{ + RegisterGameObjectAI(go_transport_the_iron_eagle); + RegisterGameObjectAI(go_transport_the_thundercaller); + RegisterGameObjectAI(go_transport_the_purple_princess); +} diff --git a/src/server/scripts/World/world_script_loader.cpp b/src/server/scripts/World/world_script_loader.cpp index cda3d4ba416ae8..21813fd4c55d84 100644 --- a/src/server/scripts/World/world_script_loader.cpp +++ b/src/server/scripts/World/world_script_loader.cpp @@ -32,6 +32,7 @@ void AddSC_action_ip_logger(); // location: scripts\World\action_ip_logger.cpp void AddSC_player_scripts(); void AddSC_npc_stave_of_ancients(); void AddSC_server_mail(); +void AddSC_transport_zeppelins(); // The name of this function should match: // void Add${NameOfDirectory}Scripts() @@ -53,4 +54,5 @@ void AddWorldScripts() AddSC_player_scripts(); AddSC_npc_stave_of_ancients(); AddSC_server_mail(); + AddSC_transport_zeppelins(); } From bae0e1c8d0ca8307c3f1f2a9144a1d1293994c81 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 12 Nov 2024 15:16:24 +0000 Subject: [PATCH 050/105] chore(DB): import pending files Referenced commit(s): 3565e4a9eba5475f7377f694838000c8837b9785 --- .../rev_1727679643827269473.sql => db_world/2024_11_12_01.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1727679643827269473.sql => db_world/2024_11_12_01.sql} (99%) diff --git a/data/sql/updates/pending_db_world/rev_1727679643827269473.sql b/data/sql/updates/db_world/2024_11_12_01.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1727679643827269473.sql rename to data/sql/updates/db_world/2024_11_12_01.sql index 8e3d2ab45a8145..5507a714fc9514 100644 --- a/data/sql/updates/pending_db_world/rev_1727679643827269473.sql +++ b/data/sql/updates/db_world/2024_11_12_01.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_12_00 -> 2024_11_12_01 -- DELETE FROM `spell_script_names` WHERE `spell_id`=39953 AND `ScriptName`='spell_gen_adals_song_of_battle'; -- A'dal From cc037981237f20cc831e48412dea5a025c5dce36 Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Tue, 12 Nov 2024 16:16:41 +0100 Subject: [PATCH 051/105] fix(Core/Spells): Jump Speed Calculations (#20479) Core/Spell: Jump Speed Calculations https://github.com/TrinityCore/TrinityCore/commit/0197a2f990aa7c7eaf8637a2a5da7f43def9c4bd Co-authored-by: DanVS <33371360+DanVS@users.noreply.github.com> --- src/server/game/Spells/SpellEffects.cpp | 28 +++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index 19583b18f1e649..72570afac73245 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -1152,13 +1152,29 @@ void Spell::EffectJumpDest(SpellEffIndex effIndex) void Spell::CalculateJumpSpeeds(uint8 i, float dist, float& speedXY, float& speedZ) { - if (m_spellInfo->Effects[i].MiscValue) - speedZ = float(m_spellInfo->Effects[i].MiscValue) / 10; - else if (m_spellInfo->Effects[i].MiscValueB) - speedZ = float(m_spellInfo->Effects[i].MiscValueB) / 10; + float runSpeed = m_caster->IsControlledByPlayer() ? playerBaseMoveSpeed[MOVE_RUN] : baseMoveSpeed[MOVE_RUN]; + if (Creature* creature = m_caster->ToCreature()) + runSpeed *= creature->GetCreatureTemplate()->speed_run; + + float multiplier = m_spellInfo->Effects[i].ValueMultiplier; + if (multiplier <= 0.0f) + multiplier = 1.0f; + + speedXY = std::min(runSpeed * 3.0f * multiplier, std::max(28.0f, m_caster->GetSpeed(MOVE_RUN) * 4.0f)); + + float duration = dist / speedXY; + float durationSqr = duration * duration; + float minHeight = m_spellInfo->Effects[i].MiscValue ? m_spellInfo->Effects[i].MiscValue / 10.0f : 0.5f; // Lower bound is blizzlike + float maxHeight = m_spellInfo->Effects[i].MiscValueB ? m_spellInfo->Effects[i].MiscValueB / 10.0f : 1000.0f; // Upper bound is unknown + float height; + if (durationSqr < minHeight * 8 / Movement::gravity) + height = minHeight; + else if (durationSqr > maxHeight * 8 / Movement::gravity) + height = maxHeight; else - speedZ = 10.0f; - speedXY = dist * 10.0f / speedZ; + height = Movement::gravity * durationSqr / 8; + + speedZ = std::sqrt(2 * Movement::gravity * height); } void Spell::EffectTeleportUnits(SpellEffIndex /*effIndex*/) From 17ae7c86ff51de7ff39e5fbd9c60866b319743d6 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Tue, 12 Nov 2024 12:49:11 -0300 Subject: [PATCH 052/105] refactor(Scripts/SunwellPlateau): Modernize instance script (#20519) --- .../SunwellPlateau/boss_brutallus.cpp | 28 +-- .../SunwellPlateau/boss_kalecgos.cpp | 10 +- .../SunwellPlateau/boss_kiljaeden.cpp | 40 ++--- .../SunwellPlateau/boss_muru.cpp | 4 +- .../instance_sunwell_plateau.cpp | 167 +++--------------- .../SunwellPlateau/sunwell_plateau.h | 25 ++- 6 files changed, 84 insertions(+), 190 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp index 96e15eb4f292c4..86f63127411410 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp @@ -235,7 +235,7 @@ struct npc_madrigosa : public NullCreatureAI { case EVENT_MAD_1: me->SetVisible(true); - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { me->SetTarget(brutallus->GetGUID()); brutallus->SetReactState(REACT_PASSIVE); @@ -261,12 +261,12 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_4, 7000); break; case EVENT_MAD_4: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) brutallus->AI()->Talk(YELL_INTRO); events.ScheduleEvent(EVENT_MAD_5, 5000); break; case EVENT_MAD_5: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { brutallus->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_ATTACK1H); me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_ATTACK1H); @@ -274,7 +274,7 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_6, 10000); break; case EVENT_MAD_6: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { brutallus->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); @@ -297,11 +297,11 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_8, 14000); break; case EVENT_MAD_8: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) me->CastSpell(brutallus, SPELL_MADRIGOSA_FROSTBOLT, false); break; case EVENT_MAD_9: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_FLAME_RING, true); brutallus->RemoveAllAuras(); @@ -323,7 +323,7 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_14, 2000); break; case EVENT_MAD_14: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { brutallus->SetDisableGravity(true); brutallus->GetMotionMaster()->MovePoint(0, brutallus->GetPositionX(), brutallus->GetPositionY() - 30.0f, brutallus->GetPositionZ() + 15.0f, false, true); @@ -331,7 +331,7 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_15, 10000); break; case EVENT_MAD_15: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { brutallus->RemoveAllAuras(); brutallus->SetDisableGravity(false); @@ -341,12 +341,12 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_16, 1400); break; case EVENT_MAD_16: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) brutallus->CastSpell(me, SPELL_BRUTALLUS_CHARGE, true); events.ScheduleEvent(EVENT_MAD_17, 1200); break; case EVENT_MAD_17: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) brutallus->HandleEmoteCommand(EMOTE_ONESHOT_ATTACK1H); events.ScheduleEvent(EVENT_MAD_18, 500); break; @@ -357,14 +357,14 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_19, 6000); break; case EVENT_MAD_19: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) brutallus->AI()->Talk(YELL_INTRO_KILL_MADRIGOSA); events.ScheduleEvent(EVENT_MAD_20, 7000); break; case EVENT_MAD_20: me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE); me->SetFaction(FACTION_FRIENDLY); - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { brutallus->AI()->Talk(YELL_INTRO_TAUNT); brutallus->CastSpell(brutallus, SPELL_BRUTALLUS_BREAK_ICE, false); @@ -372,7 +372,7 @@ struct npc_madrigosa : public NullCreatureAI events.ScheduleEvent(EVENT_MAD_21, 4000); break; case EVENT_MAD_21: - if (Creature* brutallus = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_BRUTALLUS))) + if (Creature* brutallus = instance->GetCreature(DATA_BRUTALLUS)) { brutallus->SetReactState(REACT_AGGRESSIVE); brutallus->SetHealth(brutallus->GetMaxHealth()); @@ -382,7 +382,7 @@ struct npc_madrigosa : public NullCreatureAI break; case EVENT_SPAWN_FELMYST: me->DespawnOrUnsummon(1); - if (Creature* felmyst = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_FELMYST))) + if (Creature* felmyst = instance->GetCreature(DATA_FELMYST)) felmyst->AI()->DoAction(ACTION_START_EVENT); break; } diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp index 92f91e14b5a784..2c41d4a8057c76 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp @@ -184,7 +184,7 @@ struct boss_kalecgos : public BossAI events.Reset(); events2.ScheduleEvent(EVENT_TALK_GOOD_1, 1000); ClearPlayerAuras(); - if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) + if (Creature* Sath = instance->GetCreature(DATA_SATHROVARR)) { Sath->RemoveAllAuras(); Sath->GetMotionMaster()->MovementExpired(); @@ -243,7 +243,7 @@ struct boss_kalecgos : public BossAI events2.ScheduleEvent(EVENT_TALK_GOOD_2, 1000); break; case EVENT_TALK_GOOD_2: - if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) + if (Creature* Sath = instance->GetCreature(DATA_SATHROVARR)) { summons.Despawn(Sath); Unit::Kill(me, Sath); @@ -329,7 +329,7 @@ struct boss_kalecgos : public BossAI case EVENT_CHECK_HEALTH: if (me->HealthBelowPct(10)) { - if (Creature* Sath = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_SATHROVARR))) + if (Creature* Sath = instance->GetCreature(DATA_SATHROVARR)) Sath->AI()->DoAction(ACTION_ENRAGE_OTHER); DoAction(ACTION_ENRAGE); break; @@ -403,7 +403,7 @@ struct boss_kalec : public ScriptedAI void JustDied(Unit*) override { if (InstanceScript* instance = me->GetInstanceScript()) - if (Creature* kalecgos = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS))) + if (Creature* kalecgos = instance->GetCreature(DATA_KALECGOS)) kalecgos->AI()->DoAction(ACTION_KALEC_DIED); } @@ -576,7 +576,7 @@ struct boss_sathrovarr : public ScriptedAI case EVENT_CHECK_HEALTH2: if (me->HealthBelowPct(1)) { - if (Creature* kalecgos = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS))) + if (Creature* kalecgos = instance->GetCreature(DATA_KALECGOS)) kalecgos->AI()->DoAction(ACTION_SATH_BANISH); DoAction(ACTION_BANISH); break; diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp index 50d05cddb7f5e2..3bf22491d1ada5 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp @@ -176,8 +176,8 @@ struct npc_kiljaeden_controller : public NullCreatureAI void ResetOrbs() { - for (uint8 i = 0; i < 4; ++i) - if (GameObject* orb = ObjectAccessor::GetGameObject(*me, instance->GetGuidData(DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 + i))) + for (uint8 i = DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1; i < DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_4 + 1; ++i) + if (GameObject* orb = instance->GetGameObject(i)) orb->SetGameObjectFlag(GO_FLAG_NOT_SELECTABLE); } @@ -333,7 +333,7 @@ struct boss_kiljaeden : public ScriptedAI { Talk(SAY_KJ_DEATH); instance->SetBossState(DATA_KILJAEDEN, DONE); - if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KILJAEDEN_CONTROLLER))) + if (Creature* controller = instance->GetCreature(DATA_KJ_CONTROLLER)) Unit::Kill(controller, controller); } @@ -393,17 +393,17 @@ struct boss_kiljaeden : public ScriptedAI me->CastSpell(me, SPELL_REBIRTH, false); break; case EVENT_EMPOWER_ORBS1: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_READY1); EmpowerOrb(false); break; case EVENT_EMPOWER_ORBS2: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_READY2); EmpowerOrb(false); break; case EVENT_EMPOWER_ORBS3: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_READY_ALL); EmpowerOrb(true); break; @@ -413,56 +413,56 @@ struct boss_kiljaeden : public ScriptedAI me->SetInCombatWithZone(); return; case EVENT_TEXT_SPEACH11: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_JOIN); break; case EVENT_TEXT_SPEACH21: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_AWAKEN); break; case EVENT_TEXT_SPEACH22: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + if (Creature* anveena = instance->GetCreature(DATA_ANVEENA)) sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_IMPRISONED, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); break; case EVENT_TEXT_SPEACH23: Talk(SAY_KJ_PHASE3); break; case EVENT_TEXT_SPEACH31: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_LETGO); break; case EVENT_TEXT_SPEACH32: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + if (Creature* anveena = instance->GetCreature(DATA_ANVEENA)) sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_LOST, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); break; case EVENT_TEXT_SPEACH33: Talk(SAY_KJ_PHASE4); break; case EVENT_TEXT_SPEACH41: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_FOCUS); break; case EVENT_TEXT_SPEACH42: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + if (Creature* anveena = instance->GetCreature(DATA_ANVEENA)) sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_KALEC, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); break; case EVENT_TEXT_SPEACH43: - if (Creature* kalec = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KALECGOS_KJ))) + if (Creature* kalec = instance->GetCreature(DATA_KALECGOS_KJ)) kalec->AI()->Talk(SAY_KALECGOS_FATE); break; case EVENT_TEXT_SPEACH44: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + if (Creature* anveena = instance->GetCreature(DATA_ANVEENA)) sCreatureTextMgr->SendChat(anveena, SAY_ANVEENA_GOODBYE, nullptr, CHAT_MSG_ADDON, LANG_ADDON, TEXT_RANGE_ZONE); break; case EVENT_TEXT_SPEACH45: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + if (Creature* anveena = instance->GetCreature(DATA_ANVEENA)) { anveena->RemoveAllAuras(); anveena->DespawnOrUnsummon(3500); } break; case EVENT_TEXT_SPEACH46: - if (Creature* anveena = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_ANVEENA))) + if (Creature* anveena = instance->GetCreature(DATA_ANVEENA)) { anveena->CastSpell(anveena, SPELL_SACRIFICE_OF_ANVEENA, true); me->CastSpell(me, SPELL_CUSTOM_08_STATE, true); @@ -627,9 +627,9 @@ struct boss_kiljaeden : public ScriptedAI void EmpowerOrb(bool empowerAll) { - for (uint8 i = 0; i < 4; ++i) + for (uint8 i = DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1; i < DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_4 + 1; ++i) { - if (GameObject* orb = ObjectAccessor::GetGameObject(*me, instance->GetGuidData(DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 + i))) + if (GameObject* orb = instance->GetGameObject(i)) { if (orb->HasGameObjectFlag(GO_FLAG_NOT_SELECTABLE)) { @@ -637,7 +637,7 @@ struct boss_kiljaeden : public ScriptedAI if (Creature* trigger = me->SummonTrigger(orb->GetPositionX(), orb->GetPositionY(), orb->GetPositionZ(), 0, 10 * MINUTE * IN_MILLISECONDS)) { trigger->CastSpell(trigger, SPELL_RING_OF_BLUE_FLAMES, true, nullptr, nullptr, trigger->GetGUID()); - if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_KILJAEDEN_CONTROLLER))) + if (Creature* controller = instance->GetCreature(DATA_KJ_CONTROLLER)) controller->AI()->JustSummoned(trigger); } diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp index a53becd5f067f4..b1d7198945392a 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp @@ -166,7 +166,7 @@ struct boss_entropius : public ScriptedAI void EnterEvadeMode(EvadeReason why) override { if (InstanceScript* instance = me->GetInstanceScript()) - if (Creature* muru = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MURU))) + if (Creature* muru = instance->GetCreature(DATA_MURU)) if (!muru->IsInEvadeMode()) muru->AI()->EnterEvadeMode(why); @@ -195,7 +195,7 @@ struct boss_entropius : public ScriptedAI void JustDied(Unit* /*killer*/) override { if (InstanceScript* instance = me->GetInstanceScript()) - if (Creature* muru = ObjectAccessor::GetCreature(*me, instance->GetGuidData(NPC_MURU))) + if (Creature* muru = instance->GetCreature(DATA_MURU)) Unit::Kill(muru, muru); } diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp index 9c51e79c185e0c..8f2d41cc1e285b 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp @@ -35,10 +35,28 @@ DoorData const doorData[] = ObjectData const creatureData[] = { - { NPC_LADY_SACROLASH, DATA_SACROLASH }, - { NPC_GRAND_WARLOCK_ALYTHESS, DATA_ALYTHESS }, - { NPC_MADRIGOSA, DATA_MADRIGOSA }, - { 0, 0, } + { NPC_KALECGOS, DATA_KALECGOS }, + { NPC_BRUTALLUS, DATA_BRUTALLUS }, + { NPC_FELMYST, DATA_FELMYST }, + { NPC_MURU, DATA_MURU }, + { NPC_LADY_SACROLASH, DATA_SACROLASH }, + { NPC_GRAND_WARLOCK_ALYTHESS, DATA_ALYTHESS }, + { NPC_MADRIGOSA, DATA_MADRIGOSA }, + { NPC_SATHROVARR, DATA_SATHROVARR }, + { NPC_KILJAEDEN_CONTROLLER, DATA_KJ_CONTROLLER }, + { NPC_ANVEENA, DATA_ANVEENA }, + { NPC_KALECGOS_KJ, DATA_KALECGOS_KJ }, + { 0, 0, } +}; + +ObjectData const gameObjectData[] = +{ + { GO_ICE_BARRIER, DATA_ICEBARRIER }, + { GO_ORB_OF_THE_BLUE_DRAGONFLIGHT1, DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 }, + { GO_ORB_OF_THE_BLUE_DRAGONFLIGHT2, DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_2 }, + { GO_ORB_OF_THE_BLUE_DRAGONFLIGHT3, DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_3 }, + { GO_ORB_OF_THE_BLUE_DRAGONFLIGHT4, DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_4 }, + { 0, 0 } }; class instance_sunwell_plateau : public InstanceMapScript @@ -53,36 +71,17 @@ class instance_sunwell_plateau : public InstanceMapScript SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); - LoadObjectData(creatureData, nullptr); + LoadObjectData(creatureData, gameObjectData); } void OnPlayerEnter(Player* player) override { instance->LoadGrid(1477.94f, 643.22f); instance->LoadGrid(1641.45f, 988.08f); - if (GameObject* gobj = instance->GetGameObject(IceBarrierGUID)) + if (GameObject* gobj = GetGameObject(DATA_ICEBARRIER)) gobj->SendUpdateToPlayer(player); } - Player const* GetPlayerInMap() const - { - Map::PlayerList const& players = instance->GetPlayers(); - - if (!players.IsEmpty()) - { - for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) - { - Player* player = itr->GetSource(); - if (player && !player->HasAura(45839)) - return player; - } - } - //else - // LOG_DEBUG("scripts", "Instance Sunwell Plateau: GetPlayerInMap, but PlayerList is empty!"); - - return nullptr; - } - void OnCreatureCreate(Creature* creature) override { if (creature->GetSpawnId() > 0 || !creature->GetOwnerGUID().IsPlayer()) @@ -90,55 +89,24 @@ class instance_sunwell_plateau : public InstanceMapScript switch (creature->GetEntry()) { - case NPC_KALECGOS: - KalecgosDragonGUID = creature->GetGUID(); - break; - case NPC_SATHROVARR: - SathrovarrGUID = creature->GetGUID(); - break; - case NPC_BRUTALLUS: - BrutallusGUID = creature->GetGUID(); - break; - case NPC_FELMYST: - FelmystGUID = creature->GetGUID(); - break; - case NPC_MURU: - MuruGUID = creature->GetGUID(); - break; - case NPC_KILJAEDEN: - KilJaedenGUID = creature->GetGUID(); - break; - case NPC_KILJAEDEN_CONTROLLER: - KilJaedenControllerGUID = creature->GetGUID(); - break; - case NPC_ANVEENA: - AnveenaGUID = creature->GetGUID(); - break; - case NPC_KALECGOS_KJ: - KalecgosKjGUID = creature->GetGUID(); - break; - - // Xinef: Felmyst encounter case NPC_DEMONIC_VAPOR_TRAIL: case NPC_UNYIELDING_DEAD: - if (Creature* felmyst = instance->GetCreature(FelmystGUID)) + if (Creature* felmyst = GetCreature(DATA_FELMYST)) felmyst->AI()->JustSummoned(creature); break; - // Xinef: M'uru encounter case NPC_DARKNESS: case NPC_VOID_SENTINEL: case NPC_VOID_SPAWN: - if (Creature* muru = instance->GetCreature(MuruGUID)) + if (Creature* muru = GetCreature(DATA_MURU)) muru->AI()->JustSummoned(creature); break; - // Xinef: Kil'jaeden encounter case NPC_FELFIRE_PORTAL: case NPC_VOLATILE_FELFIRE_FIEND: case NPC_SHIELD_ORB: case NPC_SINISTER_REFLECTION: - if (Creature* kiljaedenC = instance->GetCreature(KilJaedenControllerGUID)) + if (Creature* kiljaedenC = GetCreature(DATA_KJ_CONTROLLER)) kiljaedenC->AI()->JustSummoned(creature); break; default: @@ -147,87 +115,6 @@ class instance_sunwell_plateau : public InstanceMapScript InstanceScript::OnCreatureCreate(creature); } - - void OnGameObjectCreate(GameObject* go) override - { - switch (go->GetEntry()) - { - case GO_FORCE_FIELD: - case GO_BOSS_COLLISION_1: - case GO_BOSS_COLLISION_2: - case GO_FIRE_BARRIER: - case GO_MURUS_GATE_1: - case GO_MURUS_GATE_2: - AddDoor(go); - break; - case GO_ICE_BARRIER: - IceBarrierGUID = go->GetGUID(); - go->setActive(true); - break; - case GO_ORB_OF_THE_BLUE_DRAGONFLIGHT1: - blueFlightOrbGUID[0] = go->GetGUID(); - break; - case GO_ORB_OF_THE_BLUE_DRAGONFLIGHT2: - blueFlightOrbGUID[1] = go->GetGUID(); - break; - case GO_ORB_OF_THE_BLUE_DRAGONFLIGHT3: - blueFlightOrbGUID[2] = go->GetGUID(); - break; - case GO_ORB_OF_THE_BLUE_DRAGONFLIGHT4: - blueFlightOrbGUID[3] = go->GetGUID(); - break; - default: - break; - } - } - - ObjectGuid GetGuidData(uint32 id) const override - { - switch (id) - { - case NPC_KALECGOS: - return KalecgosDragonGUID; - case NPC_SATHROVARR: - return SathrovarrGUID; - case NPC_BRUTALLUS: - return BrutallusGUID; - case NPC_FELMYST: - return FelmystGUID; - case NPC_MURU: - return MuruGUID; - case NPC_ANVEENA: - return AnveenaGUID; - case NPC_KALECGOS_KJ: - return KalecgosKjGUID; - case NPC_KILJAEDEN_CONTROLLER: - return KilJaedenControllerGUID; - case NPC_KILJAEDEN: - return KilJaedenGUID; - - // Orbs - case DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1: - case DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_2: - case DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_3: - case DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_4: - return blueFlightOrbGUID[id - DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1]; - } - - return ObjectGuid::Empty; - } - - protected: - ObjectGuid KalecgosDragonGUID; - ObjectGuid SathrovarrGUID; - ObjectGuid BrutallusGUID; - ObjectGuid FelmystGUID; - ObjectGuid MuruGUID; - ObjectGuid KilJaedenGUID; - ObjectGuid KilJaedenControllerGUID; - ObjectGuid AnveenaGUID; - ObjectGuid KalecgosKjGUID; - - ObjectGuid IceBarrierGUID; - ObjectGuid blueFlightOrbGUID[4]; }; InstanceScript* GetInstanceScript(InstanceMap* map) const override diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h index 74969b0bb2f127..e40dfc057ecfe6 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h @@ -38,15 +38,22 @@ enum BossIds enum DataTypes { - DATA_SACROLASH = 0, - DATA_ALYTHESS = 1, - DATA_MADRIGOSA = 2, - - // GameObject GUIDs - DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 = 10, - DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_2 = 11, - DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_3 = 12, - DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_4 = 13 + DATA_SACROLASH = 7, + DATA_ALYTHESS = 8, + DATA_MADRIGOSA = 9, + DATA_SATHROVARR = 10, + DATA_KJ_CONTROLLER = 11, + DATA_ANVEENA = 12, + DATA_KALECGOS_KJ = 13 +}; + +enum DataTypesObjects +{ + DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_1 = 0, + DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_2 = 1, + DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_3 = 2, + DATA_ORB_OF_THE_BLUE_DRAGONFLIGHT_4 = 3, + DATA_ICEBARRIER = 4, }; enum CreatureIds From 6b1941940635ec53e4e4dc192d229a3767cf3cd9 Mon Sep 17 00:00:00 2001 From: sudlud Date: Tue, 12 Nov 2024 18:31:00 +0100 Subject: [PATCH 053/105] fix(DB/Gameobject): Sniffed Values for 'Zul' Aman Misc (2)' spawns (#20533) --- .../rev_1731427157601507600.sql | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731427157601507600.sql diff --git a/data/sql/updates/pending_db_world/rev_1731427157601507600.sql b/data/sql/updates/pending_db_world/rev_1731427157601507600.sql new file mode 100644 index 00000000000000..4b0c51c12678b4 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731427157601507600.sql @@ -0,0 +1,29 @@ +-- Update gameobject 'Zul' Aman Misc (2)' with sniffed values +-- new spawns +DELETE FROM `gameobject` WHERE (`id` IN (186622, 186623, 186648, 186658, 186671, 186860, 187035, 187036, 187037)) +AND (`guid` BETWEEN 486 AND 497); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`, `ScriptName`, `VerifiedBuild`, `Comment`) VALUES +-- Zul'Aman - Loot Box - Dwarf +(486, 186622, 568, 0, 0, 1, 1, 305.5137939453125, 1467.336669921875, 81.5059356689453125, 3.961898565292358398, 0, 0, -0.91705989837646484, 0.398749500513076782, 7200, 255, 1, "", 49345, NULL), +-- Zul'Aman - Dwarf Hammer +(487, 186623, 568, 0, 0, 1, 1, 307.208343505859375, 1464.1441650390625, 81.60315704345703125, 6.178466320037841796, 0, 0, -0.05233573913574218, 0.998629570007324218, 7200, 255, 1, "", 49345, NULL), +-- Tanzar's Trunk +(488, 186648, 568, 0, 0, 1, 1, -135.194442749023437, 1333.054443359375, 48.17387008666992187, 2.391098499298095703, 0, 0, 0.930417060852050781, 0.366502493619918823, 7200, 255, 1, "", 49345, NULL), +-- Kraz's Chest +(489, 186658, 568, 0, 0, 1, 1, -79.985137939453125, 1125.3427734375, 5.594004154205322265, 3.22885894775390625, 0, 0, -0.99904823303222656, 0.043619260191917419, 7200, 255, 1, "", 49345, NULL), +-- Ashli's Vase +(490, 186671, 568, 0, 0, 1, 1, 332.369049072265625, 1084.4185791015625, 6.280053138732910156, 3.071766138076782226, 0, 0, 0.999390602111816406, 0.034906134009361267, 7200, 255, 1, "", 49345, NULL), +(491, 186671, 568, 0, 0, 1, 1, 343.357086181640625, 1152.027099609375, 6.343656063079833984, 3.351046562194824218, 0, 0, -0.99452114105224609, 0.104535527527332305, 7200, 255, 1, "", 49345, NULL), +(492, 186671, 568, 0, 0, 1, 1, 344.3331298828125, 1084.6768798828125, 6.966906070709228515, 2.967041015625, 0, 0, 0.996193885803222656, 0.087165042757987976, 7200, 255, 1, "", 49345, NULL), +(493, 186671, 568, 0, 0, 1, 1, 424.256072998046875, 1083.61328125, 6.606083869934082031, 1.099556446075439453, 0, 0, 0.522498130798339843, 0.852640450000762939, 7200, 255, 1, "", 49345, NULL), +-- Zul'Aman - Altar Torch - Bear God +(494, 186860, 568, 0, 0, 1, 1, 99.98274993896484375, 1333.9500732421875, -9.39568901062011718, 0.593410074710845947, 0, 0, 0.292370796203613281, 0.95630502700805664, 7200, 255, 1, "", 49345, NULL), +-- Zul'Aman - Altar Torch - Eagle God +(495, 187035, 568, 0, 0, 1, 1, 132.4637603759765625, 1334.1907958984375, -9.37467288970947265, 3.752462387084960937, 0, 0, -0.95371627807617187, 0.300707906484603881, 7200, 255, 1, "", 49345, NULL), +-- Zul'Aman - Altar Torch - Dragonhawk God +(496, 187036, 568, 0, 0, 1, 1, 98.815216064453125, 1245.41064453125, -9.49481678009033203, 1.431168079376220703, 0, 0, 0.656058311462402343, 0.754710197448730468, 7200, 255, 1, "", 49345, NULL), +-- Zul'Aman - Altar Torch - Lynx God +(497, 187037, 568, 0, 0, 1, 1, 132.3734893798828125, 1244.41455078125, -9.6475982666015625, 0.296705186367034912, 0, 0, 0.147809028625488281, 0.989015936851501464, 7200, 255, 1, "", 53788, NULL); + +-- lock Tanzar's Trunk +UPDATE `gameobject_template_addon` SET `flags` = `flags` | 2 WHERE (`entry` = 186648); From dffdb635141be5c53606369ac4234d6c011529ae Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 12 Nov 2024 17:31:56 +0000 Subject: [PATCH 054/105] chore(DB): import pending files Referenced commit(s): 6b1941940635ec53e4e4dc192d229a3767cf3cd9 --- .../rev_1731427157601507600.sql => db_world/2024_11_12_02.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731427157601507600.sql => db_world/2024_11_12_02.sql} (98%) diff --git a/data/sql/updates/pending_db_world/rev_1731427157601507600.sql b/data/sql/updates/db_world/2024_11_12_02.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1731427157601507600.sql rename to data/sql/updates/db_world/2024_11_12_02.sql index 4b0c51c12678b4..0e7c5e1736a8f1 100644 --- a/data/sql/updates/pending_db_world/rev_1731427157601507600.sql +++ b/data/sql/updates/db_world/2024_11_12_02.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_12_01 -> 2024_11_12_02 -- Update gameobject 'Zul' Aman Misc (2)' with sniffed values -- new spawns DELETE FROM `gameobject` WHERE (`id` IN (186622, 186623, 186648, 186658, 186671, 186860, 187035, 187036, 187037)) From f8d53d4cd87a887237986e4a2619b54c701f1dc0 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Tue, 12 Nov 2024 15:39:48 -0300 Subject: [PATCH 055/105] =?UTF-8?q?fix(Scripts/Commands):=20Fix=20crash=20?= =?UTF-8?q?when=20using=20npc=20set=20origin=20faction=20wi=E2=80=A6=20(#2?= =?UTF-8?q?0536)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/server/scripts/Commands/cs_npc.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/server/scripts/Commands/cs_npc.cpp b/src/server/scripts/Commands/cs_npc.cpp index a7daa30246214d..2cc199bd0afa3f 100644 --- a/src/server/scripts/Commands/cs_npc.cpp +++ b/src/server/scripts/Commands/cs_npc.cpp @@ -483,6 +483,9 @@ class npc_commandscript : public CommandScript if (!player) return false; + if (!player->GetSelectedUnit()) + return false; + Creature* creature = player->GetSelectedUnit()->ToCreature(); if (!creature) From b2ddd103692bfba6f0f438b4185f6a5e7ed160fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francesco=20Borz=C3=AC?= Date: Wed, 13 Nov 2024 06:35:15 +0100 Subject: [PATCH 056/105] refactor(src/server/scripts): remove unused imports (#20540) --- src/server/scripts/Commands/cs_list.cpp | 1 - src/server/scripts/EasternKingdoms/zone_eversong_woods.cpp | 2 -- .../CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp | 1 - .../CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp | 2 -- src/server/scripts/Kalimdor/zone_moonglade.cpp | 1 - .../ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp | 1 - .../FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp | 1 - 7 files changed, 9 deletions(-) diff --git a/src/server/scripts/Commands/cs_list.cpp b/src/server/scripts/Commands/cs_list.cpp index 9702616f247054..bb66e326c608c7 100644 --- a/src/server/scripts/Commands/cs_list.cpp +++ b/src/server/scripts/Commands/cs_list.cpp @@ -32,7 +32,6 @@ EndScriptData */ #include "MapMgr.h" #include "ObjectMgr.h" #include "Player.h" -#include "Random.h" #include "SpellAuraEffects.h" using namespace Acore::ChatCommands; diff --git a/src/server/scripts/EasternKingdoms/zone_eversong_woods.cpp b/src/server/scripts/EasternKingdoms/zone_eversong_woods.cpp index c715e3542e4b25..cd3612d4ebe3e7 100644 --- a/src/server/scripts/EasternKingdoms/zone_eversong_woods.cpp +++ b/src/server/scripts/EasternKingdoms/zone_eversong_woods.cpp @@ -14,8 +14,6 @@ * You should have received a copy of the GNU General Public License along * with this program. If not, see . */ - -#include "Common.h" #include "CreatureScript.h" #include "ScriptedCreature.h" diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp index 431892aad114f6..4a11a8d1325fc7 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp @@ -19,7 +19,6 @@ #include "InstanceMapScript.h" #include "InstanceScript.h" #include "Player.h" -#include "WorldPacket.h" #include "hyjal.h" /* Battle of Mount Hyjal encounters: diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp index 9be4fa88847c54..9265e4e91d24f6 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp @@ -18,8 +18,6 @@ #include "InstanceMapScript.h" #include "InstanceScript.h" #include "Player.h" -#include "SpellInfo.h" -#include "TemporarySummon.h" #include "the_black_morass.h" const Position PortalLocation[4] = diff --git a/src/server/scripts/Kalimdor/zone_moonglade.cpp b/src/server/scripts/Kalimdor/zone_moonglade.cpp index a5bfb69b04a8d1..baa562a7603f94 100644 --- a/src/server/scripts/Kalimdor/zone_moonglade.cpp +++ b/src/server/scripts/Kalimdor/zone_moonglade.cpp @@ -33,7 +33,6 @@ EndContentData */ #include "Cell.h" #include "CreatureScript.h" #include "GridNotifiers.h" -#include "GridNotifiersImpl.h" #include "Player.h" #include "ScriptedCreature.h" #include "ScriptedEscortAI.h" diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp index a0c17eae5c1615..c2dbb9b1e9fe08 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp @@ -20,7 +20,6 @@ #include "InstanceScript.h" #include "Player.h" #include "SpellScriptLoader.h" -#include "TemporarySummon.h" #include "WorldPacket.h" #include "ruby_sanctum.h" #include "SpellScript.h" diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp index dda74b74def9cd..73550b3dbc117a 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp @@ -15,7 +15,6 @@ * with this program. If not, see . */ -#include "CreatureScript.h" #include "InstanceMapScript.h" #include "Player.h" #include "ScriptedCreature.h" From a9f0f371e5134bc86704c71010f17c8825e4706a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francesco=20Borz=C3=AC?= Date: Wed, 13 Nov 2024 11:37:20 +0100 Subject: [PATCH 057/105] refactor(src/server/game): optimise imports (#20541) --- src/server/apps/worldserver/RemoteAccess/RASession.cpp | 1 + src/server/game/AI/SmartScripts/SmartScript.h | 2 -- src/server/game/AI/SmartScripts/SmartScriptMgr.h | 5 ++--- src/server/game/Battlefield/Zones/BattlefieldWG.h | 1 - src/server/game/Battlegrounds/BattlegroundQueue.h | 3 ++- src/server/game/Chat/Channels/Channel.h | 1 - src/server/game/Chat/Hyperlinks.cpp | 1 + src/server/game/DungeonFinding/LFGQueue.h | 2 -- src/server/game/Entities/Creature/Creature.h | 2 -- src/server/game/Entities/Creature/CreatureGroups.cpp | 1 + src/server/game/Entities/Creature/CreatureGroups.h | 1 + src/server/game/Entities/Creature/GossipDef.h | 3 ++- src/server/game/Entities/GameObject/GameObject.h | 1 - src/server/game/Entities/GameObject/GameObjectData.h | 4 ++-- src/server/game/Entities/Item/ItemEnchantmentMgr.cpp | 1 + src/server/game/Entities/Object/Position.cpp | 1 + src/server/game/Entities/Player/CinematicMgr.h | 4 +++- src/server/game/Entities/Unit/CharmInfo.h | 3 ++- src/server/game/Grids/NGrid.h | 1 - src/server/game/Guilds/Guild.h | 1 - src/server/game/Loot/LootItemStorage.cpp | 1 + src/server/game/Maps/Map.cpp | 1 + src/server/game/Maps/TransportMgr.cpp | 1 + src/server/game/Misc/DynamicVisibility.h | 2 +- src/server/game/Movement/MotionMaster.h | 4 +++- .../Movement/MovementGenerators/FleeingMovementGenerator.h | 2 ++ src/server/game/Movement/MovementGenerators/PathGenerator.h | 1 - .../Movement/MovementGenerators/PointMovementGenerator.h | 2 +- .../Movement/MovementGenerators/RandomMovementGenerator.cpp | 1 + .../Movement/MovementGenerators/RandomMovementGenerator.h | 1 + src/server/game/Movement/Waypoints/WaypointMgr.h | 2 +- src/server/game/Pools/PoolMgr.cpp | 1 + src/server/game/Reputation/ReputationMgr.h | 3 +-- src/server/game/Scripting/MapScripts.cpp | 2 -- src/server/game/Scripting/ScriptDefines/GlobalScript.h | 1 + src/server/game/Scripting/ScriptDefines/ServerScript.h | 1 + src/server/game/Scripting/ScriptObject.h | 2 +- src/server/game/Spells/Spell.h | 4 +++- src/server/game/Time/UpdateTime.h | 1 - src/server/game/Tools/CharacterDatabaseCleaner.cpp | 1 + src/server/game/Tools/PlayerDump.h | 1 - src/server/game/Warden/WardenCheckMgr.cpp | 1 + src/server/game/Weather/WeatherMgr.cpp | 1 - src/server/game/World/World.h | 2 +- src/server/scripts/Commands/cs_misc.cpp | 1 + 45 files changed, 44 insertions(+), 35 deletions(-) diff --git a/src/server/apps/worldserver/RemoteAccess/RASession.cpp b/src/server/apps/worldserver/RemoteAccess/RASession.cpp index 06215d01973276..0a4703a21f443e 100644 --- a/src/server/apps/worldserver/RemoteAccess/RASession.cpp +++ b/src/server/apps/worldserver/RemoteAccess/RASession.cpp @@ -22,6 +22,7 @@ #include "Duration.h" #include "Log.h" #include "MotdMgr.h" +#include "QueryResult.h" #include "SRP6.h" #include "Util.h" #include "World.h" diff --git a/src/server/game/AI/SmartScripts/SmartScript.h b/src/server/game/AI/SmartScripts/SmartScript.h index 361384a1cf12d3..4f98c49d1aade4 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.h +++ b/src/server/game/AI/SmartScripts/SmartScript.h @@ -18,9 +18,7 @@ #ifndef ACORE_SMARTSCRIPT_H #define ACORE_SMARTSCRIPT_H -#include "Common.h" #include "Creature.h" -#include "CreatureAI.h" #include "GridNotifiers.h" #include "SmartScriptMgr.h" #include "Spell.h" diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.h b/src/server/game/AI/SmartScripts/SmartScriptMgr.h index b713054d69d341..fcf63144683eae 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.h +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.h @@ -20,12 +20,11 @@ #include "Common.h" #include "Creature.h" -#include "CreatureAI.h" #include "DBCStores.h" +#include "ObjectAccessor.h" +#include "ObjectMgr.h" #include "Optional.h" -#include "Spell.h" #include "SpellMgr.h" -#include "Unit.h" #include typedef uint32 SAIBool; diff --git a/src/server/game/Battlefield/Zones/BattlefieldWG.h b/src/server/game/Battlefield/Zones/BattlefieldWG.h index 858288ad01b346..5a53c796efe857 100644 --- a/src/server/game/Battlefield/Zones/BattlefieldWG.h +++ b/src/server/game/Battlefield/Zones/BattlefieldWG.h @@ -20,7 +20,6 @@ #include "Battlefield.h" #include "Log.h" -#include "ObjectAccessor.h" #include "World.h" class Group; diff --git a/src/server/game/Battlegrounds/BattlegroundQueue.h b/src/server/game/Battlegrounds/BattlegroundQueue.h index ab98e3291c53bf..d3589b304761dd 100644 --- a/src/server/game/Battlegrounds/BattlegroundQueue.h +++ b/src/server/game/Battlegrounds/BattlegroundQueue.h @@ -19,9 +19,10 @@ #define __BATTLEGROUNDQUEUE_H #include "Battleground.h" -#include "Common.h" #include "DBCEnums.h" #include "EventProcessor.h" +#include "ObjectGuid.h" +#include "SharedDefines.h" #include constexpr auto COUNT_OF_PLAYERS_TO_AVERAGE_WAIT_TIME = 10; diff --git a/src/server/game/Chat/Channels/Channel.h b/src/server/game/Chat/Channels/Channel.h index 62efd947376f16..3afccc3ad340b7 100644 --- a/src/server/game/Chat/Channels/Channel.h +++ b/src/server/game/Chat/Channels/Channel.h @@ -18,7 +18,6 @@ #ifndef _CHANNEL_H #define _CHANNEL_H -#include "Common.h" #include "WorldPacket.h" #include "WorldSession.h" #include diff --git a/src/server/game/Chat/Hyperlinks.cpp b/src/server/game/Chat/Hyperlinks.cpp index 6cc124e800c1de..af2ac277cf91c4 100644 --- a/src/server/game/Chat/Hyperlinks.cpp +++ b/src/server/game/Chat/Hyperlinks.cpp @@ -23,6 +23,7 @@ #include "SharedDefines.h" #include "SpellInfo.h" #include "SpellMgr.h" +#include "World.h" using namespace Acore::Hyperlinks; diff --git a/src/server/game/DungeonFinding/LFGQueue.h b/src/server/game/DungeonFinding/LFGQueue.h index cef355bcc2aa87..2cc49f645f616f 100644 --- a/src/server/game/DungeonFinding/LFGQueue.h +++ b/src/server/game/DungeonFinding/LFGQueue.h @@ -18,8 +18,6 @@ #ifndef _LFGQUEUE_H #define _LFGQUEUE_H -#include - #include "LFG.h" namespace lfg diff --git a/src/server/game/Entities/Creature/Creature.h b/src/server/game/Entities/Creature/Creature.h index 89612d57641ab8..17f69f801e8bbc 100644 --- a/src/server/game/Entities/Creature/Creature.h +++ b/src/server/game/Entities/Creature/Creature.h @@ -22,10 +22,8 @@ #include "CharmInfo.h" #include "Common.h" #include "CreatureData.h" -#include "DatabaseEnv.h" #include "LootMgr.h" #include "Unit.h" -#include "World.h" #include class SpellInfo; diff --git a/src/server/game/Entities/Creature/CreatureGroups.cpp b/src/server/game/Entities/Creature/CreatureGroups.cpp index 730da73f6f6b5d..759d38fa178d8e 100644 --- a/src/server/game/Entities/Creature/CreatureGroups.cpp +++ b/src/server/game/Entities/Creature/CreatureGroups.cpp @@ -21,6 +21,7 @@ #include "Log.h" #include "MoveSplineInit.h" #include "ObjectMgr.h" +#include "QueryResult.h" #include "WaypointMgr.h" FormationMgr::~FormationMgr() diff --git a/src/server/game/Entities/Creature/CreatureGroups.h b/src/server/game/Entities/Creature/CreatureGroups.h index dabc507d35388b..2cb6e9ae84a654 100644 --- a/src/server/game/Entities/Creature/CreatureGroups.h +++ b/src/server/game/Entities/Creature/CreatureGroups.h @@ -19,6 +19,7 @@ #define _FORMATIONS_H #include "Define.h" +#include "ObjectGuid.h" #include "Unit.h" #include #include diff --git a/src/server/game/Entities/Creature/GossipDef.h b/src/server/game/Entities/Creature/GossipDef.h index c8f98d68409ab4..7c306c0291353c 100644 --- a/src/server/game/Entities/Creature/GossipDef.h +++ b/src/server/game/Entities/Creature/GossipDef.h @@ -20,8 +20,9 @@ #include "Common.h" #include "NPCHandler.h" -#include "Object.h" +#include "ObjectGuid.h" #include "QuestDef.h" +#include class WorldSession; class ObjectGuid; diff --git a/src/server/game/Entities/GameObject/GameObject.h b/src/server/game/Entities/GameObject/GameObject.h index d8598f5fce71bd..5a214226d690d4 100644 --- a/src/server/game/Entities/GameObject/GameObject.h +++ b/src/server/game/Entities/GameObject/GameObject.h @@ -19,7 +19,6 @@ #define AZEROTHCORE_GAMEOBJECT_H #include "Common.h" -#include "DatabaseEnv.h" #include "G3D/Quat.h" #include "GameObjectData.h" #include "LootMgr.h" diff --git a/src/server/game/Entities/GameObject/GameObjectData.h b/src/server/game/Entities/GameObject/GameObjectData.h index 70182a8872b13b..fac8fa9d24f820 100644 --- a/src/server/game/Entities/GameObject/GameObjectData.h +++ b/src/server/game/Entities/GameObject/GameObjectData.h @@ -19,9 +19,9 @@ #define GAMEOBJECTDATA_H #include "SharedDefines.h" -#include "WorldPacket.h" -#include +#include #include +#include #define MAX_GAMEOBJECT_QUEST_ITEMS 6 #define MAX_GO_STATE 3 diff --git a/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp b/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp index b7c0fccd24b4dd..f82d42f8742195 100644 --- a/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp +++ b/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp @@ -20,6 +20,7 @@ #include "DatabaseEnv.h" #include "Log.h" #include "ObjectMgr.h" +#include "QueryResult.h" #include "Util.h" #include #include diff --git a/src/server/game/Entities/Object/Position.cpp b/src/server/game/Entities/Object/Position.cpp index b8dc69f9f2796e..fee50be6e8c0d9 100644 --- a/src/server/game/Entities/Object/Position.cpp +++ b/src/server/game/Entities/Object/Position.cpp @@ -19,6 +19,7 @@ #include "ByteBuffer.h" #include "Geometry.h" #include "GridDefines.h" +#include "Random.h" #include #include diff --git a/src/server/game/Entities/Player/CinematicMgr.h b/src/server/game/Entities/Player/CinematicMgr.h index 66eeaa4b933c68..2baeb54bf1b5d1 100644 --- a/src/server/game/Entities/Player/CinematicMgr.h +++ b/src/server/game/Entities/Player/CinematicMgr.h @@ -19,7 +19,9 @@ #define CinematicMgr_h__ #include "Define.h" -#include "Object.h" +#include "Position.h" +#include "TemporarySummon.h" +#include constexpr auto CINEMATIC_UPDATEDIFF = 500; constexpr auto CINEMATIC_LOOKAHEAD = 2000; diff --git a/src/server/game/Entities/Unit/CharmInfo.h b/src/server/game/Entities/Unit/CharmInfo.h index 2f44c2ff496d1c..9efc7e32a74633 100644 --- a/src/server/game/Entities/Unit/CharmInfo.h +++ b/src/server/game/Entities/Unit/CharmInfo.h @@ -18,7 +18,8 @@ #ifndef _CHARMINFO_H #define _CHARMINFO_H -#include "Object.h" +#include "Define.h" +#include "ObjectGuid.h" #define MAX_SPELL_CHARM 4 #define MAX_SPELL_VEHICLE 6 diff --git a/src/server/game/Grids/NGrid.h b/src/server/game/Grids/NGrid.h index ff1f1ed813d020..6ac60aeb72dcd4 100644 --- a/src/server/game/Grids/NGrid.h +++ b/src/server/game/Grids/NGrid.h @@ -24,7 +24,6 @@ #include "Grid.h" #include "GridReference.h" #include "Timer.h" -#include "Util.h" template < diff --git a/src/server/game/Guilds/Guild.h b/src/server/game/Guilds/Guild.h index 7e4ce174b10706..4f710d60fef66d 100644 --- a/src/server/game/Guilds/Guild.h +++ b/src/server/game/Guilds/Guild.h @@ -22,7 +22,6 @@ #include "ObjectMgr.h" #include "Optional.h" #include "Player.h" -#include "WorldPacket.h" #include #include diff --git a/src/server/game/Loot/LootItemStorage.cpp b/src/server/game/Loot/LootItemStorage.cpp index fc37aba5ac91e8..d453e08cd07286 100644 --- a/src/server/game/Loot/LootItemStorage.cpp +++ b/src/server/game/Loot/LootItemStorage.cpp @@ -19,6 +19,7 @@ #include "DatabaseEnv.h" #include "ObjectMgr.h" #include "PreparedStatement.h" +#include "QueryResult.h" LootItemStorage::LootItemStorage() { diff --git a/src/server/game/Maps/Map.cpp b/src/server/game/Maps/Map.cpp index 4fac4189a47bf7..0dac0aed760243 100644 --- a/src/server/game/Maps/Map.cpp +++ b/src/server/game/Maps/Map.cpp @@ -31,6 +31,7 @@ #include "MapInstanced.h" #include "Metric.h" #include "MiscPackets.h" +#include "MMapFactory.h" #include "Object.h" #include "ObjectAccessor.h" #include "ObjectGridLoader.h" diff --git a/src/server/game/Maps/TransportMgr.cpp b/src/server/game/Maps/TransportMgr.cpp index faeef233e848c1..ad319e943a5b8a 100644 --- a/src/server/game/Maps/TransportMgr.cpp +++ b/src/server/game/Maps/TransportMgr.cpp @@ -19,6 +19,7 @@ #include "InstanceScript.h" #include "MapMgr.h" #include "MoveSpline.h" +#include "QueryResult.h" #include "Transport.h" TransportTemplate::~TransportTemplate() diff --git a/src/server/game/Misc/DynamicVisibility.h b/src/server/game/Misc/DynamicVisibility.h index cf38bfa50a8648..00d7fe679002cb 100644 --- a/src/server/game/Misc/DynamicVisibility.h +++ b/src/server/game/Misc/DynamicVisibility.h @@ -18,7 +18,7 @@ #ifndef __DYNAMICVISIBILITY_H #define __DYNAMICVISIBILITY_H -#include "Common.h" +#include "Define.h" struct VisibilitySettingData { diff --git a/src/server/game/Movement/MotionMaster.h b/src/server/game/Movement/MotionMaster.h index 7eda4b22ff73cc..5aabfe61b31523 100644 --- a/src/server/game/Movement/MotionMaster.h +++ b/src/server/game/Movement/MotionMaster.h @@ -19,7 +19,9 @@ #define ACORE_MOTIONMASTER_H #include "Common.h" -#include "Object.h" +#include "ObjectGuid.h" +#include "PathGenerator.h" +#include "Position.h" #include "SharedDefines.h" #include "Spline/MoveSpline.h" #include diff --git a/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h b/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h index 064597f36d38cc..ce654cf88ff1b8 100644 --- a/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h @@ -18,7 +18,9 @@ #ifndef ACORE_FLEEINGMOVEMENTGENERATOR_H #define ACORE_FLEEINGMOVEMENTGENERATOR_H +#include "Creature.h" #include "MovementGenerator.h" +#include "Timer.h" template class FleeingMovementGenerator : public MovementGeneratorMedium< T, FleeingMovementGenerator > diff --git a/src/server/game/Movement/MovementGenerators/PathGenerator.h b/src/server/game/Movement/MovementGenerators/PathGenerator.h index 92f82c283cba28..b26f961a84863e 100644 --- a/src/server/game/Movement/MovementGenerators/PathGenerator.h +++ b/src/server/game/Movement/MovementGenerators/PathGenerator.h @@ -20,7 +20,6 @@ #include "DetourNavMesh.h" #include "DetourNavMeshQuery.h" -#include "MMapFactory.h" #include "MMapMgr.h" #include "MapDefines.h" #include "MoveSplineInitArgs.h" diff --git a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h index fdff98725cf6b7..f19e04d4221a7e 100644 --- a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h @@ -18,7 +18,7 @@ #ifndef ACORE_POINTMOVEMENTGENERATOR_H #define ACORE_POINTMOVEMENTGENERATOR_H -#include "FollowerReference.h" +#include "Creature.h" #include "MovementGenerator.h" template diff --git a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp index 36b2a7ee3fa26d..5d904d31acd96b 100644 --- a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp @@ -25,6 +25,7 @@ #include "ObjectAccessor.h" #include "Spell.h" #include "Util.h" +#include "World.h" template RandomMovementGenerator::~RandomMovementGenerator() { } diff --git a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h index cb88b352e20eac..d765e3d3e8ae61 100644 --- a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h @@ -20,6 +20,7 @@ #include "MovementGenerator.h" #include "PathGenerator.h" +#include "Timer.h" #define RANDOM_POINTS_NUMBER 12 #define RANDOM_LINKS_COUNT 7 diff --git a/src/server/game/Movement/Waypoints/WaypointMgr.h b/src/server/game/Movement/Waypoints/WaypointMgr.h index a9df15129512d0..ea588a28c5eb87 100644 --- a/src/server/game/Movement/Waypoints/WaypointMgr.h +++ b/src/server/game/Movement/Waypoints/WaypointMgr.h @@ -18,7 +18,7 @@ #ifndef ACORE_WAYPOINTMANAGER_H #define ACORE_WAYPOINTMANAGER_H -#include "Common.h" +#include "Define.h" #include #include #include diff --git a/src/server/game/Pools/PoolMgr.cpp b/src/server/game/Pools/PoolMgr.cpp index ed4378aa3c1541..2a31e74740f3ec 100644 --- a/src/server/game/Pools/PoolMgr.cpp +++ b/src/server/game/Pools/PoolMgr.cpp @@ -20,6 +20,7 @@ #include "Log.h" #include "MapMgr.h" #include "ObjectMgr.h" +#include "QueryResult.h" #include "Transport.h" //////////////////////////////////////////////////////////// diff --git a/src/server/game/Reputation/ReputationMgr.h b/src/server/game/Reputation/ReputationMgr.h index 57e6f71243c847..1d9cbdad706f4f 100644 --- a/src/server/game/Reputation/ReputationMgr.h +++ b/src/server/game/Reputation/ReputationMgr.h @@ -18,10 +18,9 @@ #ifndef __ACORE_REPUTATION_MGR_H #define __ACORE_REPUTATION_MGR_H -#include "Common.h" +#include "DatabaseEnvFwd.h" #include "DBCStructure.h" #include "Language.h" -#include "QueryResult.h" #include "SharedDefines.h" #include diff --git a/src/server/game/Scripting/MapScripts.cpp b/src/server/game/Scripting/MapScripts.cpp index 9cbc20f213d77c..76e945a9c5cfb0 100644 --- a/src/server/game/Scripting/MapScripts.cpp +++ b/src/server/game/Scripting/MapScripts.cpp @@ -20,14 +20,12 @@ #include "GridNotifiers.h" #include "Map.h" #include "MapMgr.h" -#include "MapRefMgr.h" #include "ObjectMgr.h" #include "Pet.h" #include "ScriptMgr.h" #include "ScriptedCreature.h" #include "Transport.h" #include "WaypointMgr.h" -#include "World.h" /// Put scripts in the execution queue void Map::ScriptsStart(ScriptMapMap const& scripts, uint32 id, Object* source, Object* target) diff --git a/src/server/game/Scripting/ScriptDefines/GlobalScript.h b/src/server/game/Scripting/ScriptDefines/GlobalScript.h index e1d9d58beaec24..c683650f4b8ea4 100644 --- a/src/server/game/Scripting/ScriptDefines/GlobalScript.h +++ b/src/server/game/Scripting/ScriptDefines/GlobalScript.h @@ -18,6 +18,7 @@ #ifndef SCRIPT_OBJECT_GLOBAL_SCRIPT_H_ #define SCRIPT_OBJECT_GLOBAL_SCRIPT_H_ +#include "DatabaseEnvFwd.h" #include "DBCEnums.h" #include "ObjectGuid.h" #include "ScriptObject.h" diff --git a/src/server/game/Scripting/ScriptDefines/ServerScript.h b/src/server/game/Scripting/ScriptDefines/ServerScript.h index 03c974194cf5d0..89c29b1f0d1b5f 100644 --- a/src/server/game/Scripting/ScriptDefines/ServerScript.h +++ b/src/server/game/Scripting/ScriptDefines/ServerScript.h @@ -20,6 +20,7 @@ #include "ScriptObject.h" #include +#include // NOTE: this import is NEEDED (even though some IDEs report it as unused) enum ServerHook { diff --git a/src/server/game/Scripting/ScriptObject.h b/src/server/game/Scripting/ScriptObject.h index 51c534bcbaa0c8..1dd8500cdcba54 100644 --- a/src/server/game/Scripting/ScriptObject.h +++ b/src/server/game/Scripting/ScriptObject.h @@ -18,8 +18,8 @@ #ifndef _SCRIPT_OBJECT_H_ #define _SCRIPT_OBJECT_H_ -#include "DatabaseEnvFwd.h" #include "ScriptObjectFwd.h" +#include //#include "Duration.h" //#include "LFG.h" diff --git a/src/server/game/Spells/Spell.h b/src/server/game/Spells/Spell.h index 83c7054ddcfb93..45ae5719487f1f 100644 --- a/src/server/game/Spells/Spell.h +++ b/src/server/game/Spells/Spell.h @@ -18,11 +18,13 @@ #ifndef __SPELL_H #define __SPELL_H +#include "ConditionMgr.h" #include "GridDefines.h" -#include "ObjectMgr.h" +#include "LootMgr.h" #include "PathGenerator.h" #include "SharedDefines.h" #include "SpellInfo.h" +#include "Unit.h" class Unit; class Player; diff --git a/src/server/game/Time/UpdateTime.h b/src/server/game/Time/UpdateTime.h index 356eb05266378d..d6618f4305f6a6 100644 --- a/src/server/game/Time/UpdateTime.h +++ b/src/server/game/Time/UpdateTime.h @@ -21,7 +21,6 @@ #include "Define.h" #include "Duration.h" #include -#include constexpr auto AVG_DIFF_COUNT = 500; diff --git a/src/server/game/Tools/CharacterDatabaseCleaner.cpp b/src/server/game/Tools/CharacterDatabaseCleaner.cpp index 2fc40800716bfa..ca133a3d95dcdf 100644 --- a/src/server/game/Tools/CharacterDatabaseCleaner.cpp +++ b/src/server/game/Tools/CharacterDatabaseCleaner.cpp @@ -19,6 +19,7 @@ #include "DBCStores.h" #include "Database/DatabaseEnv.h" #include "Log.h" +#include "QueryResult.h" #include "SpellMgr.h" #include "World.h" diff --git a/src/server/game/Tools/PlayerDump.h b/src/server/game/Tools/PlayerDump.h index 58c3a3932e1047..64b3f4b6cb05d5 100644 --- a/src/server/game/Tools/PlayerDump.h +++ b/src/server/game/Tools/PlayerDump.h @@ -19,7 +19,6 @@ #define _PLAYER_DUMP_H #include "ObjectGuid.h" -#include #include enum DumpTableType diff --git a/src/server/game/Warden/WardenCheckMgr.cpp b/src/server/game/Warden/WardenCheckMgr.cpp index 0ac1c7e364dada..a061ec4e81a6d6 100644 --- a/src/server/game/Warden/WardenCheckMgr.cpp +++ b/src/server/game/Warden/WardenCheckMgr.cpp @@ -18,6 +18,7 @@ #include "WardenCheckMgr.h" #include "Database/DatabaseEnv.h" #include "Log.h" +#include "QueryResult.h" #include "Util.h" #include "Warden.h" #include "WorldSession.h" diff --git a/src/server/game/Weather/WeatherMgr.cpp b/src/server/game/Weather/WeatherMgr.cpp index 29d8a6f4ef2622..f7b98911e41404 100644 --- a/src/server/game/Weather/WeatherMgr.cpp +++ b/src/server/game/Weather/WeatherMgr.cpp @@ -26,7 +26,6 @@ #include "Player.h" #include "Weather.h" #include "WorldSession.h" -#include namespace WeatherMgr { diff --git a/src/server/game/World/World.h b/src/server/game/World/World.h index 2eb435f5256a6c..0d71b24eb95692 100644 --- a/src/server/game/World/World.h +++ b/src/server/game/World/World.h @@ -22,10 +22,10 @@ #ifndef __WORLD_H #define __WORLD_H +#include "DatabaseEnvFwd.h" #include "IWorld.h" #include "LockedQueue.h" #include "ObjectGuid.h" -#include "QueryResult.h" #include "SharedDefines.h" #include "Timer.h" #include diff --git a/src/server/scripts/Commands/cs_misc.cpp b/src/server/scripts/Commands/cs_misc.cpp index fa85bac3fb80a6..17ee4761188adf 100644 --- a/src/server/scripts/Commands/cs_misc.cpp +++ b/src/server/scripts/Commands/cs_misc.cpp @@ -34,6 +34,7 @@ #include "Language.h" #include "MapMgr.h" #include "MiscPackets.h" +#include "MMapFactory.h" #include "MovementGenerator.h" #include "ObjectAccessor.h" #include "Pet.h" From d52cff5f8dace9d2f5cdacec4ea1ab45e91b15a2 Mon Sep 17 00:00:00 2001 From: FlyingArowana Date: Wed, 13 Nov 2024 14:44:02 +0000 Subject: [PATCH 058/105] fix(DB/Tele): Updated for Wrath of the Lich King (#20265) --- .../rev_1729603880657213700.sql | 549 ++++++++++++++++++ 1 file changed, 549 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1729603880657213700.sql diff --git a/data/sql/updates/pending_db_world/rev_1729603880657213700.sql b/data/sql/updates/pending_db_world/rev_1729603880657213700.sql new file mode 100644 index 00000000000000..caee235535ca39 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1729603880657213700.sql @@ -0,0 +1,549 @@ +-- Update Existing Teles +-- Standardisation and String Corrections +UPDATE `game_tele` SET `name` = 'Onyxia' WHERE `id` = 699 AND `name` = 'onyxia'; +UPDATE `game_tele` SET `name` = 'TheUnderbog' WHERE `id` = 1262 AND `name` = 'underbog'; +UPDATE `game_tele` SET `name` = 'GoldBug' WHERE `id` = 1430 AND `name` = 'goldbug'; +UPDATE `game_tele` SET `name` = 'MineK' WHERE `id` = 1431 AND `name` = 'minek'; +UPDATE `game_tele` SET `name` = 'Box' WHERE `id` = 1432 AND `name` = 'box'; +UPDATE `game_tele` SET `name` = 'DKZone' WHERE `id` = 1433 AND `name` = 'DKzone'; +UPDATE `game_tele` SET `name` = 'Prison' WHERE `id` = 1434 AND `name` = 'prison'; +UPDATE `game_tele` SET `name` = 'BorgorokOutpost' WHERE `id` = 1394 AND `name` = 'Bor''gorokOutpost'; +UPDATE `game_tele` SET `name` = 'Unupe' WHERE `id` = 1396 AND `name` = 'Unu''pe'; +UPDATE `game_tele` SET `name` = 'TaunkaleVillage' WHERE `id` = 1397 AND `name` = 'Taunka''leVillage'; +UPDATE `game_tele` SET `name` = 'ZulDrak' WHERE `id` = 1403 AND `name` = 'Zul''Drak'; +UPDATE `game_tele` SET `name` = 'TheOculus' WHERE `id` = 1448 AND `name` = 'Oculus'; +UPDATE `game_tele` SET `name` = 'TheForgeOfSouls' WHERE `id` = 1445 AND `name` = 'ForgeOfSouls'; +UPDATE `game_tele` SET `name` = 'TheObsidianSanctum' WHERE `id` = 1447 AND `name` = 'ObsidianSanctum'; +UPDATE `game_tele` SET `name` = 'TheEyeOfEternity' WHERE `id` = 1444 AND `name` = 'EyeOfEternity'; +UPDATE `game_tele` SET `name` = 'TheRubySanctum' WHERE `id` = 1443 AND `name` = 'RubySanctum'; + +-- Changes to locations of existing Teles +UPDATE `game_tele` SET `position_x` = 9214.63, `position_y` = -1110.82, `position_z` = 1216.12, `orientation` = 0.000729084, `map` = 571 WHERE `id` = 1406 AND `name` = 'Ulduar'; +UPDATE `game_tele` SET `position_x` = 5807.98, `position_y` = 588.487, `position_z` = 660.94, `orientation` = 1.66594, `map` = 571 WHERE `id` = 1398 AND `name` = 'Dalaran'; +UPDATE `game_tele` SET `position_x` = 5258.39, `position_y` = 156.958, `position_z` = 191.697, `orientation` = 6.03807, `map` = 571 WHERE `id` = 1490 AND `name` = 'CrystalsongForest'; +UPDATE `game_tele` SET `position_x` = 4857.14, `position_y` = 5529.11, `position_z` = -55.5802, `orientation` = 6.2518, `map` = 571 WHERE `id` = 1413 AND `name` = 'SholazarBasin'; +UPDATE `game_tele` SET `position_x` = 7374.96, `position_y` = 1991.1, `position_z` = 622.229, `orientation` = 2.79045, `map` = 571 WHERE `id` = 1407 AND `name` = 'Icecrown'; +UPDATE `game_tele` SET `position_x` = 7701.6, `position_y` = -696.182, `position_z` = 1196.38, `orientation` = 4.49486, `map` = 571 WHERE `id` = 1405 AND `name` = 'TheStormPeaks'; +UPDATE `game_tele` SET `position_x` = 4379.66, `position_y` = 1056.62, `position_z` = 150.566, `orientation` = 4.33733, `map` = 571 WHERE `id` = 1399 AND `name` = 'Dragonblight'; +UPDATE `game_tele` SET `position_x` = 3668.72, `position_y` = -1262.46, `position_z` = 243.622, `orientation` = 4.785, `map` = 571 WHERE `id` = 1463 AND `name` = 'NaxxramasOutside'; +UPDATE `game_tele` SET `position_x` = 3005.97, `position_y` = -3386.42, `position_z` = 299.55, `orientation` = 4.73338, `map` = 533 WHERE `id` = 654 AND `name` = 'Nax'; +UPDATE `game_tele` SET `position_x` = 5685.5, `position_y` = 493.516, `position_z` = 652.593, `orientation` = 4.03351, `map` = 571 WHERE `id` = 1415 AND `name` = 'TheVioletHold'; + +-- Adding New Teles +DELETE FROM `game_tele` WHERE `id` IN (1996,1995,1994,1993,1992,1991,1990,1989,1988,1987,1986,1985,1984,1983,1982,1981,1980,1979,1978,1977,1976,1975,1974,1973,1972,1971,1970,1969,1968,1967,1966,1965,1964,1963,1962,1961,1960,1959,1958,1957,1956,1955,1954,1953,1952,1951,1950,1949,1948,1947,1946,1945,1944,1943,1942,1941,1940,1939,1938,1937,1936,1935,1934,1933,1932,1931,1930,1929,1928,1927,1926,1925,1924,1923,1922,1921,1920,1919,1918,1917,1916,1915,1914,1913,1912,1911,1910,1909,1908,1907,1906,1905,1904,1903,1902,1901,1900,1899,1898,1897,1896,1895,1894,1893,1892,1891,1890,1889,1888,1887,1886,1885,1884,1883,1882,1881,1880,1879,1878,1877,1876,1875,1874,1873,1872,1871,1870,1869,1868,1867,1866,1865,1864,1863,1862,1861,1860,1859,1858,1857,1856,1855,1854,1853,1852,1851,1850,1849,1848,1847,1846,1845,1844,1843,1842,1841,1840,1839,1838,1837,1836,1835,1834,1833,1832,1831,1830,1829,1828,1827,1826,1825,1824,1823,1822,1821,1820,1819,1818,1817,1816,1815,1814,1813,1812,1811,1810,1809,1808,1807,1806,1805,1804,1803,1802,1801,1800,1799,1798,1797,1796,1795,1794,1793,1792,1791,1790,1789,1788,1787,1786,1785,1784,1783,1782,1781,1780,1779,1778,1777,1776,1775,1774,1773,1772,1771,1770,1769,1768,1767,1766,1765,1764,1763,1762,1761,1760,1759,1758,1757,1756,1755,1753,1752,1751,1750,1749,1748,1747,1746,1745,1744,1743,1742,1741,1740,1739,1738,1737,1736,1735,1734,1733,1732,1731,1730,1729,1728,1727,1726,1725,1724,1723,1722,1721,1720,1719,1718,1717,1716,1715,1714,1713,1712,1711,1710,1709,1708,1707,1706,1705,1704,1703,1702,1701,1700,1699,1698,1697,1696,1695,1694,1693,1692,1691,1690,1689,1688,1687,1686,1685,1684,1683,1682,1681,1680,1679,1678,1677,1676,1675,1674,1673,1672,1671,1670,1669,1665,1664,1663,1662,1661,1660,1659,1658,1657,1656,1655,1654,1653,1652,1651,1650,1649,1648,1646,1645,1644,1643,1642,1641,1640,1639,1638,1637,1636,1635,1634,1633,1632,1631,1630,1629,1628,1627,1626,1625,1624,1623,1622,1621,1620,1619,1618,1617,1616,1615,1614,1613,1612,1611,1610,1609,1608,1607,1606,1605,1604,1603,1602,1601,1600,1599,1598,1597,1596,1595,1594,1593,1592,1591,1590,1589,1588,1587,1586,1585,1584,1583,1582,1581,1580,1579,1578,1577,1576,1575,1574,1573,1572,1571,1570,1569,1568,1567,1566,1565,1564,1563,1562,1561,1560,1559,1558,1557,1556,1555,1554,1553,1552,1551,1550,1549,1548,1547,1546,1545,1544,1543,1542,1541,1540,1539,1538,1537,1536,1535,1534,1533,1532,1531,1529,1528,1527,1526,1525,1524,1523,1522,1520,1519,1518,1517,1516,1515,1514,1513,1512,1511,1510,1509,1508,1507,1506,1505,1504,1503,1502,1501,1500,1499,1498,1497,1496,1495,1494,1493,1492); +INSERT INTO `game_tele` (`id`, `position_x`, `position_y`, `position_z`, `orientation`, `map`, `name`) VALUES +-- Naxxramas Bosses +(1996, 3694.88, -5102, 142.031, 6.06658, 533, 'BossKelThuzad'), +(1995, 3508.07, -5297.3, 138.107, 1.38167, 533, 'BossSapphrion'), +(1994, 3440.84, -2999.21, 297.342, 0.767106, 533, 'BossThaddius'), +(1993, 3261.61, -3179.52, 297.697, 0.802449, 533, 'BossGluth'), +(1992, 3286.92, -3309.05, 292.596, 3.22933, 533, 'BossGrobbulus'), +(1991, 3115.55, -3140.86, 294.063, 0.0798831, 533, 'BossPatchwerk'), +(1990, 2549.22, -2978.79, 241.342, 2.35361, 533, 'BossTheFourHorsemen'), +(1989, 2686.89, -3390.9, 267.684, 3.15865, 533, 'BossGothikTheHarvester'), +(1988, 2819.62, -3099.78, 273.848, 3.1076, 533, 'BossInstructorRazuvious'), +(1987, 2909.6, -3975.38, 273.585, 4.7059, 533, 'BossLoatheb'), +(1986, 2808.89, -3682.28, 273.65, 4.00297, 533, 'BossHeiganTheUnclean'), +(1985, 2707.11, -3497.54, 261.996, 3.3393, 533, 'BossNothThePlaguebringer'), +(1984, 3461.93, -3869.97, 301.92, 5.58159, 533, 'BossMaexxna'), +(1983, 3350.53, -3640.92, 259.084, 1.42684, 533, 'BossGrandWidowFaerlina'), +(1982, 3245.79, -3476.99, 287.076, 6.26491, 533, 'BossAnubRekhan'), +-- Ulduar Bosses +(1981, 1906.81, -25.2215, 330.75, 6.22424, 603, 'BossYoggSaron'), +(1980, 1846.22, 150.219, 342.378, 4.732, 603, 'BossGeneralVezax'), +(1979, 2700.71, 2569.49, 364.314, 0.00390482, 603, 'BossMimiron'), +(1978, 2000.69, -186.973, 432.688, 4.68095, 603, 'BossHodir'), +(1977, 2135.35, -251.086, 419.743, 4.66132, 603, 'BossThorim'), +(1976, 2326.82, -48.131, 424.963, 4.92835, 603, 'BossFreya'), +(1975, 1913.55, -9.0797, 417.732, 6.20462, 603, 'BossAuriaya'), +(1974, 1770.04, -23.6213, 448.805, 6.26835, 603, 'BossKologarn'), +(1973, 1622.44, 117.544, 427.277, 3.18957, 603, 'BossSteelbreaker'), +(1972, 819.243, -10.9022, 409.804, 0.000738144, 603, 'BossXT002Deconstructor'), +(1971, 586.008, 259.144, 360.803, 1.57154, 603, 'BossIgnisTheFurnaceMaster'), +(1970, 589.184, -145.013, 391.517, 4.71314, 603, 'BossRazorscale'), +(1969, 332.943, -16.5407, 409.802, 6.27214, 603, 'BossFlameLeviathan'), +-- ICC Bosses +(1968, 516.458, -2124.64, 840.857, 3.15294, 631, 'BossTheLichKing'), +(1967, 4401.16, 2484.25, 203.375, 6.26747, 631, 'BossSindragosa'), +(1966, 4281.54, 2483.64, 365.591, 3.28689, 631, 'BossValithriaDreamwalker'), +(1965, 4610.78, 2769.24, 400.138, 6.26747, 631, 'BossBloodQueenLanathel'), +(1964, 4659.07, 2769.33, 361.352, 0.0117693, 631, 'BossPrinceCouncil'), +(1963, 4659.07, 2769.33, 361.352, 0.0117693, 631, 'BossPrinceValanarKelesethTaldaram'), +(1962, 4356.34, 3169.93, 389.399, 1.53545, 631, 'BossProfessorPutricide'), +(1961, 4445.64, 3092.77, 360.386, 1.55115, 631, 'BossRotface'), +(1960, 4268.18, 3095.11, 360.386, 1.57472, 631, 'BossFestergut'), +(1959, -559.589, 2211.55, 539.286, 6.27241, 631, 'BossDeathbringerSaurfang'), +(1958, -467.294, 2466.7, 190.462, 3.10332, 631, 'BossMuradinBronzebeard'), +(1957, -474.192, 1916.34, 216.332, 3.17401, 631, 'BossHighOverlordSaurfang'), +(1956, -625.631, 2211.41, 51.7989, 3.12687, 631, 'BossLadyDeathwhisper'), +(1955, -358.348, 2209.58, 42.3155, 3.19756, 631, 'BossLordMarrowgar'), +-- Instances (Raids/ZoneID) +(1954, 3274, 533.531, 87.665, 3.16, 724, 'Instance4987'), +(1953, 3274, 533.531, 87.665, 3.16, 724, 'TheRubySanctumInstance'), +(1952, 65.7692, 2211.28, 30, 3.14651, 631, 'ICCInstance'), +(1951, 65.7692, 2211.28, 30, 3.14651, 631, 'Instance4812'), +(1950, 65.7692, 2211.28, 30, 3.14651, 631, 'IceCrownCitadelInstance'), +(1949, 29.1607, -71.3372, -8.18032, 4.58, 249, 'Instance2159'), +(1948, 29.1607, -71.3372, -8.18032, 4.58, 249, 'OnyxiasLairInstance'), +(1947, 563.61, 80.6815, 395.2, 1.59, 649, 'TotCInstance'), +(1946, 563.61, 80.6815, 395.2, 1.59, 649, 'Instance4722'), +(1945, 563.61, 80.6815, 395.2, 1.59, 649, 'TrialOfTheCrusaderInstance'), +(1944, -914.041, -148.98, 463.137, 6.28, 603, 'Instance4273'), +(1943, -914.041, -148.98, 463.137, 6.28, 603, 'UlduarInstance'), +(1942, 728.055, 1329.03, 267.235, 5.51524, 616, 'Instance4500'), +(1941, 728.055, 1329.03, 267.235, 5.51524, 616, 'TheEyeOfEternityInstance'), +(1940, -505.96, -103.353, 157, 0, 624, 'Instance4603'), +(1939, -505.96, -103.353, 157, 0, 624, 'VaultOfArchavonInstance'), +(1938, 3228.58, 385.86, 65.5484, 1.578, 615, 'Instance4493'), +(1937, 3228.58, 385.86, 65.5484, 1.578, 615, 'TheObsidianSanctumInstance'), +(1936, 3019.34, -3434.36, 293.99, 6.27, 533, 'Instance3456'), +(1935, 3019.34, -3434.36, 293.99, 6.27, 533, 'NaxxramasInstance'), +-- Instances (Dungeons/ZoneID) +(1934, 4922.86, 2175.63, 638.734, 2.00355, 632, 'Instance4809'), +(1933, 4922.86, 2175.63, 638.734, 2.00355, 632, 'TheForgeOfSoulsInstance'), +(1932, 435.743, 212.413, 528.709, 6.25646, 658, 'Instance4813'), +(1931, 435.743, 212.413, 528.709, 6.25646, 658, 'PitOfSaronInstance'), +(1930, 5239.01, 1932.64, 707.695, 0.800565, 668, 'Instance4820'), +(1929, 5239.01, 1932.64, 707.695, 0.800565, 668, 'HallsOfReflectionInstance'), +(1928, 804.065, 618.033, 412.393, 3.1456, 650, 'ToCInstance'), +(1927, 804.065, 618.033, 412.393, 3.1456, 650, 'ChampInstance'), +(1926, 804.065, 618.033, 412.393, 3.1456, 650, 'Instance4723'), +(1925, 804.065, 618.033, 412.393, 3.1456, 650, 'TrialOfTheChampionInstance'), +(1924, 1431.1, 556.92, 36.69, 4.96991, 595, 'COSInstance'), +(1923, 1431.1, 556.92, 36.69, 4.96991, 595, 'CullingInstance'), +(1922, 1431.1, 556.92, 36.69, 4.96991, 595, 'Instance4100'), +(1921, 1431.1, 556.92, 36.69, 4.96991, 595, 'TheCullingOfStratholmeInstance'), +(1920, 582.731, -327.947, 110.139, 3.122, 575, 'Instance1196'), +(1919, 582.731, -327.947, 110.139, 3.122, 575, 'UtgardePinnacleInstance'), +(1918, 1153.24, 806.164, 195.937, 4.715, 599, 'Instance4264'), +(1917, 1153.24, 806.164, 195.937, 4.715, 599, 'HallsOfStoneInstance'), +(1916, 1894.58, 652.713, 176.666, 4.078, 604, 'Instance4416'), +(1915, 1894.58, 652.713, 176.666, 4.078, 604, 'GundrakInstance'), +(1914, 1808.82, 803.93, 44.364, 6.282, 608, 'Instance4415'), +(1913, 1808.82, 803.93, 44.364, 6.282, 608, 'TheVioletHoldInstance'), +(1912, -517.343, -487.976, 11.0099, 4.93467, 600, 'Instance4196'), +(1911, -517.343, -487.976, 11.0099, 4.93467, 600, 'DrakTharonInstance'), +(1910, 339.113, -1105.97, 64.5518, 0.603778, 619, 'Instance4494'), +(1909, 339.113, -1105.97, 64.5518, 0.603778, 619, 'AhnkahetInstance'), +(1908, 413.314, 795.968, 831.351, 5.5, 601, 'Instance4277'), +(1907, 413.314, 795.968, 831.351, 5.5, 601, 'AzjolNerubInstance'), +(1906, 145.87, -10.554, -16.6361, 1.528, 576, 'Instance4265'), +(1905, 145.87, -10.554, -16.6361, 1.528, 576, 'TheNexusInstance'), +(1904, 1055.93, 986.85, 361.07, 5.8738, 578, 'Instance4428'), +(1903, 1055.93, 986.85, 361.07, 5.8738, 578, 'TheOculusInstance'), +(1902, 153.789, -86.548, 12.551, 0.304, 574, 'Instance206'), +(1901, 153.789, -86.548, 12.551, 0.304, 574, 'UtgardeKeepInstance'), +-- Howling Fjord +(1900, 976.845, -5468.45, 187.242, 4.18982, 571, 'Nifflevar'), +(1899, 969.743, -4425.3, 152.014, 2.97618, 571, 'Halgrind'), +(1898, 386.3, -4231.49, 250.998, 2.90157, 571, 'ThorvaldsCamp'), +(1897, 974.166, -3893.34, 176.66, 6.00781, 571, 'EmberClutch'), +(1896, 775.187, -4034.94, 206.663, 4.61767, 571, 'EmberSpearTower'), +(1895, 712.759, -3808.51, 251.035, 2.67773, 571, 'TheAncientLift'), +(1894, 1351.31, -2765.79, 4.73287, 3.63987, 571, 'ShatteredStraits'), +(1893, 1589.97, -3472.51, 163.027, 0.258715, 571, 'WhisperGulch'), +(1892, 616.172, -3402.42, 67.9472, 4.34836, 571, 'TheIsleOfSpears'), +(1891, 163.423, -3292.19, 0.348844, 4.89419, 571, 'TwinShores'), +(1890, 422.335, -3752.92, 1.70311, 1.64657, 571, 'SorlofsStrand'), +(1889, 453.997, -4014.72, 268.52, 2.34951, 571, 'WestwindLift'), +(1888, 88.063, -3423.07, 9.96335, 3.40193, 571, 'GarvansReef'), +(1887, -136.685, -3553.48, 2.33788, 4.22266, 571, 'ScalawagPoint'), +(1886, -42.5513, -4692.24, 260.238, 2.95424, 571, 'ExcavationLift'), +(1885, -41.9164, -5026.52, 314.267, 4.57609, 571, 'ShieldHill'), +(1884, 832.82, -5536.65, 2.35336, 1.68832, 571, 'DaggercapBay'), +(1883, 190.259, -5790.33, 85.8658, 4.46075, 571, 'BaelgunsExcavationSite'), +(1882, 433.677, -6100.82, 315.713, 4.61782, 571, 'StonewallLift'), +(1881, 476.711, -5920.39, 308.72, 5.06943, 571, 'ExplorersLeagueOutpost'), +(1880, 965.385, -5987.9, 280.311, 4.60212, 571, 'MidwallLift'), +(1879, 1210.86, -6212.92, 256.906, 1.4566, 571, 'IvaldsRuin'), +(1878, 1458.13, -6353.72, 8.54294, 4.78668, 571, 'DerelictStrand'), +(1877, 1738.37, -5968.56, 6.96339, 5.63886, 571, 'BleedingVale'), +(1876, 1608.33, -5756.91, 256.771, 5.52105, 571, 'VengeanceLift'), +(1875, 1506.48, -5609.05, 226.791, 2.67399, 571, 'BalejarWatch'), +(1874, 1503.1, -5264.78, 206.775, 2.12813, 571, 'Baleheim'), +(1873, 1572.71, -4963.87, 143.133, 3.09025, 571, 'CauldrosIsle'), +(1872, 1670.78, -4612.64, 120.971, 3.9267, 571, 'LakeCauldros'), +(1871, 1684.48, -4114.81, 271.105, 0.223537, 571, 'Skorn'), +(1870, 2068.87, -4522.56, 211.568, 3.57719, 571, 'TheVibrantGlade'), +(1869, 2178.2, -4683.51, 215.523, 0.235324, 571, 'NorthSpearTower'), +(1868, 2429.95, -4643.19, 226.413, 3.61646, 571, 'TheTwistedGlade'), +(1867, 2218.09, -5113.87, 237.372, 2.84285, 571, 'TheFrozenGlade'), +(1866, 2311.32, -5146.06, 251.091, 5.41895, 571, 'CaldemereLake'), +(1865, 2098.94, -5775.22, 223.157, 4.54324, 571, 'GiantsRun'), +(1864, 2836.87, -5902.29, 274.566, 3.96598, 571, 'TheBrokenBluffs'), +(1863, 2696.08, -5441.9, 416.088, 2.83107, 571, 'FrostbladePeak'), +(1862, 2568.28, -5012.63, 294.664, 5.66246, 571, 'WildervarMine'), +(1861, 2322.54, -3954.91, 218.263, 4.07771, 571, 'WintersBreathLake'), +(1860, 2383.11, -3310.57, 152.833, 0.323502, 571, 'Rivenwood'), +(1859, 2865.05, -3885.04, 248.529, 2.16526, 571, 'WintersTerrace'), +(1858, 2709.33, -3638.37, 232.904, 2.15348, 571, 'Gjalerbron'), +(1857, 2117.37, -3304.95, 147.385, 2.79356, 571, 'SteelGate'), +(1856, 2151.87, -2706.89, 6.8216, 2.64041, 571, 'ChillmereCoast'), +(1855, 2134.33, -2979.44, 148.544, 3.19411, 571, 'ApothecaryCamp'), +-- Dragonblight +(1854, 2530.41, 1702.8, 127.07, 5.57824, 571, 'TheBrinyPinnacle'), +(1853, 3480.38, 2951.22, 29.787, 2.16177, 571, 'ColdwindPass'), +(1852, 3735.05, 2869.61, 92.7331, 6.2262, 571, 'WestwindRefugeeCamp'), +(1851, 3404.86, 2460.02, 58.1013, 2.73509, 571, 'MoonrestGardens'), +(1850, 3480.7, 2000.06, 64.975, 5.92773, 571, 'StarsRest'), +(1849, 3968.96, 2229.36, 153.402, 3.2574, 571, 'IcemistVillage'), +(1848, 4383.8, 1368.28, 146.37, 1.60806, 571, 'ObsidianDragonshrine'), +(1847, 4387.59, 1545.65, 138.711, 1.39993, 571, 'MawOfNeltharion'), +(1846, 3841.51, 1534.04, 89.7246, 4.78105, 571, 'AgmarsHammer'), +(1845, 3354.49, 1039.8, 141.402, 6.183, 571, 'SnowfallGlade'), +(1844, 3083.37, 1471.81, 148.902, 4.15276, 571, 'LakeIndule'), +(1843, 2908.95, 1484.6, 156.878, 5.81388, 571, 'InduleVillage'), +(1842, 3818.46, 933.553, 56.9857, 2.74298, 571, 'RubyDragonshrine'), +(1841, 4231.09, 18.8035, 69.4327, 5.14024, 571, 'TheDragonWastes'), +(1840, 2863.16, 66.4786, 0.781584, 3.35738, 571, 'EmeraldDragonshrine'), +(1839, 2964.01, 553.736, 97.8648, 5.87458, 571, 'AzureDragonshrine'), +(1838, 3556.22, 264.514, 342.722, 2.53185, 571, 'WyrmrestTemple'), +(1837, 3608.34, -128.986, 59.6741, 4.48356, 571, 'TheMirrorOfDawn'), +(1836, 4013.97, -335.498, 132.835, 5.45354, 571, 'BronzeDragonshrine'), +(1835, 3477.32, -963.915, 143.061, 1.68657, 571, 'VengeancePass'), +(1834, 3241.29, -699.767, 166.985, 5.3583, 571, 'Venomspite'), +(1833, 2760.75, -345.15, 138.634, 3.27698, 571, 'NewHearthglen'), +(1832, 2556.21, -386.928, 3.09721, 5.9159, 571, 'CrusadersLanding'), +(1831, 2975.9, -1006.61, 14.7403, 3.61861, 571, 'TheForgottenShore'), +(1830, 3207.84, -1560.6, 43.9224, 5.51928, 571, 'DragonspineTributary'), +(1829, 2945.99, -1414.55, 60.1215, 2.84499, 571, 'EldritchHeights'), +(1828, 3674.81, -1366.92, 129.625, 1.64728, 571, 'TheCarrionFields'), +(1827, 3704.55, -1187.99, 121.055, 4.30192, 571, 'WintergardeMausoleum'), +(1826, 3853.27, -1379.23, 143.756, 5.88843, 571, 'ThorsonsPost'), +(1825, 4147.24, -1281.53, 165.627, 5.42113, 571, 'OnslaughtBaseCamp'), +(1824, 4544.47, -1352.48, 156.723, 0.00187922, 571, 'Jinthakalar'), +(1823, 4585.39, -1059.07, 165.072, 1.56876, 571, 'LightsTrust'), +(1822, 4692.14, -540.826, 169.499, 5.22091, 571, 'FrostmourneCavern'), +(1821, 4714.4, -433.742, 177.143, 2.44453, 571, 'ScarletPoint'), +(1820, 4670.02, -368.448, 213.859, 0.889421, 571, 'ScarletTower'), +(1819, 4343.89, 976.371, 90.6862, 2.40132, 571, 'DragonsFall'), +(1818, 4700.41, 551.307, 122.672, 3.548, 571, 'NozzlerustPost'), +(1817, 4253.56, 338.546, 66.2099, 1.29783, 571, 'GalakrondsRest'), +(1816, 4520.64, 4.94384, 72.4321, 5.0599, 571, '7thLegionFront'), +(1815, 4872.14, 156.47, 99.5612, 3.3438, 571, 'TheCrystalVice'), +(1814, 5049.35, 115.582, 285.378, 4.2745, 571, 'PathOfTheTitans'), +(1813, 5190.75, 1038.03, 229.375, 0.885501, 571, 'ColdwindHeights'), +(1812, 4897.85, 1352.22, 230.933, 2.23246, 571, 'KorkronVanguard'), +(1811, 4595.02, 1435.48, 189.187, 0.064754, 571, 'FordragonHold'), +(1810, 4695.51, 1264.93, 144.148, 0.8855, 571, 'TheCourtOfSkulls'), +(1809, 4906.47, 1527.25, 219.974, 4.02316, 571, 'AngratharTheWrathgate'), +-- Grizzly Hills +(1808, 3848.7, -4543.46, 209.278, 1.46236, 571, 'CampOneqwah'), +(1807, 4262.61, -2983.02, 310.169, 2.2301, 571, 'BlueSkyLoggingGrounds'), +(1806, 4378.16, -2505.15, 246.418, 0.184134, 571, 'Silverbrook'), +(1805, 3939.2, -2612.27, 211.497, 5.38738, 571, 'VordrassilsTears'), +(1804, 4250.66, -1984.45, 206.711, 4.59415, 571, 'ZebHalak'), +(1803, 4212.34, -1871.36, 204.452, 3.17651, 571, 'ZimbosHideout'), +(1802, 3837.16, -1949.98, 208.549, 5.63087, 571, 'GraniteSprings'), +(1801, 3251.86, -2244.98, 114.555, 1.20122, 571, 'ConquestHold'), +(1800, 3280.87, -2583.1, 52.9869, 1.05593, 571, 'BlackriverLoggingCamp'), +(1799, 3375.57, -1807.81, 114.167, 5.68979, 571, 'RuinsOfDrakZin'), +(1798, 3208.15, -1966.09, 86.0497, 0.753556, 571, 'EvergreenTradingPost'), +(1797, 2792.2, -1972.36, 10.8207, 2.59138, 571, 'VentureBay'), +(1796, 2903.43, -2666.82, 84.794, 1.84526, 571, 'Voldrune'), +(1795, 3150.29, -3003.11, 134.354, 4.02865, 571, 'ForestsEdgePost'), +(1794, 3579.31, -2936.16, 235.545, 3.04487, 571, 'AspenGrovePost'), +(1793, 3701.38, -3246.06, 284.015, 3.6457, 571, 'VordrassilsHeart'), +(1792, 3926.91, -3432.28, 288.524, 3.37088, 571, 'VordrassilPass'), +(1791, 4070.65, -4396.67, 260.483, 1.9768, 571, 'SolsticeVillage'), +(1790, 4104.24, -4730.87, 100.787, 4.96131, 571, 'RedwoodTradingPost'), +(1789, 4069.37, -4149.7, 211.326, 1.321, 571, 'WhitePineTradingPost'), +(1788, 4096.92, -3828.53, 221.792, 2.56195, 571, 'Grizzlemaw'), +(1787, 3664.25, -4003.14, 178.315, 0.186114, 571, 'RageFangShrine'), +(1786, 3682.97, -4254.79, 193.184, 1.2464, 571, 'AshwoodPost'), +(1785, 3390.78, -4606.09, 231.508, 3.36305, 571, 'HeartsBloodShrine'), +(1784, 3253.62, -4505.13, 339.378, 5.82921, 571, 'TheForgottenOverlook'), +(1783, 3354.7, -5083.21, 325.288, 3.80682, 571, 'DunArgol'), +(1782, 4215.73, -5326.97, 11.9034, 0.622016, 571, 'RuinsOfTethys'), +(1781, 4620.51, -5652.22, 110.528, 4.21931, 571, 'ShadowfangTower'), +(1780, 4607.06, -4865.96, 48.0641, 0.00564718, 571, 'DrakiljinRuins'), +(1779, 4920.96, -4563.4, 219.554, 4.33318, 571, 'ThorModan'), +(1778, 4529.59, -4233.93, 170.185, 0.221619, 571, 'WestfallBrigadeEncampment'), +(1777, 4850.77, -3836.81, 338.689, 6.20242, 571, 'UrsocsDen'), +(1776, 4509.47, -3482.06, 226.932, 0.775326, 571, 'DrakatalPassage'), +(1775, 4347.96, -3679.87, 256.372, 3.64988, 571, 'HeartwoodTradingPost'), +-- Crytalsong Forest +(1768, 5595.35, -704.415, 206.626, 1.06257, 571, 'SunreaversCommand'), +(1767, 5057.03, -560.349, 220.132, 5.96739, 571, 'WindrunnersOverlook'), +(1766, 5291.85, -729.117, 162.904, 6.27369, 571, 'RuinsOfShandaral'), +(1765, 5508, -384.533, 170.492, 5.15056, 571, 'TheUnboundThicket'), +(1764, 5842.22, 785.206, 149.071, 2.04037, 571, 'TheTwilightRivulet'), +(1763, 5728.56, 205.439, 181.593, 2.41343, 571, 'ForlornWoods'), +(1762, 5522.5, 115.187, 148.671, 2.78651, 571, 'TheMirrorOfTwilight'), +(1761, 5576.85, 730.087, 158.475, 3.04179, 571, 'TheAzureFront'), +(1760, 5744.35, 1017.14, 174.48, 3.39524, 571, 'VioletStand'), +(1759, 5818.74, 1089.68, 198.347, 6.2266, 571, 'TheGreatTree'), +(1758, 6158.07, 913.136, 148.881, 0.885881, 571, 'TheDecrepitFlow'), +-- Crytalsong Forest (Dalaran) +(1757, 5761.53, 736.624, 641.698, 2.63982, 571, 'SistersSorcerous'), +(1756, 5922.4, 566.631, 609.825, 5.58114, 571, 'TheBlackMarket'), +(1755, 5804.89, 640.08, 609.887, 1.00618, 571, 'CircleOfWills'), +(1753, 5650.68, 856.348, 570.438, 2.4749, 571, 'TheUnderbellyExit'), +(1752, 5772.59, 705.993, 618.721, 2.46311, 571, 'CantripsCrows'), +(1751, 5804.89, 640.08, 609.887, 1.00618, 571, 'DalaranSewer'), +(1750, 5814.48, 769.885, 639.241, 1.74838, 571, 'TheUnderbellyWest'), +(1749, 5798.26, 546.654, 648.213, 4.05745, 571, 'TheUnderbellyEast'), +(1748, 5795.23, 770.997, 661.279, 1.47744, 571, 'TheVioletCitadel'), +(1747, 5700.74, 761.688, 647.664, 5.589, 571, 'TheSilverEnclave'), +(1746, 5637.25, 740.106, 641.684, 5.81284, 571, 'TheBeerGarden'), +(1745, 5726.92, 682.248, 646.564, 2.4317, 571, 'AHerosWelcome'), +(1744, 5654.86, 682.2, 652.006, 2.69087, 571, 'DalaranMerchantsBank'), +(1743, 5666.24, 645.034, 647.98, 3.47627, 571, 'TheMilitantMystic'), +(1742, 5669.53, 628.231, 648.106, 3.67262, 571, 'LangromsLeatherLinks'), +(1741, 5682.33, 615.55, 648.237, 3.76687, 571, 'GloriousGoods'), +(1740, 5700.25, 641.774, 646.28, 3.51554, 571, 'TheEventide'), +(1739, 5726.38, 602.7, 648.54, 4.06925, 571, 'TheArsernalAbsolute'), +(1738, 5769.84, 632.804, 661.076, 3.18961, 571, 'CuriositiesMoore'), +(1737, 5805.09, 676.243, 658.032, 1.75626, 571, 'TheThreadsOfFate'), +(1736, 5812.08, 689.954, 647.046, 4.45411, 571, 'TheWonderworks'), +(1735, 5840.61, 647.844, 658.404, 0.0912267, 571, 'TheLedgerdemainLounge'), +(1734, 5757.44, 621.777, 650.091, 0.460362, 571, 'DalaranVisitorCenter'), +(1733, 5809.02, 579.559, 652.756, 1.66201, 571, 'TheVioletGate'), +(1732, 5778.72, 556.013, 651.639, 4.02756, 571, 'TheHuntersReach'), +(1731, 5813.84, 449.122, 658.752, 1.16086, 571, 'KrasusLanding'), +(1730, 5848.54, 566.409, 652.657, 5.62583, 571, 'MagicalMenagerie'), +(1729, 5886.87, 514.771, 641.57, 4.93077, 571, 'TheFilthyAnimal'), +(1728, 5908.21, 540.531, 649.94, 2.47248, 571, 'SunreaversSanctuary'), +(1727, 5885.77, 606.631, 650.294, 5.618, 571, 'OneMoreGlass'), +(1726, 5890.33, 621.467, 649.383, 5.62193, 571, 'Barbershop'), +(1725, 5958.08, 617.286, 650.627, 5.90074, 571, 'TheBankOfDalaran'), +(1724, 5947.99, 664.679, 641.227, 1.21196, 571, 'AntonidasMemorial'), +(1723, 5905.42, 680.836, 643.496, 5.53165, 571, 'TanksForEverything'), +(1722, 5860.97, 702.897, 643.276, 0.956697, 571, 'TheScribesSacellum'), +(1721, 5874.33, 719.983, 643.116, 4.97401, 571, 'CartierCoFineJewelry'), +(1720, 5890.16, 703.427, 643.239, 4.01976, 571, 'TheAgronomicalApothecary'), +(1719, 5881.62, 747.392, 640.372, 1.85205, 571, 'TalismanicTextiles'), +(1718, 5903.79, 752.506, 641.048, 1.33761, 571, 'LegendaryLeathers'), +(1717, 5922.9, 728.071, 642.135, 6.22279, 571, 'LikeClockwork'), +(1716, 5921.77, 709.744, 642.515, 6.22279, 571, 'AllThatGlittersProspectingCo'), +(1715, 5915.89, 694.852, 642.426, 5.73584, 571, 'ForgeOfFate'), +(1714, 5894.9, 719.209, 640.544, 0.854603, 571, 'MagusCommerceExchange'), +(1713, 5804.04, 657.739, 648.141, 4.85228, 571, 'RuneweaverSquare'), +-- Zul'Drak +(1712, 5754.5, -2939.17, 286.276, 5.17592, 571, 'AmphitheaterOfAnguish'), +(1711, 5506.12, -2773.37, 274.379, 4.81857, 571, 'DrakAgal'), +(1710, 6084, -2080.68, 422.947, 0.583579, 571, 'Voltarus'), +(1709, 6071.19, -1945.42, 235.752, 5.5209, 571, 'ReliquaryOfPain'), +(1708, 5950.3, -1826.16, 248.309, 4.6766, 571, 'DargathsDemise'), +(1707, 5620.84, -1661.04, 242.363, 5.07322, 571, 'TheDeadFields'), +(1706, 5653.61, -1402.88, 234.446, 1.03628, 571, 'ThrymsEnd'), +(1705, 5228.59, -1328.17, 242.364, 2.37145, 571, 'EbonWatch'), +(1704, 5273.84, -1694.88, 429.14, 2.9173, 571, 'Zeramas'), +(1703, 5217.57, -1588.56, 239.176, 4.29569, 571, 'ReliquaryOfAgony'), +(1702, 4768.23, -2438.55, 235.542, 5.49402, 571, 'RageclawLake'), +(1701, 4977.99, -2299.54, 245.837, 3.76615, 571, 'RageclawDen'), +(1700, 5154.52, -2188.33, 236.538, 4.48478, 571, 'LightsBreach'), +(1699, 5203.09, -3199.7, 273.816, 2.34064, 571, 'DrakSotra'), +(1698, 5031.48, -3608.56, 299.963, 5.13666, 571, 'Kolramas'), +(1697, 4976.34, -2666.44, 289.707, 5.51365, 571, 'DrakSotraFields'), +(1696, 5277.93, -2433.96, 290.05, 3.14174, 571, 'ZimAbwa'), +(1695, 5450.38, -2422.65, 292.419, 4.6929, 571, 'TheArgentStand'), +(1694, 5675.91, -2507.03, 287.433, 2.49378, 571, 'PoolsOfZhaJin'), +(1693, 5929.82, -2414.55, 293.403, 1.57487, 571, 'HebValok'), +(1692, 6205.11, -2620.46, 293.168, 6.27548, 571, 'AltarOfSseratus'), +(1691, 6276.62, -3264.6, 376.07, 0.0276335, 571, 'AltarOfRhunok'), +(1690, 6071.54, -3369.12, 350.617, 1.69268, 571, 'DrakMabwa'), +(1689, 6909.43, -4111.03, 467.354, 2.22675, 571, 'DubraJin'), +(1688, 6461.61, -3900.62, 482.288, 6.27547, 571, 'ZolMazStronghold'), +(1687, 6087.96, -3469.78, 365.552, 5.50187, 571, 'ZimRhuk'), +(1686, 5889.7, -3782.53, 361.962, 5.53329, 571, 'HebDrakkar'), +(1685, 5757.21, -3528.22, 388.185, 4.71648, 571, 'ZimTorga'), +(1684, 5569.49, -3447.85, 350.442, 3.95464, 571, 'PoolsOfJinAlai'), +(1683, 5376.1, -3732.46, 360.095, 3.91143, 571, 'AltarOfHarkoa'), +(1682, 5716.33, -4302.82, 373.996, 4.73609, 571, 'AltarOfQuetzlun'), +(1681, 6096.32, -4244.25, 319.05, 2.99251, 571, 'MamtothCrater'), +(1680, 6310.73, -4249.27, 447.474, 3.12603, 571, 'AltarOfMamtoth'), +(1679, 6499.12, -4481.15, 454.953, 3.02393, 571, 'ZolHeb'), +-- Wintergrasp +(1678, 4372.54, 1791.25, 356.766, 3.11312, 571, 'TheCauldronOfFlames'), +(1677, 4774.84, 2015.98, 424.402, 6.27041, 571, 'GlacialFalls'), +(1676, 4693.02, 3309.75, 374.64, 5.99946, 571, 'WesternBridge'), +(1675, 4607.97, 2846.56, 396.896, 0.179658, 571, 'CentralBridge'), +(1674, 4970.23, 2425.01, 320.791, 2.39449, 571, 'TheSunkenRing'), +(1673, 4607.46, 2368.2, 379.028, 0.434927, 571, 'EasternBridge'), +(1672, 4447.06, 2015, 434.694, 0.804061, 571, 'FlamewatchTower'), +(1671, 4403.72, 2380.28, 376.318, 5.73244, 571, 'EastsparkWorkshop'), +(1670, 4437.6, 2833.36, 405.225, 5.93272, 571, 'WintersEdgeTower'), +(1669, 4396.97, 3320.53, 372.424, 5.17873, 571, 'WestsparkWorkshop'), +(1665, 4589.59, 3560.4, 392.277, 4.29124, 571, 'ShadowsightTower'), +(1664, 4457.95, 3927.66, 411.536, 6.03089, 571, 'TheSteppeOfLife'), +(1663, 4803.77, 3801.29, 356.158, 5.84632, 571, 'TheForestOfShadows'), +(1662, 4991.69, 3333.74, 376.877, 3.54903, 571, 'TheBrokenTemple'), +(1661, 5178.08, 3420.28, 356.525, 4.18128, 571, 'TheChilledQuagmire'), +(1660, 5348.02, 2839.27, 409.239, 0.038305, 571, 'WintergraspFortress'), +-- The Storm Peaks +(1774, 6657, -1441, 682.935, 1.60449, 571, 'SnowblindTerrace'), +(1773, 6463, -1292, 466.597, 2.93967, 571, 'SnowblindHills'), +(1772, 7096, -918, 1067, 2.48807, 571, 'TheBroodmothersNext'), +(1771, 7843.9, -796.826, 1183.4, 4.79714, 571, 'GromarshCrashSite'), +(1659, 6327.28, -1576.64, 425.267, 5.7436, 571, 'Garm'), +(1658, 6327.91, -1320.87, 428.324, 4.6951, 571, 'GarmsBane'), +(1657, 6114.87, -581.335, 383.725, 3.86257, 571, 'SparksocketMinefield'), +(1656, 6472.49, -1040.14, 433.549, 0.0180354, 571, 'CrystalwebCavern'), +(1655, 6091.97, -932.899, 387.132, 4.44377, 571, 'RicketsFolly'), +(1654, 6123.7, -1059.19, 402.624, 4.65975, 571, 'K3'), +(1653, 8618.31, -622.963, 926.204, 2.47396, 571, 'TempleOfWisdom'), +(1652, 8186.44, -1934.66, 1738.48, 5.2896, 571, 'TempleOfOrder'), +(1651, 7528.82, -1906.84, 1473.62, 2.94125, 571, 'TempleOfWinter'), +(1650, 7890.03, -1418.43, 1534.06, 2.45823, 571, 'TempleOfInvention'), +(1649, 7771.56, -1772.27, 1279.5, 5.09325, 571, 'TerraceOfTheMakers'), +(1648, 8095.7, -2242.73, 1206.33, 1.27074, 571, 'HallOfTheShaper'), +(1646, 7934.5, -2582.04, 1154.45, 5.46475, 571, 'PlainOfEchoes'), +(1645, 8060.57, -2917.89, 1140.24, 5.67679, 571, 'TheHowlingHollow'), +(1644, 7977.41, -2680.05, 1138, 4.96209, 571, 'TempleOfLife'), +(1643, 7808.82, -2949.29, 1257.53, 4.11778, 571, 'CampTunkalo'), +(1642, 7776.83, -3202.63, 868.409, 6.05771, 571, 'Thunderfall'), +(1641, 7210.23, -3379.79, 845.316, 4.68326, 571, 'FjornsAnvil'), +(1640, 7393.51, -3247.05, 850.774, 1.29822, 571, 'FrostfieldLake'), +(1639, 7165.42, -2729.01, 776.77, 0.347884, 571, 'DunNiffelem'), +(1638, 7152.8, -2134.07, 761.915, 0.253633, 571, 'HibernalCavern'), +(1637, 7111.28, -2059.48, 766.21, 4.54192, 571, 'ValleyOfAncientWinters'), +(1636, 7056.37, -1698, 821.595, 3.61516, 571, 'BrunnhildarVillage'), +(1635, 6962.97, -1655.72, 810.822, 3.57196, 571, 'ThePitOfTheFang'), +(1634, 6933.2, -1351.58, 831.134, 1.70664, 571, 'TheForlomMine'), +(1633, 6840.09, -1061.41, 804.305, 2.93971, 571, 'SifreldarVillage'), +(1632, 7521.46, -899.843, 909.642, 4.72649, 571, 'EngineOfTheMakers'), +(1631, 7154.05, -754.211, 890.867, 5.41765, 571, 'AbandonedCamp'), +(1630, 6725.91, -783.269, 730.959, 0.163331, 571, 'BorsBreath'), +(1629, 7411.71, -531.622, 1896.85, 6.18734, 571, 'TempleOfStorms'), +(1628, 7243.53, -461.666, 916.621, 0.00232267, 571, 'Uldis'), +(1627, 6666.43, -211.341, 947.816, 1.56526, 571, 'Frosthold'), +(1626, 6768.53, -58.3224, 740.45, 1.49458, 571, 'RohemdalPass'), +(1625, 7393.04, 167.78, 770.688, 0.277205, 571, 'TheBlightedPool'), +(1624, 7335.99, -62.7787, 772.723, 2.46849, 571, 'Valkyrion'), +(1623, 7843.14, -110.96, 882.857, 2.24857, 571, 'TheFrozenMine'), +(1622, 7767.64, 29.2474, 1009.34, 0.120142, 571, 'Nidavelir'), +(1621, 7988.62, -291.5, 847.385, 5.69254, 571, 'NarvirsCradle'), +(1620, 8360.21, -139.844, 827.823, 6.25804, 571, 'SnowdriftPlains'), +-- Icecrown +(1770, 6319.63, 1740.14, 525, 0.0847461, 571, 'MalykrissTheVileHold'), +(1769, 6204, 2606, 570, 1.95007, 571, 'CathedralOfDarkness'), +(1619, 6216.68, -2.72999, 410.165, 0.391102, 571, 'TheArgentVanguard'), +(1618, 6244.26, 225.228, 387.66, 5.3116, 571, 'ValleyOfEchoes'), +(1617, 6447.27, 239.528, 397.736, 3.65834, 571, 'TheBreach'), +(1616, 6362.92, 1012.17, 327.467, 3.5798, 571, 'IronwallDam'), +(1615, 6873.3, 1174.87, 283.413, 3.61907, 571, 'TheBrokenFront'), +(1614, 7594.92, 1350.4, 333.679, 1.70663, 571, 'FirstLegionFowardCamp'), +(1613, 7678.03, 1372.25, 345.455, 2.71194, 571, 'TheValleyOfLostHope'), +(1612, 7497.14, 2598.56, 534.671, 3.43842, 571, 'IronwallRampart'), +(1611, 7233.18, 2971.8, 433.708, 5.13096, 571, 'IcecrownGlacier'), +(1610, 7841.6, 2274.98, 378.063, 3.79579, 571, 'TheValleyOfFallenHeroes'), +(1609, 7705.46, 1818.86, 354.901, 4.15315, 571, 'TheBombardment'), +(1608, 6749.04, 2544.51, 426.1, 0.383241, 571, 'TheConflagration'), +(1607, 6286.64, 2294.73, 481.885, 3.50913, 571, 'TheCourtOfBones'), +(1606, 8130.79, 437.999, 574.684, 0.30234, 571, 'SilentVigil'), +(1605, 10406.6, 915.842, 123.528, 1.88887, 571, 'HrothgarsLanding'), +(1604, 8103, 785.057, 481.016, 5.99883, 571, 'QuelDelarsRest'), +(1603, 7819.14, 1017.74, 449.338, 1.52599, 571, 'SindragosasFall'), +(1602, 7185.36, 609.466, 495.828, 1.16863, 571, 'ThePitOfFiends'), +(1601, 6809.66, 427.36, 465.349, 2.99863, 571, 'Scourgeholme'), +(1600, 6974.72, 1216.42, 415.465, 6.10879, 571, 'MordretharTheDeathGate'), +(1599, 7932.5, 2057.79, 500.268, 3.15567, 571, 'AldurtharTheDesolationGate'), +(1598, 7025.57, 1884.51, 532.252, 1.78908, 571, 'SaroniteMines'), +(1597, 7058.78, 1784.73, 527.87, 3.85076, 571, 'Ymirheim'), +(1596, 6514, 2563.77, 651.57, 0.752369, 571, 'CorpretharTheHorrorGate'), +(1595, 6635.72, 3210.13, 668.535, 4.1767, 571, 'SanctumOfReanimation'), +(1594, 6490.04, 3454.59, 595.554, 5.3862, 571, 'TheFleshwerks'), +(1593, 6955.48, 4514.21, 601.093, 4.98564, 571, 'Jotunheim'), +(1592, 7057.58, 4254.91, 676.829, 1.32961, 571, 'BalargardeFortress'), +(1591, 6869.59, 3878.78, 628.466, 4.16098, 571, 'KulgalarKeep'), +(1590, 7799.59, 3711.14, 653.015, 4.38089, 571, 'NjorndarVillage'), +(1589, 8428.12, 2894.52, 606.259, 1.60058, 571, 'UfrangsHall'), +(1588, 8454.85, 3137.16, 588.142, 3.88217, 571, 'SavageLedge'), +(1587, 7946.45, 3254.79, 676.137, 0.795563, 571, 'TheUnderhalls'), +(1586, 7865.1, 3350.07, 652.318, 2.33494, 571, 'TheCircleOfSuffering'), +(1585, 7994.08, 3303.67, 632.396, 0.815185, 571, 'HallOfHorrors'), +(1584, 8125.72, 3438.16, 672.373, 0.771992, 571, 'Valhalas'), +(1583, 7185.49, 3909.44, 591.7, 5.68466, 571, 'HallsOfTheAncestors'), +(1582, 7787.65, 5012.76, 4.37668, 3.1321, 571, 'OnslaughtHarbor'), +(1581, 7547.36, 4848.95, 52.4912, 3.15958, 571, 'TheCrimsonCathedral'), +-- Sholazar Basin +(1580, 6352, 5812.13, 56.8665, 3.32617, 571, 'TheStormwrightsShelf'), +(1579, 6200.55, 4732.6, 224.713, 1.43729, 571, 'TheGlimmeringPillar'), +(1578, 6077.61, 4509.06, -80.9205, 0.32209, 571, 'DeathsHandEncampment'), +(1577, 6514.13, 4434.68, -49.7989, 3.6993, 571, 'TheBonefields'), +(1576, 6587.91, 4882.84, -42.9031, 3.11024, 571, 'TheSavageThicket'), +(1575, 6622.02, 5177.81, -41.6024, 4.14697, 571, 'SpearbornEncampment'), +(1574, 5196.96, 5504.35, -86.8983, 5.1601, 571, 'SparktouchedHaven'), +(1573, 5108.43, 5365.51, 224.995, 4.48466, 571, 'TheMosslightPillar'), +(1572, 4928.71, 5192.91, -92.8246, 3.52253, 571, 'Waygate'), +(1571, 4991.56, 4569.96, 148.897, 1.9753, 571, 'TheSkyreachPillar'), +(1570, 4997.3, 4324.79, -84.737, 1.97922, 571, 'SapphireHive'), +(1569, 5272.1, 4524.57, -83.0975, 3.81705, 571, 'FrenzyheartHill'), +(1568, 5540.35, 4104.43, 43.2335, 4.64957, 571, 'TheLifebloodPillar'), +(1567, 5588.53, 3860.26, -97.1207, 4.22938, 571, 'TheSunderedShard'), +(1566, 5702.6, 3456.26, 300.842, 4.83806, 571, 'MakersOverlook'), +(1565, 5800.24, 3556, -7.71123, 2.30908, 571, 'MosswalkerVillage'), +(1564, 5819.48, 3900.97, -57.8919, 2.6036, 571, 'TheLostLands'), +(1563, 6200.41, 3754.96, 167.473, 2.58396, 571, 'TheAvalanche'), +(1562, 5732.95, 4385.3, -136.637, 2.47012, 571, 'RainspeakerRapids'), +(1561, 5438.16, 4621.39, -142.395, 5.72167, 571, 'FrenzyheartRiver'), +(1560, 5653.33, 4565.95, -134.441, 1.00929, 571, 'RainspeakerCanopy'), +(1559, 5368.05, 4843.58, -197.195, 5.93375, 571, 'RiversHeart'), +(1558, 5501.47, 4733, -194.376, 2.29344, 571, 'LakesideLanding'), +(1557, 5660.99, 5098.01, -133.723, 5.82774, 571, 'WildgrowthMangal'), +(1556, 5794.79, 5479.6, 203.391, 3.75822, 571, 'TheSuntouchedPillar'), +(1555, 5923.1, 5326, -95.5351, 2.48981, 571, 'SwindlegrinsDig'), +(1554, 6092.06, 5317.29, -95.0416, 5.62353, 571, 'BittertideLake'), +(1553, 6118.86, 5662.16, 5.1509, 0.730512, 571, 'TheMakersPerch'), +(1552, 5561.69, 5748.65, -76.2847, 1.51591, 571, 'NesingwaryBaseCamp'), +(1551, 5505.3, 5990.77, -40.6402, 0.435986, 571, 'TheSeabreachFlow'), +(1550, 4874.82, 5901.06, -40.5268, 1.68084, 571, 'KartaksHold'), +-- Borean Tundra +(1549, 4155.55, 6962.69, 164.671, 3.40091, 571, 'Coldarra'), +(1548, 3954.58, 6045.14, 23.8309, 3.93498, 571, 'TheWestrift'), +(1547, 3580.99, 6654.6, 195.569, 6.0948, 571, 'TransitusShield'), +(1546, 4130.43, 6262.65, 28.9689, 2.5307, 571, 'WinterfinCaverns'), +(1545, 4202.91, 6294, 11.929, 5.96681, 571, 'WinterfinVillage'), +(1544, 4497.91, 6358.62, 24.8969, 3.65774, 571, 'GlimmerBay'), +(1543, 4730.28, 5581.22, 6.86127, 4.8162, 571, 'TheLostPassage'), +(1542, 2803.56, 4696.17, 1.8599, 3.375, 571, 'NjordsBreathBay'), +(1541, 3998.88, 4818.12, 25.1371, 1.42266, 571, 'FizzcrankPumpingStation'), +(1540, 4018.28, 4921.16, -12.9943, 5.08653, 571, 'MidPointStation'), +(1539, 4210.47, 4797.77, -12.9951, 0.994613, 571, 'NorthPointStation'), +(1538, 4127.8, 5085.07, -0.181869, 2.57327, 571, 'WestPointStation'), +(1537, 3793.5, 4818.49, -12.9668, 0.282474, 571, 'SouthPointStation'), +(1536, 3814.71, 4668.49, -8.99847, 1.02861, 571, 'TheGeyserFields'), +(1535, 3577.14, 4821.72, 0.984557, 5.45434, 571, 'ScaldingPools'), +(1534, 3704.34, 4336.71, 13.5571, 1.77082, 571, 'SteamSprings'), +(1533, 3335.1, 3689.79, 32.4327, 3.15905, 571, 'TheWailingZiggurat'), +(1532, 3180.09, 3923.03, 31.1576, 0.897093, 571, 'FrozenReach'), +(1531, 3107.09, 3843.45, 22.3012, 4.7691, 571, 'DeathsStand'), +(1529, 3567.48, 3470.22, 50.2653, 2.13238, 571, 'Transborea'), +(1528, 4057.56, 3713.47, 92.6897, 0.400578, 571, 'SpireOfDecay'), +(1527, 3810.97, 3465.01, 82.904, 4.27652, 571, 'SpireOfPain'), +(1526, 4053.27, 3517.44, 115.678, 5.76875, 571, 'SpireOfBlood'), +(1525, 3694.55, 3724.94, 47.8466, 5.80018, 571, 'TempleCityofEnkilah'), +(1524, 4199.34, 4196.99, 88.6181, 5.40748, 571, 'DensOfDying'), +(1523, 4314.41, 4609.35, 26.678, 5.6235, 571, 'Talramas'), +(1522, 4357.79, 5470.73, 48.1204, 5.66279, 571, 'Magmoth'), +(1520, 4548.21, 6004.51, 74.8061, 1.57091, 571, 'RuinsOfEldranath'), +(1519, 4392.41, 6129.05, 0.116559, 2.6626, 571, 'WinterfinRetreat'), +(1518, 4323.22, 5859.49, 57.4084, 0.561667, 571, 'BlisteringPool'), +(1517, 3942.05, 5703.13, 63.3935, 5.57644, 571, 'SteeljawsCaravan'), +(1516, 3639.94, 5592.77, 32.8598, 5.58588, 571, 'ColdrockQuarry'), +(1515, 2913.33, 6502.97, 79.3253, 4.12898, 571, 'TorpsFarm'), +(1514, 2788.62, 6559.41, 49.4538, 3.34358, 571, 'WarsongGranary'), +(1513, 2647.44, 6674.29, 24.8536, 2.68779, 571, 'CoastOfEchoes'), +(1512, 2481.1, 6542.99, 41.0985, 4.26645, 571, 'PlainsOfNasam'), +(1511, 2797.04, 6997.76, 26.7684, 4.48636, 571, 'WarsongJetty'), +(1510, 2425.16, 6822.39, 4.41998, 5.57807, 571, 'Palea'), +(1509, 2987.91, 6817.53, 4.5871, 3.59886, 571, 'GarroshsLanding'), +(1508, 3101.81, 6326.78, 91.8155, 2.6446, 571, 'WarsongSlaughterhouse'), +(1507, 3458.82, 6218.68, 73.441, 3.67738, 571, 'BerylPoint'), +(1506, 3601.73, 5941.81, 136.218, 1.37617, 571, 'AmberLedge'), +(1505, 3179.06, 5735.6, 49.8884, 5.0911, 571, 'LakeKumuya'), +(1504, 2865.25, 5576.93, 56.1496, 1.14841, 571, 'BloodsporePlains'), +(1503, 3226.48, 5273.91, 47.0191, 2.8645, 571, 'DEHTAEncampment'), +(1502, 2953.95, 5029.19, 32.5341, 1.29836, 571, 'TheFloodPlains'), +(1501, 2562.73, 5082.13, 8.78205, 0.697533, 571, 'TheAbandonedReach'), +(1500, 2452.49, 5149.73, 30.2057, 0.575801, 571, 'FarshireLighthouse'), +(1499, 2709.2, 5295.72, 31.4857, 5.84583, 571, 'FarshireMine'), +(1498, 2601.02, 5276.52, 36.8806, 2.46075, 571, 'Farshire'), +(1497, 2104.41, 5514.25, 0.336683, 5.60234, 571, 'SandsOfNasam'), +(1496, 1471.34, 5802.38, 3.89735, 4.01848, 571, 'RiplashRuins'), +(1495, 1818.7, 5813.67, 0.434314, 6.06444, 571, 'RiplashStrand'), +(1494, 2535.97, 6126.06, 77.0848, 6.23719, 571, 'MightstoneQuarry'), +-- Dun Morogh +(1493, -6165.16, 383.46, 399.154, 6.27642, 0, 'Anvilmar'), +(1492, -6022.06, 60.0566, 406.509, 5.72273, 0, 'ColdridgePass'); From 54e2e2b60392a1cb303e55df898e88e4f06d6e65 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 13 Nov 2024 14:44:57 +0000 Subject: [PATCH 059/105] chore(DB): import pending files Referenced commit(s): d52cff5f8dace9d2f5cdacec4ea1ab45e91b15a2 --- .../rev_1729603880657213700.sql => db_world/2024_11_13_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1729603880657213700.sql => db_world/2024_11_13_00.sql} (99%) diff --git a/data/sql/updates/pending_db_world/rev_1729603880657213700.sql b/data/sql/updates/db_world/2024_11_13_00.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1729603880657213700.sql rename to data/sql/updates/db_world/2024_11_13_00.sql index caee235535ca39..42535b1938bf87 100644 --- a/data/sql/updates/pending_db_world/rev_1729603880657213700.sql +++ b/data/sql/updates/db_world/2024_11_13_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_12_02 -> 2024_11_13_00 -- Update Existing Teles -- Standardisation and String Corrections UPDATE `game_tele` SET `name` = 'Onyxia' WHERE `id` = 699 AND `name` = 'onyxia'; From d78350ba3674750ec5f4d21877f4d1374ef074ae Mon Sep 17 00:00:00 2001 From: FlyingArowana Date: Wed, 13 Nov 2024 18:59:42 +0000 Subject: [PATCH 060/105] fix(DB/gameobject): Wrong faction banners while event 20 running. (#20539) * Created SQL * Banners corrected * Updated to match Bench's suggestion Co-authored-by: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> --------- Co-authored-by: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> --- .../sql/updates/pending_db_world/rev_1731438952898922800.sql | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731438952898922800.sql diff --git a/data/sql/updates/pending_db_world/rev_1731438952898922800.sql b/data/sql/updates/pending_db_world/rev_1731438952898922800.sql new file mode 100644 index 00000000000000..f61b55b93cc089 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731438952898922800.sql @@ -0,0 +1,5 @@ +-- +UPDATE `gameobject` SET `id` = 180396 WHERE `guid` IN (151423, 151424, 151425, 151426, 151427, 151428, 151429, 151430, 151431, 151432, 151433) AND `id` = 180398; + +UPDATE `gameobject` SET `id` = 180398 WHERE `guid` IN (151434, 151435, 151436, 151437, 151438, 151439, 151440, 151441, 151442, 151443, 151444, 151445) AND `id` = 180396; + From 32f15256c764c5e0e63badb9d32a37e658d03816 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 13 Nov 2024 19:00:35 +0000 Subject: [PATCH 061/105] chore(DB): import pending files Referenced commit(s): d78350ba3674750ec5f4d21877f4d1374ef074ae --- .../rev_1731438952898922800.sql => db_world/2024_11_13_01.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731438952898922800.sql => db_world/2024_11_13_01.sql} (88%) diff --git a/data/sql/updates/pending_db_world/rev_1731438952898922800.sql b/data/sql/updates/db_world/2024_11_13_01.sql similarity index 88% rename from data/sql/updates/pending_db_world/rev_1731438952898922800.sql rename to data/sql/updates/db_world/2024_11_13_01.sql index f61b55b93cc089..d59b1610296bd2 100644 --- a/data/sql/updates/pending_db_world/rev_1731438952898922800.sql +++ b/data/sql/updates/db_world/2024_11_13_01.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_13_00 -> 2024_11_13_01 -- UPDATE `gameobject` SET `id` = 180396 WHERE `guid` IN (151423, 151424, 151425, 151426, 151427, 151428, 151429, 151430, 151431, 151432, 151433) AND `id` = 180398; From d6b25295570e4748417bfc0827166561bf2a193c Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Wed, 13 Nov 2024 16:02:01 -0300 Subject: [PATCH 062/105] refactor(Scripts/SunwellPlateau): Update Brutallus script (#20548) --- .../SunwellPlateau/boss_brutallus.cpp | 109 ++++++------------ 1 file changed, 35 insertions(+), 74 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp index 86f63127411410..74d7ff147c90b7 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp @@ -70,17 +70,8 @@ struct boss_brutallus : public BossAI void Reset() override { BossAI::Reset(); - me->CastSpell(me, SPELL_DUAL_WIELD, true); - } - - void DamageTaken(Unit* who, uint32& damage, DamageEffectType, SpellSchoolMask) override - { - if (me->GetReactState() == REACT_PASSIVE && (!who || who->GetEntry() != NPC_MADRIGOSA)) - { - if (who) - Unit::Kill(me, who); - damage = 0; - } + DoCastSelf(SPELL_DUAL_WIELD, true); + me->m_Events.KillAllEvents(false); } void JustEngagedWith(Unit* who) override @@ -91,10 +82,24 @@ struct boss_brutallus : public BossAI Talk(YELL_AGGRO); BossAI::JustEngagedWith(who); - events.ScheduleEvent(EVENT_SPELL_SLASH, 11000); - events.ScheduleEvent(EVENT_SPELL_STOMP, 30000); - events.ScheduleEvent(EVENT_SPELL_BURN, 45000); - events.ScheduleEvent(EVENT_SPELL_BERSERK, 360000); + ScheduleTimedEvent(11s, [&] { + DoCastVictim(SPELL_METEOR_SLASH); + }, 10s); + + ScheduleTimedEvent(30s, [&] { + DoCastVictim(SPELL_STOMP); + Talk(YELL_LOVE); + }, 30s); + + ScheduleTimedEvent(45s, [&] { + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 100.0f, true, true, -SPELL_BURN_DAMAGE)) + DoCast(target, SPELL_BURN); + }, 1min); + + me->m_Events.AddEventAtOffset([&] { + DoCastSelf(SPELL_BERSERK, true); + Talk(YELL_BERSERK); + }, 6min); } void KilledUnit(Unit* victim) override @@ -108,7 +113,7 @@ struct boss_brutallus : public BossAI BossAI::JustDied(killer); Talk(YELL_DEATH); - me->CastSpell(me, SPELL_SUMMON_BRUTALLUS_DEATH_CLOUD, true); + DoCastAOE(SPELL_SUMMON_BRUTALLUS_DEATH_CLOUD, true); if (Creature* madrigosa = instance->GetCreature(DATA_MADRIGOSA)) madrigosa->AI()->DoAction(ACTION_SPAWN_FELMYST); } @@ -119,40 +124,6 @@ struct boss_brutallus : public BossAI return; BossAI::AttackStart(who); } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_SLASH: - me->CastSpell(me->GetVictim(), SPELL_METEOR_SLASH, false); - events.ScheduleEvent(EVENT_SPELL_SLASH, 10000); - break; - case EVENT_SPELL_STOMP: - me->CastSpell(me->GetVictim(), SPELL_STOMP, false); - Talk(YELL_LOVE); - events.ScheduleEvent(EVENT_SPELL_STOMP, 30000); - break; - case EVENT_SPELL_BURN: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 100.0f, true, true, -SPELL_BURN_DAMAGE)) - me->CastSpell(target, SPELL_BURN, false); - events.ScheduleEvent(EVENT_SPELL_BURN, 60000); - break; - case EVENT_SPELL_BERSERK: - me->CastSpell(me, SPELL_BERSERK, true); - Talk(YELL_BERSERK); - break; - } - - DoMeleeAttackIfReady(); - } }; enum eMadrigosa @@ -400,18 +371,13 @@ class spell_madrigosa_activate_barrier : public SpellScript { go->SetGoState(GO_STATE_READY); if (Map* map = go->GetMap()) - { - Map::PlayerList const& PlayerList = map->GetPlayers(); - for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) - if (i->GetSource()) - { - UpdateData data; - WorldPacket pkt; - go->BuildValuesUpdateBlockForPlayer(&data, i->GetSource()); - data.BuildPacket(pkt); - i->GetSource()->GetSession()->SendPacket(&pkt); - } - } + map->DoForAllPlayers([&](Player* player) { + UpdateData data; + WorldPacket pkt; + go->BuildValuesUpdateBlockForPlayer(&data, player); + data.BuildPacket(pkt); + player->GetSession()->SendPacket(&pkt); + }); } } @@ -432,18 +398,13 @@ class spell_madrigosa_deactivate_barrier : public SpellScript { go->SetGoState(GO_STATE_ACTIVE); if (Map* map = go->GetMap()) - { - Map::PlayerList const& PlayerList = map->GetPlayers(); - for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) - if (i->GetSource()) - { - UpdateData data; - WorldPacket pkt; - go->BuildValuesUpdateBlockForPlayer(&data, i->GetSource()); - data.BuildPacket(pkt); - i->GetSource()->GetSession()->SendPacket(&pkt); - } - } + map->DoForAllPlayers([&](Player* player) { + UpdateData data; + WorldPacket pkt; + go->BuildValuesUpdateBlockForPlayer(&data, player); + data.BuildPacket(pkt); + player->GetSession()->SendPacket(&pkt); + }); } } From f011a849dc7c7e26f6e972b570cd544625b610ee Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Wed, 13 Nov 2024 20:10:36 +0100 Subject: [PATCH 063/105] fix(Scripts/ZulAman): speed up gong event (#20547) --- .../rev_1731513769607437914.sql | 3 ++ .../ZulAman/instance_zulaman.cpp | 5 +-- .../EasternKingdoms/ZulAman/zulaman.cpp | 35 +++++++++++++++++-- .../scripts/EasternKingdoms/ZulAman/zulaman.h | 3 +- 4 files changed, 41 insertions(+), 5 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731513769607437914.sql diff --git a/data/sql/updates/pending_db_world/rev_1731513769607437914.sql b/data/sql/updates/pending_db_world/rev_1731513769607437914.sql new file mode 100644 index 00000000000000..af98360eedba03 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731513769607437914.sql @@ -0,0 +1,3 @@ +-- +DELETE FROM `spell_script_names` WHERE `spell_id` = 45217 AND `ScriptName` = 'spell_ritual_of_power'; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES (45217, 'spell_ritual_of_power'); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp index 3ed70672089b82..bc2bbbde75640d 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp @@ -58,8 +58,9 @@ DoorData const doorData[] = ObjectData const creatureData[] = { - { NPC_SPIRIT_LYNX, DATA_SPIRIT_LYNX }, - { 0, 0 } + { NPC_SPIRIT_LYNX, DATA_SPIRIT_LYNX }, + { NPC_HARRISON_JONES, DATA_HARRISON_JONES }, + { 0, 0 } }; ObjectData const gameObjectData[] = diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp index 8896931d22d106..83a04cbf65b036 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp @@ -33,6 +33,7 @@ EndContentData */ #include "ScriptedGossip.h" #include "SpellInfo.h" #include "SpellScript.h" +#include "SpellScriptLoader.h" /*###### ## npc_forest_frog @@ -348,6 +349,11 @@ enum Events GONG_EVENT_11 = 11 }; +enum Actions +{ + ACTION_COMPLETE_EVENT_3 = 0, +}; + enum Waypoints { HARRISON_MOVE_1 = 860440, @@ -419,6 +425,15 @@ struct npc_harrison_jones : public ScriptedAI } } + void DoAction(int32 action) override + { + if (action == ACTION_COMPLETE_EVENT_3) + { + _gongEvent = GONG_EVENT_4; + _gongTimer = 0; + } + } + void UpdateAI(uint32 diff) override { if (_gongEvent) @@ -444,8 +459,6 @@ struct npc_harrison_jones : public ScriptedAI case GONG_EVENT_3: if (GameObject* gong = _instance->GetGameObject(DATA_STRANGE_GONG)) gong->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE); - _gongEvent = GONG_EVENT_4; - _gongTimer = 105000; break; case GONG_EVENT_4: me->RemoveAura(SPELL_BANGING_THE_GONG); @@ -538,9 +551,27 @@ struct npc_harrison_jones : public ScriptedAI ObjectGuid uiTargetGUID; }; +class spell_ritual_of_power : public SpellScript +{ + PrepareSpellScript(spell_ritual_of_power); + + void OnEffect(SpellEffIndex /*effIndex*/) + { + if (InstanceScript* instance = GetCaster()->GetInstanceScript()) + if (Creature* creature = instance->GetCreature(DATA_HARRISON_JONES)) + creature->AI()->DoAction(ACTION_COMPLETE_EVENT_3); + } + + void Register() override + { + OnEffectLaunch += SpellEffectFn(spell_ritual_of_power::OnEffect, EFFECT_0, SPELL_EFFECT_SEND_EVENT); + } +}; + void AddSC_zulaman() { RegisterZulAmanCreatureAI(npc_forest_frog); new npc_zulaman_hostage(); RegisterZulAmanCreatureAI(npc_harrison_jones); + RegisterSpellScript(spell_ritual_of_power); } diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h index 86092f9186ee7d..4da0ed8cd42232 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h @@ -37,7 +37,8 @@ enum DataTypes TYPE_RAND_VENDOR_2 = 9, DATA_STRANGE_GONG = 10, DATA_MASSIVE_GATE = 11, - DATA_HEXLORD_GATE = 12 + DATA_HEXLORD_GATE = 12, + DATA_HARRISON_JONES = 13 }; enum CreatureIds From 288e97d4a2aadcb77decd17a91d9f4133383f59c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 13 Nov 2024 19:11:43 +0000 Subject: [PATCH 064/105] chore(DB): import pending files Referenced commit(s): f011a849dc7c7e26f6e972b570cd544625b610ee --- .../rev_1731513769607437914.sql => db_world/2024_11_13_02.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731513769607437914.sql => db_world/2024_11_13_02.sql} (82%) diff --git a/data/sql/updates/pending_db_world/rev_1731513769607437914.sql b/data/sql/updates/db_world/2024_11_13_02.sql similarity index 82% rename from data/sql/updates/pending_db_world/rev_1731513769607437914.sql rename to data/sql/updates/db_world/2024_11_13_02.sql index af98360eedba03..b2a15d7bed6c76 100644 --- a/data/sql/updates/pending_db_world/rev_1731513769607437914.sql +++ b/data/sql/updates/db_world/2024_11_13_02.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_13_01 -> 2024_11_13_02 -- DELETE FROM `spell_script_names` WHERE `spell_id` = 45217 AND `ScriptName` = 'spell_ritual_of_power'; INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES (45217, 'spell_ritual_of_power'); From 21c5575d1ab5ccf881881d3281cca57086354b08 Mon Sep 17 00:00:00 2001 From: manstfu <33990720+manstfu@users.noreply.github.com> Date: Wed, 13 Nov 2024 21:53:03 +0100 Subject: [PATCH 065/105] fix(Core/Player): Nerfing Heirloom Weapons Damage (#20357) Fixing heirloom damage Co-authored-by: ariel- --- src/server/game/Entities/Player/Player.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index d757f1a1346286..eca6924736a155 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -6921,7 +6921,7 @@ void Player::_ApplyWeaponDamage(uint8 slot, ItemTemplate const* proto, ScalingSt float maxDamage = proto->Damage[i].DamageMax; // If set dpsMod in ScalingStatValue use it for min (70% from average), max (130% from average) damage - if (ssv) + if (ssv && i == 0) // scaling stats only for first damage { int32 extraDPS = ssv->getDPSMod(ScalingStatValue); if (extraDPS) From 4871e1821ff5b77eebf78bc519d7497d57939cb6 Mon Sep 17 00:00:00 2001 From: IntelligentQuantum Date: Thu, 14 Nov 2024 00:39:09 +0330 Subject: [PATCH 066/105] Fix(Sql/Creature): Correct felguard annihilator ids (#20435) * Fix(Sql/Creature): Correct felguard annihilator ids * Update rev_1730699152248147966.sql * fix fel power * Update rev_1730699152248147966.sql --- .../updates/pending_db_world/rev_1730699152248147966.sql | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1730699152248147966.sql diff --git a/data/sql/updates/pending_db_world/rev_1730699152248147966.sql b/data/sql/updates/pending_db_world/rev_1730699152248147966.sql new file mode 100644 index 00000000000000..1156ca40f58292 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730699152248147966.sql @@ -0,0 +1,7 @@ +UPDATE `creature` SET `id1` = 17400 WHERE `guid` IN (138247, 138248, 138249, 138250, 138252, 138253); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 22 AND `SourceGroup` = 6 AND `SourceEntry` = 17371 AND `ConditionValue1` = 17400; +INSERT INTO `conditions` +(`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) +VALUES +(22, 6, 17371, 0, 1, 29, 1, 17400, 10, 0, 0, 0, 0, '', 'Only cast Fel Power (33111) if a Felguard Annihilator (17400) is nearby'); From bc70272a34e6a376c778ade0d5864a08f87f9a68 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 13 Nov 2024 21:10:09 +0000 Subject: [PATCH 067/105] chore(DB): import pending files Referenced commit(s): 4871e1821ff5b77eebf78bc519d7497d57939cb6 --- .../rev_1730699152248147966.sql => db_world/2024_11_13_03.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1730699152248147966.sql => db_world/2024_11_13_03.sql} (93%) diff --git a/data/sql/updates/pending_db_world/rev_1730699152248147966.sql b/data/sql/updates/db_world/2024_11_13_03.sql similarity index 93% rename from data/sql/updates/pending_db_world/rev_1730699152248147966.sql rename to data/sql/updates/db_world/2024_11_13_03.sql index 1156ca40f58292..852134ebaf4957 100644 --- a/data/sql/updates/pending_db_world/rev_1730699152248147966.sql +++ b/data/sql/updates/db_world/2024_11_13_03.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_13_02 -> 2024_11_13_03 UPDATE `creature` SET `id1` = 17400 WHERE `guid` IN (138247, 138248, 138249, 138250, 138252, 138253); DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 22 AND `SourceGroup` = 6 AND `SourceEntry` = 17371 AND `ConditionValue1` = 17400; From 54c83433c614333b24e94936ab10ca020763314a Mon Sep 17 00:00:00 2001 From: daobashun <49193927+fangshun2004@users.noreply.github.com> Date: Thu, 14 Nov 2024 05:23:58 +0800 Subject: [PATCH 068/105] Fix(DB/SAI) Added dialogue and emotes for Creature (19316). (#20348) --- .../pending_db_world/rev_1730205089330945800.sql | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1730205089330945800.sql diff --git a/data/sql/updates/pending_db_world/rev_1730205089330945800.sql b/data/sql/updates/pending_db_world/rev_1730205089330945800.sql new file mode 100644 index 00000000000000..4fde2f9241fc62 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730205089330945800.sql @@ -0,0 +1,15 @@ +-- Field Marshal Rohamus smart ai +SET @ENTRY := 19316; +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = @ENTRY; +DELETE FROM `smart_scripts` WHERE `source_type` = 0 AND `entryOrGuid` = @ENTRY; +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`, `event_param5`, `event_param6`, `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, 1, 0, 100, 0, 0, 0, 81000, 85000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Field Marshal Rohamus - Out of Combat - Say Line 0'), +(@ENTRY, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 67, 1, 3000, 3000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Field Marshal Rohamus - Out of Combat - Create Timed Event'), +(@ENTRY, 0, 2, 0, 59, 0, 100, 0, 1, 0, 0, 0, 0, 0, 5, 275, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Field Marshal Rohamus - On Timed Event 1 Triggered - Play Emote ONESHOT_TRAIN(DNR) (275)'); + +DELETE FROM `creature_text` WHERE `CreatureID` = 19316; +INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(19316, 0, 0, 'Tear it down, soldiers! We\'re shippin\' this thing back to Stormwind!', 12, 7, 100, 22, 0, 0, 16576, 0, 'Field Marshal Rohamus'), +(19316, 0, 1, 'We\'re gonna melt this hunk of junk down and make weapons with the ingots! Let\'s see how the Legion likes a taste of fel reaver served up Alliance style!', 12, 7, 100, 22, 0, 0, 16577, 0, 'Field Marshal Rohamus'), +(19316, 0, 2, 'Well done, soldiers! We weren\'t about to let the filthy animals of the Horde show us up!', 12, 7, 100, 22, 0, 0, 16578, 0, 'Field Marshal Rohamus'), +(19316, 0, 3, 'Let them throw another one of these overgrown tin cans at us! We\'ll show them what the Alliance is made of!', 12, 7, 100, 22, 0, 0, 16579, 0, 'Field Marshal Rohamus'); From 35ebe2f9c6b932ede4f7a8b10c7837430b603ed4 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 13 Nov 2024 21:24:51 +0000 Subject: [PATCH 069/105] chore(DB): import pending files Referenced commit(s): 54c83433c614333b24e94936ab10ca020763314a --- .../rev_1730205089330945800.sql => db_world/2024_11_13_04.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1730205089330945800.sql => db_world/2024_11_13_04.sql} (98%) diff --git a/data/sql/updates/pending_db_world/rev_1730205089330945800.sql b/data/sql/updates/db_world/2024_11_13_04.sql similarity index 98% rename from data/sql/updates/pending_db_world/rev_1730205089330945800.sql rename to data/sql/updates/db_world/2024_11_13_04.sql index 4fde2f9241fc62..f163f2a9981756 100644 --- a/data/sql/updates/pending_db_world/rev_1730205089330945800.sql +++ b/data/sql/updates/db_world/2024_11_13_04.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_13_03 -> 2024_11_13_04 -- Field Marshal Rohamus smart ai SET @ENTRY := 19316; UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = @ENTRY; From bdb6ef8937725f0522aeb9d703d92651f20b6f0f Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Wed, 13 Nov 2024 19:46:06 -0300 Subject: [PATCH 070/105] fix(Scripts/TheEye): Fix Wrath of the Astromancer's original caster (#20549) --- src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp index 309fd555fa74d1..4378d6a2461550 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp @@ -256,7 +256,7 @@ class spell_astromancer_wrath_of_the_astromancer : public AuraScript return; Unit* target = GetUnitOwner(); - target->CastSpell(target, GetSpellInfo()->Effects[EFFECT_1].CalcValue(), false); + target->CastSpell(target, GetSpellInfo()->Effects[EFFECT_1].CalcValue(), false, nullptr, nullptr, GetCaster () ? GetCaster()->GetGUID() : ObjectGuid::Empty); } void Register() override From 1bea402e5ccb85403fc2664c96f3e31e291f980f Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Wed, 13 Nov 2024 22:58:33 -0300 Subject: [PATCH 071/105] fix(Scripts/ZulAman): Remove Eletrical Storm hacks (#20553) * fix(Scripts/ZulAman): Remove Eletrical Storm hacks * Update boss_akilzon.cpp * Create rev_1731545993422354000.sql --- .../rev_1731545993422354000.sql | 4 + .../EasternKingdoms/ZulAman/boss_akilzon.cpp | 266 ++++++++---------- 2 files changed, 124 insertions(+), 146 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731545993422354000.sql diff --git a/data/sql/updates/pending_db_world/rev_1731545993422354000.sql b/data/sql/updates/pending_db_world/rev_1731545993422354000.sql new file mode 100644 index 00000000000000..a9555d49bb5d20 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731545993422354000.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_electrial_storm' AND `spell_id` = 43648; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(43648, 'spell_electrial_storm'); diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp index 75d7722d20a00b..5972ea2ea8d5c9 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp @@ -15,20 +15,13 @@ * with this program. If not, see . */ -/* ScriptData -SDName: boss_Akilzon -SD%Complete: 75% -SDComment: Missing timer for Call Lightning and Sound ID's -SQLUpdate: -#Temporary fix for Soaring Eagles - -EndScriptData */ - #include "Cell.h" #include "CreatureScript.h" #include "GridNotifiers.h" #include "GridNotifiersImpl.h" #include "ScriptedCreature.h" +#include "SpellScript.h" +#include "SpellScriptLoader.h" #include "Weather.h" #include "zulaman.h" @@ -39,6 +32,7 @@ enum Spells SPELL_CALL_LIGHTNING = 43661, // Missing timer SPELL_GUST_OF_WIND = 43621, SPELL_ELECTRICAL_STORM = 43648, + SPELL_ELECTRICAL_STORM_AREA = 44007, // Safe within the eye of the storm SPELL_BERSERK = 45078, SPELL_ELECTRICAL_OVERLOAD = 43658, SPELL_EAGLE_SWOOP = 44732, @@ -56,6 +50,11 @@ enum Says SAY_DEATH = 5 }; +enum Misc +{ + ACTION_INCREASE_STORM_COUNT = 1 +}; + constexpr auto NPC_SOARING_EAGLE = 24858; class boss_akilzon : public CreatureScript @@ -71,12 +70,12 @@ class boss_akilzon : public CreatureScript { _Reset(); - TargetGUID.Clear(); - CloudGUID.Clear(); - CycloneGUID.Clear(); + _targetGUID.Clear(); + _cloudGUID.Clear(); + _cycloneGUID.Clear(); - StormCount = 0; - isRaining = false; + _stormCount = 0; + _isRaining = false; SetWeather(WEATHER_STATE_FINE, 0.0f); @@ -93,7 +92,7 @@ class boss_akilzon : public CreatureScript target = me->GetVictim(); if (target) { - TargetGUID = target->GetGUID(); + _targetGUID = target->GetGUID(); DoCast(target, SPELL_STATIC_DISRUPTION, false); me->SetInFront(me->GetVictim()); } @@ -118,8 +117,8 @@ class boss_akilzon : public CreatureScript EnterEvadeMode(); return; } - target->CastSpell(target, 44007, true); // cloud visual - DoCast(target, SPELL_ELECTRICAL_STORM, false); // storm cyclon + visual + target->CastSpell(target, SPELL_ELECTRICAL_STORM_AREA, true); // cloud visual + DoCast(target, SPELL_ELECTRICAL_STORM); // storm cyclon + visual float x, y, z; target->GetPosition(x, y, z); @@ -128,7 +127,7 @@ class boss_akilzon : public CreatureScript { target->GetMotionMaster()->MoveJump(Cloud->GetPosition(), 1.0f, 1.0f); - CloudGUID = Cloud->GetGUID(); + _cloudGUID = Cloud->GetGUID(); Cloud->SetDisableGravity(true); Cloud->StopMoving(); Cloud->SetObjectScale(1.0f); @@ -137,27 +136,27 @@ class boss_akilzon : public CreatureScript Cloud->SetHealth(9999999); Cloud->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - me->m_Events.AddEventAtOffset([&, Cloud] { - HandleStormSequence(Cloud); + me->m_Events.AddEventAtOffset([&] { + HandleStormSequence(); }, 3s); } - StormCount = 1; + _stormCount = 1; me->m_Events.AddEventAtOffset([&] { - if (!isRaining) + if (!_isRaining) { SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); - isRaining = true; + _isRaining = true; } }, Seconds(urand(47, 52))); }, 1min); ScheduleTimedEvent(47s, 52s, [&] { - if (!isRaining) + if (!_isRaining) { SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); - isRaining = true; + _isRaining = true; } }, 47s, 52s); @@ -187,81 +186,44 @@ class boss_akilzon : public CreatureScript me->GetMap()->SetZoneWeather(me->GetZoneId(), WeatherState(weather), grade); } - void HandleStormSequence(Unit* Cloud) // 1: begin, 2-9: tick, 10: end + void HandleStormSequence() // 1: begin, 2-9: tick, 10: end { + Creature* Cloud = ObjectAccessor::GetCreature(*me, _cloudGUID); if (!Cloud) return; - if (StormCount < 10 && StormCount > 1) + if (_stormCount > 10) { - // deal damage - int32 bp0 = 800; - for (uint8 i = 2; i < StormCount; ++i) - bp0 *= 2; - - std::list tempUnitMap; - - Acore::AnyAoETargetUnitInObjectRangeCheck u_check(me, me, SIZE_OF_GRIDS); - Acore::UnitListSearcher searcher(me, tempUnitMap, u_check); - Cell::VisitAllObjects(me, searcher, SIZE_OF_GRIDS); - - // deal damage - for (auto const& target : tempUnitMap) - { - if (target) - { - if (Cloud && !Cloud->IsWithinDist(target, 6, false)) - Cloud->CastCustomSpell(target, SPELL_ZAP, &bp0, nullptr, nullptr, true, 0, 0, me->GetGUID()); - } - } - - // visual - float x, y, z; - z = me->GetPositionZ(); - for (uint8 i = 0; i < 5 + rand() % 5; ++i) - { - x = 343.0f + rand() % 60; - y = 1380.0f + rand() % 60; - if (Unit* trigger = me->SummonTrigger(x, y, z, 0, 2000)) - { - trigger->SetFaction(FACTION_FRIENDLY); - trigger->SetMaxHealth(100000); - trigger->SetHealth(100000); - trigger->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - if (Cloud) - Cloud->CastCustomSpell(trigger, /*43661*/SPELL_ZAP, &bp0, nullptr, nullptr, true, 0, 0, Cloud->GetGUID()); - } - } - } - - ++StormCount; - - if (StormCount > 10) - { - StormCount = 0; // finish + _stormCount = 0; // finish me->m_Events.AddEventAtOffset([&] { SummonEagles(); }, 5s); me->InterruptNonMeleeSpells(false); - CloudGUID.Clear(); + _cloudGUID.Clear(); if (Cloud) Cloud->KillSelf(); SetWeather(WEATHER_STATE_FINE, 0.0f); - isRaining = false; + _isRaining = false; } me->m_Events.AddEventAtOffset([&] { - Unit* target = ObjectAccessor::GetUnit(*me, CloudGUID); + Unit* target = ObjectAccessor::GetUnit(*me, _cloudGUID); if (!target || !target->IsAlive()) return; - else if (Unit* Cyclone = ObjectAccessor::GetUnit(*me, CycloneGUID)) + else if (Unit* Cyclone = ObjectAccessor::GetUnit(*me, _cycloneGUID)) Cyclone->CastSpell(target, SPELL_SAND_STORM, true); // keep casting or... - HandleStormSequence(target); + HandleStormSequence(); }, 1s); } + void DoAction(int32 actionId) override + { + if (actionId == ACTION_INCREASE_STORM_COUNT) + ++_stormCount; + } + void SummonEagles() { Talk(SAY_SUMMON); @@ -271,7 +233,7 @@ class boss_akilzon : public CreatureScript for (uint8 i = 0; i < 8; ++i) { - Unit* bird = ObjectAccessor::GetUnit(*me, BirdGUIDs[i]); + Unit* bird = ObjectAccessor::GetUnit(*me, _birdGUIDs[i]); if (!bird) //they despawned on die { if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) @@ -287,19 +249,19 @@ class boss_akilzon : public CreatureScript { creature->AddThreat(me->GetVictim(), 1.0f); creature->AI()->AttackStart(me->GetVictim()); - BirdGUIDs[i] = creature->GetGUID(); + _birdGUIDs[i] = creature->GetGUID(); } } } } private: - ObjectGuid BirdGUIDs[8]; - ObjectGuid TargetGUID; - ObjectGuid CycloneGUID; - ObjectGuid CloudGUID; - uint8 StormCount; - bool isRaining; + ObjectGuid _birdGUIDs[8]; + ObjectGuid _targetGUID; + ObjectGuid _cycloneGUID; + ObjectGuid _cloudGUID; + uint8 _stormCount; + bool _isRaining; }; CreatureAI* GetAI(Creature* creature) const override @@ -308,89 +270,101 @@ class boss_akilzon : public CreatureScript } }; -class npc_akilzon_eagle : public CreatureScript +struct npc_akilzon_eagle : public ScriptedAI { -public: - npc_akilzon_eagle() : CreatureScript("npc_akilzon_eagle") { } + npc_akilzon_eagle(Creature* creature) : ScriptedAI(creature) { } - struct npc_akilzon_eagleAI : public ScriptedAI + uint32 EagleSwoop_Timer; + bool arrived; + ObjectGuid TargetGUID; + + void Reset() override { - npc_akilzon_eagleAI(Creature* creature) : ScriptedAI(creature) { } + EagleSwoop_Timer = urand(5000, 10000); + arrived = true; + TargetGUID.Clear(); + me->SetDisableGravity(true); + } - uint32 EagleSwoop_Timer; - bool arrived; - ObjectGuid TargetGUID; + void JustEngagedWith(Unit* /*who*/) override + { + DoZoneInCombat(); + } - void Reset() override - { - EagleSwoop_Timer = urand(5000, 10000); - arrived = true; - TargetGUID.Clear(); - me->SetDisableGravity(true); - } + void MoveInLineOfSight(Unit* /*who*/) override { } - void JustEngagedWith(Unit* /*who*/) override + void MovementInform(uint32, uint32) override + { + arrived = true; + if (TargetGUID) { - DoZoneInCombat(); + if (Unit* target = ObjectAccessor::GetUnit(*me, TargetGUID)) + DoCast(target, SPELL_EAGLE_SWOOP, true); + TargetGUID.Clear(); + me->SetSpeed(MOVE_RUN, 1.2f); + EagleSwoop_Timer = urand(5000, 10000); } + } - void MoveInLineOfSight(Unit* /*who*/) override { } - - void MovementInform(uint32, uint32) override - { - arrived = true; - if (TargetGUID) - { - if (Unit* target = ObjectAccessor::GetUnit(*me, TargetGUID)) - DoCast(target, SPELL_EAGLE_SWOOP, true); - TargetGUID.Clear(); - me->SetSpeed(MOVE_RUN, 1.2f); - EagleSwoop_Timer = urand(5000, 10000); - } - } + void UpdateAI(uint32 diff) override + { + if (EagleSwoop_Timer <= diff) + EagleSwoop_Timer = 0; + else + EagleSwoop_Timer -= diff; - void UpdateAI(uint32 diff) override + if (arrived) { - if (EagleSwoop_Timer <= diff) - EagleSwoop_Timer = 0; - else - EagleSwoop_Timer -= diff; - - if (arrived) + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) + float x, y, z; + if (EagleSwoop_Timer) { - float x, y, z; - if (EagleSwoop_Timer) - { - x = target->GetPositionX() + irand(-10, 10); - y = target->GetPositionY() + irand(-10, 10); - z = target->GetPositionZ() + urand(10, 15); - if (z > 95) - z = 95.0f - urand(0, 5); - } - else - { - target->GetContactPoint(me, x, y, z); - z += 2; - me->SetSpeed(MOVE_RUN, 5.0f); - TargetGUID = target->GetGUID(); - } - me->GetMotionMaster()->MovePoint(0, x, y, z); - arrived = false; + x = target->GetPositionX() + irand(-10, 10); + y = target->GetPositionY() + irand(-10, 10); + z = target->GetPositionZ() + urand(10, 15); + if (z > 95) + z = 95.0f - urand(0, 5); } + else + { + target->GetContactPoint(me, x, y, z); + z += 2; + me->SetSpeed(MOVE_RUN, 5.0f); + TargetGUID = target->GetGUID(); + } + me->GetMotionMaster()->MovePoint(0, x, y, z); + arrived = false; } } - }; + } +}; - CreatureAI* GetAI(Creature* creature) const override +// 43648 - Electrical Storm +class spell_electrial_storm : public AuraScript +{ + PrepareAuraScript(spell_electrial_storm); + + bool Load() override + { + return GetCaster() && GetCaster()->IsCreature(); + } + + void OnPeriodic(AuraEffect const* /*aurEff*/) + { + if (GetCaster()) + GetCaster()->ToCreature()->AI()->DoAction(ACTION_INCREASE_STORM_COUNT); + } + + void Register() override { - return GetZulAmanAI(creature); + OnEffectPeriodic += AuraEffectPeriodicFn(spell_electrial_storm::OnPeriodic, EFFECT_1, SPELL_AURA_PERIODIC_TRIGGER_SPELL); } }; void AddSC_boss_akilzon() { new boss_akilzon(); - new npc_akilzon_eagle(); + RegisterZulAmanCreatureAI(npc_akilzon_eagle); + RegisterSpellScript(spell_electrial_storm); } From 6ae57e232e67aad724a4bf1c2a695ed15cf1d9a6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 14 Nov 2024 01:59:30 +0000 Subject: [PATCH 072/105] chore(DB): import pending files Referenced commit(s): 1bea402e5ccb85403fc2664c96f3e31e291f980f --- .../rev_1731545993422354000.sql => db_world/2024_11_14_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731545993422354000.sql => db_world/2024_11_14_00.sql} (82%) diff --git a/data/sql/updates/pending_db_world/rev_1731545993422354000.sql b/data/sql/updates/db_world/2024_11_14_00.sql similarity index 82% rename from data/sql/updates/pending_db_world/rev_1731545993422354000.sql rename to data/sql/updates/db_world/2024_11_14_00.sql index a9555d49bb5d20..4e3e69b8aa02bd 100644 --- a/data/sql/updates/pending_db_world/rev_1731545993422354000.sql +++ b/data/sql/updates/db_world/2024_11_14_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_13_04 -> 2024_11_14_00 -- DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_electrial_storm' AND `spell_id` = 43648; INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES From 14980a91bce7d692ff132460396355587375c3c7 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Wed, 13 Nov 2024 23:18:27 -0300 Subject: [PATCH 073/105] fix(Scripts/ZulAman): Permbind players when using the gong (#20554) --- .../scripts/EasternKingdoms/ZulAman/zulaman.cpp | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp index 83a04cbf65b036..594d5fcebee3e9 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp @@ -15,17 +15,6 @@ * with this program. If not, see . */ -/* ScriptData -SDName: Zulaman -SD%Complete: 90 -SDComment: Forest Frog will turn into different NPC's. Workaround to prevent new entry from running this script -SDCategory: Zul'Aman -EndScriptData */ - -/* ContentData -npc_forest_frog -EndContentData */ - #include "zulaman.h" #include "CreatureScript.h" #include "Player.h" @@ -429,6 +418,7 @@ struct npc_harrison_jones : public ScriptedAI { if (action == ACTION_COMPLETE_EVENT_3) { + me->GetMap()->ToInstanceMap()->PermBindAllPlayers(); _gongEvent = GONG_EVENT_4; _gongTimer = 0; } From b7732690c97a285026db6653f296ad01c7ca72b6 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 00:00:52 -0300 Subject: [PATCH 074/105] refactor(Scripts/SunwellPlateau): Modernize Muru script (#20551) --- .../rev_1731534309713710300.sql | 5 + .../SunwellPlateau/boss_muru.cpp | 278 ++++++------------ 2 files changed, 96 insertions(+), 187 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1731534309713710300.sql diff --git a/data/sql/updates/pending_db_world/rev_1731534309713710300.sql b/data/sql/updates/pending_db_world/rev_1731534309713710300.sql new file mode 100644 index 00000000000000..20b284f409edcd --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731534309713710300.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_entropius_negative_energy'; +DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_entropius_negative_energy_periodic' AND `spell_id` = 46284; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(46284, 'spell_entropius_negative_energy_periodic'); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp index b1d7198945392a..c851ab105045a4 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp @@ -42,7 +42,6 @@ enum Spells // Entropius's spells SPELL_ENTROPIUS_COSMETIC_SPAWN = 46223, SPELL_NEGATIVE_ENERGY_PERIODIC = 46284, - SPELL_NEGATIVE_ENERGY_CHAIN = 46285, SPELL_BLACK_HOLE = 46282, SPELL_DARKNESS = 46268, SPELL_SUMMON_DARK_FIEND_ENTROPIUS = 46263, @@ -55,23 +54,6 @@ enum Spells SPELL_BLACK_HOLE_EFFECT = 46230 }; -enum Misc -{ - EVENT_SPELL_ENRAGE = 1, - EVENT_SUMMON_ENTROPIUS = 2, - EVENT_SET_INVISIBLE = 3, - EVENT_SPAWN_BLACK_HOLE = 4, - EVENT_SPAWN_DARKNESS = 5, - EVENT_START_BLACK_HOLE = 6, - EVENT_SWITCH_BLACK_HOLE_TARGET = 7, - EVENT_ENTROPIUS_AURAS = 8, - EVENT_ENTROPIUS_COMBAT = 9, - EVENT_SINGULARITY_DEATH = 10, - - DATA_ENRAGE_TIMER = 1, - DATA_NEGATIVE_ENERGY_TARGETS = 2 -}; - struct boss_muru : public BossAI { boss_muru(Creature* creature) : BossAI(creature, DATA_MURU) { } @@ -82,67 +64,46 @@ struct boss_muru : public BossAI me->SetReactState(REACT_AGGRESSIVE); me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); me->SetVisible(true); + me->m_Events.KillAllEvents(false); } void JustEngagedWith(Unit* who) override { BossAI::JustEngagedWith(who); - me->CastSpell(me, SPELL_NEGATIVE_ENERGY, true); - me->CastSpell(me, SPELL_SUMMON_BLOOD_ELVES_PERIODIC, true); - me->CastSpell(me, SPELL_OPEN_PORTAL_PERIODIC, true); - me->CastSpell(me, SPELL_DARKNESS_PERIODIC, true); + DoCastSelf(SPELL_NEGATIVE_ENERGY, true); + DoCastSelf(SPELL_SUMMON_BLOOD_ELVES_PERIODIC, true); + DoCastSelf(SPELL_OPEN_PORTAL_PERIODIC, true); + DoCastSelf(SPELL_DARKNESS_PERIODIC, true); + + me->m_Events.AddEventAtOffset([&] { + DoCastSelf(SPELL_ENRAGE, true); - events.ScheduleEvent(EVENT_SPELL_ENRAGE, 600000); + if (Creature* entropius = summons.GetCreatureWithEntry(NPC_ENTROPIUS)) + entropius->CastSpell(entropius, SPELL_ENRAGE, true); + }, 10min); } void DamageTaken(Unit*, uint32& damage, DamageEffectType, SpellSchoolMask) override { if (damage >= me->GetHealth()) { - damage = 0; + damage = me->GetHealth() - 1; if (!me->HasUnitFlag(UNIT_FLAG_NOT_SELECTABLE)) { me->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); me->RemoveAllAuras(); - me->CastSpell(me, SPELL_OPEN_ALL_PORTALS, true); - events.ScheduleEvent(EVENT_SUMMON_ENTROPIUS, 7000); - } - } - } + DoCastSelf(SPELL_OPEN_ALL_PORTALS, true); - void JustSummoned(Creature* summon) override - { - if (summon->GetEntry() == NPC_ENTROPIUS) - summon->AI()->SetData(DATA_ENRAGE_TIMER, events.GetNextEventTime(EVENT_SPELL_ENRAGE)); - else - { - if (!summon->IsTrigger()) - summon->SetInCombatWithZone(); - summons.Summon(summon); - } - } + me->m_Events.AddEventAtOffset([&] + { + DoCastAOE(SPELL_SUMMON_ENTROPIUS); + }, 7s); - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SUMMON_ENTROPIUS: - me->CastSpell(me, SPELL_SUMMON_ENTROPIUS, false); - events.ScheduleEvent(EVENT_SET_INVISIBLE, 1000); - break; - case EVENT_SET_INVISIBLE: - me->SetVisible(false); - break; + me->m_Events.AddEventAtOffset([&] + { + me->SetVisible(false); + }, 8s); + } } } }; @@ -151,16 +112,20 @@ struct boss_entropius : public ScriptedAI { boss_entropius(Creature* creature) : ScriptedAI(creature) { } - EventMap events; - EventMap events2; - void Reset() override { - events.Reset(); - events2.Reset(); - events2.ScheduleEvent(EVENT_ENTROPIUS_AURAS, 0); - events2.ScheduleEvent(EVENT_ENTROPIUS_COMBAT, 3000); + scheduler.CancelAll(); + + DoCastSelf(SPELL_ENTROPIUS_COSMETIC_SPAWN); + DoCastSelf(SPELL_NEGATIVE_ENERGY_PERIODIC, true); + me->SetReactState(REACT_PASSIVE); + + me->m_Events.AddEventAtOffset([&] { + me->SetReactState(REACT_AGGRESSIVE); + me->SetInCombatWithZone(); + AttackStart(SelectTargetFromPlayerList(50.0f)); + }, 3s); } void EnterEvadeMode(EvadeReason why) override @@ -175,123 +140,72 @@ struct boss_entropius : public ScriptedAI void JustEngagedWith(Unit* /*who*/) override { - events.ScheduleEvent(EVENT_SPAWN_BLACK_HOLE, 15000); - events.ScheduleEvent(EVENT_SPAWN_DARKNESS, 10000); - } - - void SetData(uint32 type, uint32 data) override - { - if (type == DATA_ENRAGE_TIMER) - events.ScheduleEvent(EVENT_SPELL_ENRAGE, data); - } + ScheduleTimedEvent(10s, [&] { + DoCastRandomTarget(SPELL_DARKNESS, 0, 50.0f, true, true); + }, 15s); - uint32 GetData(uint32 type) const override - { - if (type == DATA_NEGATIVE_ENERGY_TARGETS) - return 1 + uint32(events.GetTimer() / 12000); - return 0; + ScheduleTimedEvent(15s, [&] { + DoCastRandomTarget(SPELL_BLACK_HOLE, 0, 50.0f, true, true); + }, 15s); } void JustDied(Unit* /*killer*/) override { if (InstanceScript* instance = me->GetInstanceScript()) if (Creature* muru = instance->GetCreature(DATA_MURU)) - Unit::Kill(muru, muru); + muru->KillSelf(); } void UpdateAI(uint32 diff) override { - events2.Update(diff); - switch (events2.ExecuteEvent()) - { - case EVENT_ENTROPIUS_AURAS: - me->CastSpell(me, SPELL_ENTROPIUS_COSMETIC_SPAWN, false); - me->CastSpell(me, SPELL_NEGATIVE_ENERGY_PERIODIC, true); - break; - case EVENT_ENTROPIUS_COMBAT: - me->SetReactState(REACT_AGGRESSIVE); - me->SetInCombatWithZone(); - AttackStart(SelectTargetFromPlayerList(50.0f)); - break; - } - - if (!events2.Empty()) - return; - if (!UpdateVictim()) return; - events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - switch (events.ExecuteEvent()) - { - case EVENT_SPELL_ENRAGE: - me->CastSpell(me, SPELL_ENRAGE, true); - break; - case EVENT_SPAWN_DARKNESS: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) - me->CastSpell(target, SPELL_DARKNESS, true); - events.ScheduleEvent(EVENT_SPAWN_DARKNESS, 15000); - break; - case EVENT_SPAWN_BLACK_HOLE: - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) - me->CastSpell(target, SPELL_BLACK_HOLE, true); - events.ScheduleEvent(EVENT_SPAWN_BLACK_HOLE, 15000); - break; - } - - DoMeleeAttackIfReady(); + scheduler.Update(diff); } }; struct npc_singularity : public NullCreatureAI { - npc_singularity(Creature* creature) : NullCreatureAI(creature) - { - } - - EventMap events; + npc_singularity(Creature* creature) : NullCreatureAI(creature) { } void Reset() override { me->DespawnOrUnsummon(18000); - me->CastSpell(me, SPELL_BLACK_HOLE_SUMMON_VISUAL, true); - me->CastSpell(me, SPELL_BLACK_HOLE_SUMMON_VISUAL2, true); - events.ScheduleEvent(EVENT_START_BLACK_HOLE, 3500); - events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 5000); - events.ScheduleEvent(EVENT_SINGULARITY_DEATH, 17000); - } + DoCastSelf(SPELL_BLACK_HOLE_SUMMON_VISUAL, true); + DoCastSelf(SPELL_BLACK_HOLE_SUMMON_VISUAL2, true); - void UpdateAI(uint32 diff) override - { - events.Update(diff); - switch (events.ExecuteEvent()) - { - case EVENT_SINGULARITY_DEATH: + me->m_Events.AddEventAtOffset([&] { me->KillSelf(); - break; - case EVENT_START_BLACK_HOLE: + }, 17s); + + me->m_Events.AddEventAtOffset([&] { me->RemoveAurasDueToSpell(SPELL_BLACK_HOLE_SUMMON_VISUAL2); - me->CastSpell(me, SPELL_BLACK_HOLE_VISUAL2, true); - me->CastSpell(me, SPELL_BLACK_HOLE_PASSIVE, true); - break; - case EVENT_SWITCH_BLACK_HOLE_TARGET: + DoCastSelf(SPELL_BLACK_HOLE_VISUAL2, true); + DoCastSelf(SPELL_BLACK_HOLE_PASSIVE, true); + }, 3500ms); + + scheduler.Schedule(5s, [this](TaskContext context) { - Map::PlayerList const& players = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr) - if (Player* player = itr->GetSource()) + auto const& playerList = me->GetMap()->GetPlayers(); + for (auto const& playerRef : playerList) + { + if (Player* player = playerRef.GetSource()) if (me->GetDistance2d(player) < 15.0f && player->GetPositionZ() < 72.0f && player->IsAlive() && !player->HasAura(SPELL_BLACK_HOLE_EFFECT)) { me->GetMotionMaster()->MovePoint(0, player->GetPositionX(), player->GetPositionY(), player->GetPositionZ(), false, true); - events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 5000); + context.Repeat(); return; } - events.ScheduleEvent(EVENT_SWITCH_BLACK_HOLE_TARGET, 500); - break; - } - } + } + + context.Repeat(1s); + }); + } + + void UpdateAI(uint32 diff) override + { + scheduler.Update(diff); } }; @@ -349,39 +263,6 @@ class spell_muru_darkness_aura : public AuraScript } }; -class spell_entropius_negative_energy : public SpellScript -{ - PrepareSpellScript(spell_entropius_negative_energy); - - bool Validate(SpellInfo const* /*spellInfo*/) override - { - return ValidateSpellInfo({ SPELL_NEGATIVE_ENERGY_CHAIN }); - } - - bool Load() override - { - return GetCaster()->IsCreature(); - } - - void FilterTargets(std::list& targets) - { - Acore::Containers::RandomResize(targets, GetCaster()->GetAI()->GetData(DATA_NEGATIVE_ENERGY_TARGETS)); - } - - void HandleScriptEffect(SpellEffIndex effIndex) - { - PreventHitDefaultEffect(effIndex); - if (Unit* target = GetHitUnit()) - GetCaster()->CastSpell(target, SPELL_NEGATIVE_ENERGY_CHAIN, true); - } - - void Register() override - { - OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_entropius_negative_energy::FilterTargets, EFFECT_0, TARGET_UNIT_SRC_AREA_ENEMY); - OnEffectHitTarget += SpellEffectFn(spell_entropius_negative_energy::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); - } -}; - class spell_entropius_void_zone_visual_aura : public AuraScript { PrepareAuraScript(spell_entropius_void_zone_visual_aura); @@ -440,6 +321,29 @@ class spell_entropius_black_hole_effect : public SpellScript } }; +// 46284 - Negative Energy Periodic +class spell_entropius_negative_energy_periodic : public AuraScript +{ + PrepareAuraScript(spell_entropius_negative_energy_periodic); + + bool Validate(SpellInfo const* spellInfo) override + { + return ValidateSpellInfo({ spellInfo->Effects[EFFECT_0].TriggerSpell }); + } + + void PeriodicTick(AuraEffect const* aurEff) + { + PreventDefaultAction(); + uint32 targetCount = aurEff->GetTickNumber() > 12 ? 1 : aurEff->GetTickNumber() / 12; + GetTarget()->CastCustomSpell(aurEff->GetSpellInfo()->Effects[EFFECT_0].TriggerSpell, SPELLVALUE_MAX_TARGETS, targetCount); + } + + void Register() override + { + OnEffectPeriodic += AuraEffectPeriodicFn(spell_entropius_negative_energy_periodic::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); + } +}; + void AddSC_boss_muru() { RegisterSunwellPlateauCreatureAI(boss_muru); @@ -448,7 +352,7 @@ void AddSC_boss_muru() RegisterSpellScript(spell_muru_summon_blood_elves_periodic_aura); RegisterSpellScript(spell_muru_darkness_aura); - RegisterSpellScript(spell_entropius_negative_energy); RegisterSpellScript(spell_entropius_void_zone_visual_aura); RegisterSpellScript(spell_entropius_black_hole_effect); + RegisterSpellScript(spell_entropius_negative_energy_periodic); } From 587762ca36a69ab311b7ce87c6e48f76ed87b714 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 00:01:22 -0300 Subject: [PATCH 075/105] fix(Core/Instance): Save persistent data to DB on updates (#20555) --- src/server/game/Instances/InstanceScript.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/server/game/Instances/InstanceScript.cpp b/src/server/game/Instances/InstanceScript.cpp index 593aab04aa6e9d..bbc160c01035c4 100644 --- a/src/server/game/Instances/InstanceScript.cpp +++ b/src/server/game/Instances/InstanceScript.cpp @@ -393,7 +393,11 @@ void InstanceScript::StorePersistentData(uint32 index, uint32 data) return; } - persistentData[index] = data; + if (persistentData[index] != data) + { + persistentData[index] = data; + SaveToDB(); + } } void InstanceScript::DoForAllMinions(uint32 id, std::function exec) From 0fc6f468e6cf0c6f15a58bc02146a239965a7cbc Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 14 Nov 2024 03:01:47 +0000 Subject: [PATCH 076/105] chore(DB): import pending files Referenced commit(s): b7732690c97a285026db6653f296ad01c7ca72b6 --- .../rev_1731534309713710300.sql => db_world/2024_11_14_01.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731534309713710300.sql => db_world/2024_11_14_01.sql} (88%) diff --git a/data/sql/updates/pending_db_world/rev_1731534309713710300.sql b/data/sql/updates/db_world/2024_11_14_01.sql similarity index 88% rename from data/sql/updates/pending_db_world/rev_1731534309713710300.sql rename to data/sql/updates/db_world/2024_11_14_01.sql index 20b284f409edcd..0cdf5c27ab0acd 100644 --- a/data/sql/updates/pending_db_world/rev_1731534309713710300.sql +++ b/data/sql/updates/db_world/2024_11_14_01.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_14_00 -> 2024_11_14_01 -- DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_entropius_negative_energy'; DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_entropius_negative_energy_periodic' AND `spell_id` = 46284; From e2020e088658b9e38a0f93c640016f661337f0b3 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 03:29:43 -0300 Subject: [PATCH 077/105] chore(Scripts/ZulAman): Update Akilzon to new register method (#20556) --- .../EasternKingdoms/ZulAman/boss_akilzon.cpp | 335 +++++++++--------- 1 file changed, 162 insertions(+), 173 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp index 5972ea2ea8d5c9..5a769f256c006c 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp @@ -57,217 +57,206 @@ enum Misc constexpr auto NPC_SOARING_EAGLE = 24858; -class boss_akilzon : public CreatureScript +struct boss_akilzon : public BossAI { -public: - boss_akilzon() : CreatureScript("boss_akilzon") { } + boss_akilzon(Creature* creature) : BossAI(creature, DATA_AKILZON), _stormCount(0), _isRaining(false) { } - struct boss_akilzonAI : public BossAI + void Reset() override { - boss_akilzonAI(Creature* creature) : BossAI(creature, DATA_AKILZON) { } + _Reset(); - void Reset() override - { - _Reset(); + _targetGUID.Clear(); + _cloudGUID.Clear(); + _cycloneGUID.Clear(); - _targetGUID.Clear(); - _cloudGUID.Clear(); - _cycloneGUID.Clear(); - - _stormCount = 0; - _isRaining = false; + _stormCount = 0; + _isRaining = false; - SetWeather(WEATHER_STATE_FINE, 0.0f); + SetWeather(WEATHER_STATE_FINE, 0.0f); - me->m_Events.KillAllEvents(false); - } + me->m_Events.KillAllEvents(false); + } - void JustEngagedWith(Unit* /*who*/) override - { - _JustEngagedWith(); + void JustEngagedWith(Unit* /*who*/) override + { + _JustEngagedWith(); - ScheduleTimedEvent(10s, 20s, [&]{ - Unit* target = SelectTarget(SelectTargetMethod::Random, 1); - if (!target) - target = me->GetVictim(); - if (target) - { - _targetGUID = target->GetGUID(); - DoCast(target, SPELL_STATIC_DISRUPTION, false); - me->SetInFront(me->GetVictim()); - } - }, 10s, 18s); - - ScheduleTimedEvent(20s, 30s, [&] { - Unit* target = SelectTarget(SelectTargetMethod::Random, 1); - if (!target) - target = me->GetVictim(); - if (target) - DoCast(target, SPELL_GUST_OF_WIND); - }, 20s, 30s); - - ScheduleTimedEvent(10s, 20s, [&] { - DoCastVictim(SPELL_CALL_LIGHTNING); - }, 12s, 17s); - - ScheduleTimedEvent(1min, [&] { - Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50, true); - if (!target) - { - EnterEvadeMode(); - return; - } - target->CastSpell(target, SPELL_ELECTRICAL_STORM_AREA, true); // cloud visual - DoCast(target, SPELL_ELECTRICAL_STORM); // storm cyclon + visual - float x, y, z; - target->GetPosition(x, y, z); + ScheduleTimedEvent(10s, 20s, [&] { + Unit* target = SelectTarget(SelectTargetMethod::Random, 1); + if (!target) + target = me->GetVictim(); + if (target) + { + _targetGUID = target->GetGUID(); + DoCast(target, SPELL_STATIC_DISRUPTION, false); + me->SetInFront(me->GetVictim()); + } + }, 10s, 18s); + + ScheduleTimedEvent(20s, 30s, [&] { + Unit* target = SelectTarget(SelectTargetMethod::Random, 1); + if (!target) + target = me->GetVictim(); + if (target) + DoCast(target, SPELL_GUST_OF_WIND); + }, 20s, 30s); + + ScheduleTimedEvent(10s, 20s, [&] { + DoCastVictim(SPELL_CALL_LIGHTNING); + }, 12s, 17s); + + ScheduleTimedEvent(1min, [&] { + Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50, true); + if (!target) + { + EnterEvadeMode(); + return; + } + target->CastSpell(target, SPELL_ELECTRICAL_STORM_AREA, true); // cloud visual + DoCast(target, SPELL_ELECTRICAL_STORM); // storm cyclon + visual + float x, y, z; + target->GetPosition(x, y, z); - Unit* Cloud = me->SummonTrigger(x, y, me->GetPositionZ() + 16, 0, 15000); - if (Cloud) - { - target->GetMotionMaster()->MoveJump(Cloud->GetPosition(), 1.0f, 1.0f); - - _cloudGUID = Cloud->GetGUID(); - Cloud->SetDisableGravity(true); - Cloud->StopMoving(); - Cloud->SetObjectScale(1.0f); - Cloud->SetFaction(FACTION_FRIENDLY); - Cloud->SetMaxHealth(9999999); - Cloud->SetHealth(9999999); - Cloud->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - - me->m_Events.AddEventAtOffset([&] { - HandleStormSequence(); - }, 3s); - } + Unit* Cloud = me->SummonTrigger(x, y, me->GetPositionZ() + 16, 0, 15000); + if (Cloud) + { + target->GetMotionMaster()->MoveJump(Cloud->GetPosition(), 1.0f, 1.0f); - _stormCount = 1; + _cloudGUID = Cloud->GetGUID(); + Cloud->SetDisableGravity(true); + Cloud->StopMoving(); + Cloud->SetObjectScale(1.0f); + Cloud->SetFaction(FACTION_FRIENDLY); + Cloud->SetMaxHealth(9999999); + Cloud->SetHealth(9999999); + Cloud->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); me->m_Events.AddEventAtOffset([&] { - if (!_isRaining) - { - SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); - _isRaining = true; - } - }, Seconds(urand(47, 52))); - }, 1min); - - ScheduleTimedEvent(47s, 52s, [&] { + HandleStormSequence(); + }, 3s); + } + + _stormCount = 1; + + me->m_Events.AddEventAtOffset([&] { if (!_isRaining) { SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); _isRaining = true; } - }, 47s, 52s); + }, Seconds(urand(47, 52))); + }, 1min); - me->m_Events.AddEventAtOffset([&] { - Talk(SAY_ENRAGE); - DoCastSelf(SPELL_BERSERK, true); - }, 10min); + ScheduleTimedEvent(47s, 52s, [&] { + if (!_isRaining) + { + SetWeather(WEATHER_STATE_HEAVY_RAIN, 0.9999f); + _isRaining = true; + } + }, 47s, 52s); - Talk(SAY_AGGRO); - } + me->m_Events.AddEventAtOffset([&] { + Talk(SAY_ENRAGE); + DoCastSelf(SPELL_BERSERK, true); + }, 10min); - void JustDied(Unit* /*killer*/) override - { - Talk(SAY_DEATH); - _JustDied(); - me->m_Events.KillAllEvents(false); - } + Talk(SAY_AGGRO); + } - void KilledUnit(Unit* who) override - { - if (who->IsPlayer()) - Talk(SAY_KILL); - } + void JustDied(Unit* /*killer*/) override + { + Talk(SAY_DEATH); + _JustDied(); + me->m_Events.KillAllEvents(false); + } - void SetWeather(uint32 weather, float grade) - { - me->GetMap()->SetZoneWeather(me->GetZoneId(), WeatherState(weather), grade); - } + void KilledUnit(Unit* who) override + { + if (who->IsPlayer()) + Talk(SAY_KILL); + } - void HandleStormSequence() // 1: begin, 2-9: tick, 10: end - { - Creature* Cloud = ObjectAccessor::GetCreature(*me, _cloudGUID); - if (!Cloud) - return; + void SetWeather(uint32 weather, float grade) + { + me->GetMap()->SetZoneWeather(me->GetZoneId(), WeatherState(weather), grade); + } - if (_stormCount > 10) - { - _stormCount = 0; // finish + void HandleStormSequence() // 1: begin, 2-9: tick, 10: end + { + Creature* Cloud = ObjectAccessor::GetCreature(*me, _cloudGUID); + if (!Cloud) + return; - me->m_Events.AddEventAtOffset([&] { - SummonEagles(); - }, 5s); - - me->InterruptNonMeleeSpells(false); - _cloudGUID.Clear(); - if (Cloud) - Cloud->KillSelf(); - SetWeather(WEATHER_STATE_FINE, 0.0f); - _isRaining = false; - } + if (_stormCount > 10) + { + _stormCount = 0; // finish me->m_Events.AddEventAtOffset([&] { - Unit* target = ObjectAccessor::GetUnit(*me, _cloudGUID); - if (!target || !target->IsAlive()) - return; - else if (Unit* Cyclone = ObjectAccessor::GetUnit(*me, _cycloneGUID)) - Cyclone->CastSpell(target, SPELL_SAND_STORM, true); // keep casting or... - HandleStormSequence(); - }, 1s); - } + SummonEagles(); + }, 5s); - void DoAction(int32 actionId) override - { - if (actionId == ACTION_INCREASE_STORM_COUNT) - ++_stormCount; + me->InterruptNonMeleeSpells(false); + _cloudGUID.Clear(); + if (Cloud) + Cloud->KillSelf(); + SetWeather(WEATHER_STATE_FINE, 0.0f); + _isRaining = false; } - void SummonEagles() - { - Talk(SAY_SUMMON); + me->m_Events.AddEventAtOffset([&] { + Unit* target = ObjectAccessor::GetUnit(*me, _cloudGUID); + if (!target || !target->IsAlive()) + return; + else if (Unit* Cyclone = ObjectAccessor::GetUnit(*me, _cycloneGUID)) + Cyclone->CastSpell(target, SPELL_SAND_STORM, true); // keep casting or... + HandleStormSequence(); + }, 1s); + } - float x, y, z; - me->GetPosition(x, y, z); + void DoAction(int32 actionId) override + { + if (actionId == ACTION_INCREASE_STORM_COUNT) + ++_stormCount; + } - for (uint8 i = 0; i < 8; ++i) + void SummonEagles() + { + Talk(SAY_SUMMON); + + float x, y, z; + me->GetPosition(x, y, z); + + for (uint8 i = 0; i < 8; ++i) + { + Unit* bird = ObjectAccessor::GetUnit(*me, _birdGUIDs[i]); + if (!bird) //they despawned on die { - Unit* bird = ObjectAccessor::GetUnit(*me, _birdGUIDs[i]); - if (!bird) //they despawned on die + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) { - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - { - x = target->GetPositionX() + irand(-10, 10); - y = target->GetPositionY() + irand(-10, 10); - z = target->GetPositionZ() + urand(16, 20); - if (z > 95) - z = 95.0f - urand(0, 5); - } -; - if (Creature* creature = me->SummonCreature(NPC_SOARING_EAGLE, x, y, z, 0, TEMPSUMMON_CORPSE_DESPAWN, 0)) - { - creature->AddThreat(me->GetVictim(), 1.0f); - creature->AI()->AttackStart(me->GetVictim()); - _birdGUIDs[i] = creature->GetGUID(); - } + x = target->GetPositionX() + irand(-10, 10); + y = target->GetPositionY() + irand(-10, 10); + z = target->GetPositionZ() + urand(16, 20); + if (z > 95) + z = 95.0f - urand(0, 5); + } + ; + if (Creature* creature = me->SummonCreature(NPC_SOARING_EAGLE, x, y, z, 0, TEMPSUMMON_CORPSE_DESPAWN, 0)) + { + creature->AddThreat(me->GetVictim(), 1.0f); + creature->AI()->AttackStart(me->GetVictim()); + _birdGUIDs[i] = creature->GetGUID(); } } } - - private: - ObjectGuid _birdGUIDs[8]; - ObjectGuid _targetGUID; - ObjectGuid _cycloneGUID; - ObjectGuid _cloudGUID; - uint8 _stormCount; - bool _isRaining; - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return GetZulAmanAI(creature); } + +private: + ObjectGuid _birdGUIDs[8]; + ObjectGuid _targetGUID; + ObjectGuid _cycloneGUID; + ObjectGuid _cloudGUID; + uint8 _stormCount; + bool _isRaining; }; struct npc_akilzon_eagle : public ScriptedAI @@ -364,7 +353,7 @@ class spell_electrial_storm : public AuraScript void AddSC_boss_akilzon() { - new boss_akilzon(); + RegisterZulAmanCreatureAI(boss_akilzon); RegisterZulAmanCreatureAI(npc_akilzon_eagle); RegisterSpellScript(spell_electrial_storm); } From 7746287ee12e615358eb1a9a1b221fcd66fd1b86 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 03:37:23 -0300 Subject: [PATCH 078/105] fix(Core/Spells): Fix Lay on Hands healing bypassing Cyclone (#20552) * fix(Core/Spells): Fix Lay on Hands healing bypassing Cyclone * and mana as well --- src/server/game/Spells/SpellEffects.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index 72570afac73245..811dea160d4aaf 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -1885,6 +1885,12 @@ void Spell::EffectEnergize(SpellEffIndex effIndex) if (!unitTarget->IsAlive()) return; + if (unitTarget->HasUnitState(UNIT_STATE_ISOLATED)) + { + m_caster->SendSpellDamageImmune(unitTarget, GetSpellInfo()->Id); + return; + } + if (m_spellInfo->Effects[effIndex].MiscValue < 0 || m_spellInfo->Effects[effIndex].MiscValue >= int8(MAX_POWERS)) return; @@ -3679,6 +3685,12 @@ void Spell::EffectHealMaxHealth(SpellEffIndex /*effIndex*/) if (!unitTarget || !unitTarget->IsAlive()) return; + if (unitTarget->HasUnitState(UNIT_STATE_ISOLATED)) + { + m_caster->SendSpellDamageImmune(unitTarget, GetSpellInfo()->Id); + return; + } + int32 addhealth = 0; // damage == 0 - heal for caster max health From 87fbdb7967094f19a00a3e5623115588c689cae6 Mon Sep 17 00:00:00 2001 From: silviu20092 Date: Thu, 14 Nov 2024 10:35:26 +0200 Subject: [PATCH 079/105] feat(Core/Scripting): Add hook for applying weapon damage (#20350) Add hook for applying weapon damage --- src/server/game/Entities/Player/Player.cpp | 2 ++ src/server/game/Scripting/ScriptDefines/PlayerScript.cpp | 5 +++++ src/server/game/Scripting/ScriptDefines/PlayerScript.h | 3 +++ src/server/game/Scripting/ScriptMgr.h | 1 + 4 files changed, 11 insertions(+) diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index eca6924736a155..f4a57e656a40c8 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -6936,6 +6936,8 @@ void Player::_ApplyWeaponDamage(uint8 slot, ItemTemplate const* proto, ScalingSt if (apply) { + sScriptMgr->OnApplyWeaponDamage(this, slot, proto, minDamage, maxDamage, i); + if (minDamage > 0.f) { SetBaseWeaponDamage(WeaponAttackType(attType), MINDAMAGE, minDamage, i); diff --git a/src/server/game/Scripting/ScriptDefines/PlayerScript.cpp b/src/server/game/Scripting/ScriptDefines/PlayerScript.cpp index 9c6769f4587601..30d8021c6ca0b9 100644 --- a/src/server/game/Scripting/ScriptDefines/PlayerScript.cpp +++ b/src/server/game/Scripting/ScriptDefines/PlayerScript.cpp @@ -644,6 +644,11 @@ void ScriptMgr::OnApplyEnchantmentItemModsBefore(Player* player, Item* item, Enc CALL_ENABLED_HOOKS(PlayerScript, PLAYERHOOK_ON_APPLY_ENCHANTMENT_ITEM_MODS_BEFORE, script->OnApplyEnchantmentItemModsBefore(player, item, slot, apply, enchant_spell_id, enchant_amount)); } +void ScriptMgr::OnApplyWeaponDamage(Player* player, uint8 slot, ItemTemplate const* proto, float& minDamage, float& maxDamage, uint8 damageIndex) +{ + CALL_ENABLED_HOOKS(PlayerScript, PLAYERHOOK_ON_APPLY_WEAPON_DAMAGE, script->OnApplyWeaponDamage(player, slot, proto, minDamage, maxDamage, damageIndex)); +} + bool ScriptMgr::CanArmorDamageModifier(Player* player) { CALL_ENABLED_BOOLEAN_HOOKS(PlayerScript, PLAYERHOOK_CAN_ARMOR_DAMAGE_MODIFIER, !script->CanArmorDamageModifier(player)); diff --git a/src/server/game/Scripting/ScriptDefines/PlayerScript.h b/src/server/game/Scripting/ScriptDefines/PlayerScript.h index 21df41a2d053a2..388203b4095a96 100644 --- a/src/server/game/Scripting/ScriptDefines/PlayerScript.h +++ b/src/server/game/Scripting/ScriptDefines/PlayerScript.h @@ -150,6 +150,7 @@ enum PlayerHook PLAYERHOOK_ON_CUSTOM_SCALING_STAT_VALUE, PLAYERHOOK_ON_APPLY_ITEM_MODS_BEFORE, PLAYERHOOK_ON_APPLY_ENCHANTMENT_ITEM_MODS_BEFORE, + PLAYERHOOK_ON_APPLY_WEAPON_DAMAGE, PLAYERHOOK_CAN_ARMOR_DAMAGE_MODIFIER, PLAYERHOOK_ON_GET_FERAL_AP_BONUS, PLAYERHOOK_CAN_APPLY_WEAPON_DEPENDENT_AURA_DAMAGE_MOD, @@ -547,6 +548,8 @@ class PlayerScript : public ScriptObject virtual void OnApplyEnchantmentItemModsBefore(Player* /*player*/, Item* /*item*/, EnchantmentSlot /*slot*/, bool /*apply*/, uint32 /*enchant_spell_id*/, uint32& /*enchant_amount*/) { } + virtual void OnApplyWeaponDamage(Player* /*player*/, uint8 /*slot*/, ItemTemplate const* /*proto*/, float& /*minDamage*/, float& /*maxDamage*/, uint8 /*damageIndex*/) { } + [[nodiscard]] virtual bool CanArmorDamageModifier(Player* /*player*/) { return true; } virtual void OnGetFeralApBonus(Player* /*player*/, int32& /*feral_bonus*/, int32 /*dpsMod*/, ItemTemplate const* /*proto*/, ScalingStatValuesEntry const* /*ssv*/) { } diff --git a/src/server/game/Scripting/ScriptMgr.h b/src/server/game/Scripting/ScriptMgr.h index 85d29a2bb5babb..7d074dbf7804cb 100644 --- a/src/server/game/Scripting/ScriptMgr.h +++ b/src/server/game/Scripting/ScriptMgr.h @@ -411,6 +411,7 @@ class ScriptMgr void OnCustomScalingStatValue(Player* player, ItemTemplate const* proto, uint32& statType, int32& val, uint8 itemProtoStatNumber, uint32 ScalingStatValue, ScalingStatValuesEntry const* ssv); void OnApplyItemModsBefore(Player* player, uint8 slot, bool apply, uint8 itemProtoStatNumber, uint32 statType, int32& val); void OnApplyEnchantmentItemModsBefore(Player* player, Item* item, EnchantmentSlot slot, bool apply, uint32 enchant_spell_id, uint32& enchant_amount); + void OnApplyWeaponDamage(Player* player, uint8 slot, ItemTemplate const* proto, float& minDamage, float& maxDamage, uint8 damageIndex); bool CanArmorDamageModifier(Player* player); void OnGetFeralApBonus(Player* player, int32& feral_bonus, int32 dpsMod, ItemTemplate const* proto, ScalingStatValuesEntry const* ssv); bool CanApplyWeaponDependentAuraDamageMod(Player* player, Item* item, WeaponAttackType attackType, AuraEffect const* aura, bool apply); From 980b9246c8f207135feeed45e6a2a92ccea2a5e9 Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Thu, 14 Nov 2024 10:06:42 +0100 Subject: [PATCH 080/105] fix(Scripts/TheEye): Kael'thas advisors, refactor and RP (#20188) refactor to use base advisor class refactor doaction extract phase enchanted weapons sql delete script kael_phase_two --- .../rev_1726878416572918109.sql | 5 + .../Outland/TempestKeep/Eye/boss_kaelthas.cpp | 486 ++++++------------ 2 files changed, 150 insertions(+), 341 deletions(-) create mode 100644 data/sql/updates/pending_db_world/rev_1726878416572918109.sql diff --git a/data/sql/updates/pending_db_world/rev_1726878416572918109.sql b/data/sql/updates/pending_db_world/rev_1726878416572918109.sql new file mode 100644 index 00000000000000..db88fba2dea441 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1726878416572918109.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `spell_script_names` WHERE `spell_id`=36450 AND `ScriptName`='spell_kaelthas_resurrection'; +DELETE FROM `spell_script_names` WHERE `spell_id`=36709 AND `ScriptName`='spell_kaelthas_kael_phase_two'; +-- fix entry from 19871 to Kael'thas for ID - 36709 Kael Phase Two +UPDATE `conditions` SET `ConditionValue2` = 19622 WHERE (`SourceTypeOrReferenceId` = 13) AND (`SourceGroup` = 1) AND (`SourceEntry` = 36709) AND (`SourceId` = 0) AND (`ConditionTypeOrReference` = 31); diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp index c22920f8de5311..745bc2c95b883a 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp @@ -43,14 +43,8 @@ enum KTYells SAY_PYROBLAST = 14, // Advisors - SAY_THALADRED_AGGRO = 0, - SAY_SANGUINAR_AGGRO = 0, - SAY_CAPERNIAN_AGGRO = 0, - SAY_TELONICUS_AGGRO = 0, - SAY_THALADRED_DEATH = 1, - SAY_SANGUINAR_DEATH = 1, - SAY_CAPERNIAN_DEATH = 1, - SAY_TELONICUS_DEATH = 1, + SAY_ADVISOR_AGGRO = 0, + SAY_ADVISOR_DEATH = 1, EMOTE_THALADRED_FIXATE = 2 }; @@ -120,6 +114,7 @@ enum KTSpells // Advisors // Universal SPELL_KAEL_PHASE_TWO = 36709, + SPELL_PERMANENT_FEIGN_DEATH = 29266, // placed upon advisors on fake death // Sanguinar SPELL_BELLOWING_ROAR = 44863, @@ -166,11 +161,10 @@ enum KTMisc enum KTPreFightEvents { EVENT_PREFIGHT_PHASE1_01 = 1, - EVENT_PREFIGHT_PHASE1_02 = 2, - EVENT_PREFIGHT_PHASE5_01 = 3, - EVENT_PREFIGHT_PHASE5_02 = 4, - EVENT_PREFIGHT_PHASE6_02 = 5, - EVENT_PREFIGHT_PHASE6_03 = 6, + EVENT_PREFIGHT_PHASE5_01 = 2, + EVENT_PREFIGHT_PHASE5_02 = 3, + EVENT_PREFIGHT_PHASE6_02 = 4, + EVENT_PREFIGHT_PHASE6_03 = 5, }; enum KTTransitionScene @@ -197,11 +191,12 @@ enum KTTransitionScene enum KTActions { - ACTION_START_SANGUINAR = 0, - ACTION_START_CAPERNIAN = 1, - ACTION_START_TELONICUS = 2, - ACTION_START_WEAPONS = 3, - ACTION_PROGRESS_PHASE_CHECK = 4 + ACTION_START_THALADRED = 0, + ACTION_START_SANGUINAR = 1, + ACTION_START_CAPERNIAN = 2, + ACTION_START_TELONICUS = 3, + ACTION_START_WEAPONS = 4, + ACTION_PROGRESS_PHASE_CHECK = 5 }; enum KTSpellGroups @@ -241,24 +236,6 @@ struct boss_kaelthas : public BossAI } } - void SetData(uint32 type, uint32 data) override - { - if (type == DATA_RESURRECT_CAST && data == DATA_RESURRECT_CAST) - { - summons.DoForAllSummons([&](WorldObject* summon){ - if (Creature* summonedCreature = summon->ToCreature()) - { - if (summonedCreature->GetEntry() >= NPC_LORD_SANGUINAR && summonedCreature->GetEntry() <= NPC_THALADRED) - { - summonedCreature->SetReactState(REACT_PASSIVE); - summonedCreature->setDeathState(DeathState::JustRespawned); - summonedCreature->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); - } - } - }); - } - } - void SetRoomState(GOState state) { //TODO: handle door closing @@ -280,6 +257,7 @@ struct boss_kaelthas : public BossAI _phase = PHASE_NONE; _transitionSceneReached = false; + _advisorsAlive = 4; me->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_HOVER, true); // hover effect 36550 - Floating Drowned me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); @@ -304,21 +282,10 @@ struct boss_kaelthas : public BossAI me->SetUnitFlag(UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE | UNIT_FLAG_DISABLE_MOVE); Talk(SAY_INTRO); DoCastAOE(SPELL_REMOVE_ENCHANTED_WEAPONS, true); - ScheduleUniqueTimedEvent(23s, [&] + ScheduleUniqueTimedEvent(21s, [&] { - Talk(SAY_INTRO_THALADRED); + IntroduceNewAdvisor(SAY_INTRO_THALADRED, ACTION_START_THALADRED); }, EVENT_PREFIGHT_PHASE1_01); - ScheduleUniqueTimedEvent(30s, [&] - { - if (Creature* thaladred = summons.GetCreatureWithEntry(NPC_THALADRED)) - { - thaladred->SetReactState(REACT_AGGRESSIVE); - thaladred->RemoveUnitFlag(UNIT_FLAG_NON_ATTACKABLE); - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - thaladred->AI()->AttackStart(target); - thaladred->SetInCombatWithZone(); - } - }, EVENT_PREFIGHT_PHASE1_02); } } @@ -337,70 +304,35 @@ struct boss_kaelthas : public BossAI summon->SetReactState(REACT_PASSIVE); } - void DoAction(int32 action) override + void SpellHit(Unit* caster, SpellInfo const* spell) override { - switch (action) + if (_phase == PHASE_SINGLE_ADVISOR && spell->Id == SPELL_KAEL_PHASE_TWO) { - case ACTION_START_SANGUINAR: - IntroduceNewAdvisor(SAY_INTRO_SANGUINAR, ACTION_START_SANGUINAR); - break; - case ACTION_START_CAPERNIAN: - IntroduceNewAdvisor(SAY_INTRO_CAPERNIAN, ACTION_START_CAPERNIAN); - break; - case ACTION_START_TELONICUS: - IntroduceNewAdvisor(SAY_INTRO_TELONICUS, ACTION_START_TELONICUS); - break; - case ACTION_START_WEAPONS: - ScheduleUniqueTimedEvent(3s, [&]{ - Talk(SAY_PHASE2_WEAPON); - DoCastSelf(SPELL_SUMMON_WEAPONS); - _phase = PHASE_WEAPONS; - }, EVENT_PREFIGHT_PHASE5_01); - ScheduleUniqueTimedEvent(9s, [&]{ - summons.DoForAllSummons([&](WorldObject* summon) - { - if (Creature* summonedCreature = summon->ToCreature()) - { - if (!summonedCreature->GetSpawnId()) - { - summonedCreature->SetReactState(REACT_AGGRESSIVE); - summonedCreature->SetInCombatWithZone(); - if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) - { - summonedCreature->AI()->AttackStart(target); - } - } - } - }); - scheduler.Schedule(90s, GROUP_PROGRESS_PHASE, [this](TaskContext) - { - PhaseAllAdvisorsExecute(); - }); - }, EVENT_PREFIGHT_PHASE5_02); - break; - case ACTION_PROGRESS_PHASE_CHECK: - if (_phase == PHASE_ALL_ADVISORS) - { - bool advisorAlive = false; - summons.DoForAllSummons([&advisorAlive](WorldObject* summon) - { - if (Creature* summonedCreature = summon->ToCreature()) - { - if (summonedCreature->IsAlive()) - { - if (summonedCreature->GetEntry() >= NPC_LORD_SANGUINAR && summonedCreature->GetEntry() <= NPC_THALADRED) - { - advisorAlive = true; - return; - } - } - } - }); - if (!advisorAlive) - PhaseKaelExecute(); - } - default: - break; + switch (caster->GetEntry()) + { + case NPC_THALADRED: + IntroduceNewAdvisor(SAY_INTRO_SANGUINAR, ACTION_START_SANGUINAR); + break; + case NPC_LORD_SANGUINAR: + IntroduceNewAdvisor(SAY_INTRO_CAPERNIAN, ACTION_START_CAPERNIAN); + break; + case NPC_CAPERNIAN: + IntroduceNewAdvisor(SAY_INTRO_TELONICUS, ACTION_START_TELONICUS); + break; + case NPC_TELONICUS: + PhaseEnchantedWeaponsExecute(); + break; + default: + break; + } + } + else if (_phase == PHASE_ALL_ADVISORS && spell->Id == SPELL_KAEL_PHASE_TWO) + { + --_advisorsAlive; + if (_advisorsAlive == 0) + { + PhaseKaelExecute(); + } } } @@ -626,6 +558,10 @@ struct boss_kaelthas : public BossAI //switch because talk times are different switch (kaelAction) { + case ACTION_START_THALADRED: + attackStartTimer = 7000ms; + advisorNPCId = NPC_THALADRED; + break; case ACTION_START_SANGUINAR: attackStartTimer = 14500ms; advisorNPCId = NPC_LORD_SANGUINAR; @@ -650,28 +586,26 @@ struct boss_kaelthas : public BossAI if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) advisor->AI()->AttackStart(target); advisor->SetInCombatWithZone(); + advisor->AI()->Talk(SAY_ADVISOR_AGGRO); } }); } - void PhaseAllAdvisorsExecute() + void PhaseEnchantedWeaponsExecute() { - _phase = PHASE_TRANSITION; - scheduler.CancelGroup(GROUP_PROGRESS_PHASE); - Talk(SAY_PHASE3_ADVANCE); - ScheduleUniqueTimedEvent(6s, [&]{ - DoCastSelf(SPELL_RESURRECTION); - }, EVENT_PREFIGHT_PHASE6_02); - ScheduleUniqueTimedEvent(12s, [&]{ - _phase = PHASE_ALL_ADVISORS; + ScheduleUniqueTimedEvent(3s, [&]{ + Talk(SAY_PHASE2_WEAPON); + DoCastSelf(SPELL_SUMMON_WEAPONS); + _phase = PHASE_WEAPONS; + }, EVENT_PREFIGHT_PHASE5_01); + ScheduleUniqueTimedEvent(9s, [&]{ summons.DoForAllSummons([&](WorldObject* summon) { if (Creature* summonedCreature = summon->ToCreature()) { - if (summonedCreature->GetSpawnId()) + if (!summonedCreature->GetSpawnId()) { summonedCreature->SetReactState(REACT_AGGRESSIVE); - summonedCreature->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); summonedCreature->SetInCombatWithZone(); if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) { @@ -682,9 +616,24 @@ struct boss_kaelthas : public BossAI }); scheduler.Schedule(3min, GROUP_PROGRESS_PHASE, [this](TaskContext) { - PhaseKaelExecute(); + PhaseAllAdvisorsExecute(); }); - }, EVENT_PREFIGHT_PHASE6_03); + }, EVENT_PREFIGHT_PHASE5_02); + } + + void PhaseAllAdvisorsExecute() + { + _phase = PHASE_TRANSITION; + scheduler.CancelGroup(GROUP_PROGRESS_PHASE); + Talk(SAY_PHASE3_ADVANCE); + ScheduleUniqueTimedEvent(6s, [&]{ + DoCastSelf(SPELL_RESURRECTION); + _phase = PHASE_ALL_ADVISORS; + }, EVENT_PREFIGHT_PHASE6_02); + scheduler.Schedule(192s, GROUP_PROGRESS_PHASE, [this](TaskContext) + { + PhaseKaelExecute(); + }); } void PhaseKaelExecute() @@ -769,58 +718,89 @@ struct boss_kaelthas : public BossAI } private: uint32 _phase; + uint8 _advisorsAlive; bool _transitionSceneReached = false; }; -struct npc_lord_sanguinar : public ScriptedAI + +struct advisor_baseAI : public ScriptedAI + { - npc_lord_sanguinar(Creature* creature) : ScriptedAI(creature) { - _instance = creature->GetInstanceScript(); + advisor_baseAI(Creature* creature) : ScriptedAI(creature) { scheduler.SetValidator([this] { return !me->HasUnitState(UNIT_STATE_CASTING); }); } + virtual void ScheduleEvents() {} + void Reset() override { + _preventDeath = true; + _feigning = false; + me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); scheduler.CancelAll(); - _hasDied = false; - me->SetReactState(REACT_PASSIVE); } - void JustEngagedWith(Unit* /*who*/) override + void JustEngagedWith(Unit* /*who*/) override { ScheduleEvents(); } + + void DamageTaken(Unit* /*attacker*/, uint32& damage, DamageEffectType /*damageEffectType*/, SpellSchoolMask /*spellSchoolMask*/) override { - if (!_hasDied) + if (!_preventDeath) + return; + if (damage >= me->GetHealth()) { - Talk(SAY_SANGUINAR_AGGRO); + damage = me->GetHealth() - 1; // prevent death + if (_feigning) + return; + scheduler.CancelAll(); + me->AttackStop(); + me->SetUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + DoCastAOE(SPELL_KAEL_PHASE_TWO, true); + DoCastSelf(SPELL_PERMANENT_FEIGN_DEATH, true); + _feigning = true; } - ScheduleTimedEvent(0s, 2s, [&]{ - DoCastSelf(SPELL_BELLOWING_ROAR); - }, 30s, 40s); - } + } - void JustDied(Unit* /*killer*/) override + void SpellHit(Unit* caster, SpellInfo const* spell) override { - if (Creature* kael = _instance->GetCreature(DATA_KAELTHAS)) + if (spell->Id == SPELL_RESURRECTION && caster->GetEntry() == NPC_KAELTHAS) { - kael->AI()->DoAction(ACTION_PROGRESS_PHASE_CHECK); - if (!_hasDied) + me->RemoveAurasDueToSpell(SPELL_PERMANENT_FEIGN_DEATH); + me->SetStandState(UNIT_STAND_STATE_STAND); + scheduler.Schedule(6s, [&](TaskContext /*context*/) { - Talk(SAY_SANGUINAR_DEATH); - DoCastSelf(SPELL_KAEL_PHASE_TWO, true); - kael->AI()->DoAction(ACTION_START_CAPERNIAN); - _hasDied = true; - } + _preventDeath = false; + _feigning = false; + me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); + DoResetThreatList(); + me->SetInCombatWithZone(); + me->SetReactState(REACT_AGGRESSIVE); + if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0)) + { + AttackStart(target); + } + ScheduleEvents(); + }); } + } + + void JustDied(Unit* /*killer*/) override + { + Talk(SAY_ADVISOR_DEATH); scheduler.CancelAll(); + DoCastAOE(SPELL_KAEL_PHASE_TWO, true); } void UpdateAI(uint32 diff) override { - if (!UpdateVictim()) + scheduler.Update(diff); + + if (_feigning) return; - scheduler.Update(diff); + if (!UpdateVictim()) + return; if (me->HasUnitState(UNIT_STATE_CASTING)) return; @@ -828,26 +808,20 @@ struct npc_lord_sanguinar : public ScriptedAI DoMeleeAttackIfReady(); } private: - InstanceScript* _instance; - bool _hasDied; + bool _preventDeath; + bool _feigning; }; -struct npc_capernian : public ScriptedAI +struct npc_lord_sanguinar : public advisor_baseAI { - npc_capernian(Creature* creature) : ScriptedAI(creature) { - _instance = creature->GetInstanceScript(); - scheduler.SetValidator([this] - { - return !me->HasUnitState(UNIT_STATE_CASTING); - }); - } + npc_lord_sanguinar(Creature* creature) : advisor_baseAI(creature) { }; - void Reset() override - { - scheduler.CancelAll(); - _hasDied = false; - me->SetReactState(REACT_PASSIVE); - } + void ScheduleEvents() override {} +}; + +struct npc_capernian : public advisor_baseAI +{ + npc_capernian(Creature* creature) : advisor_baseAI(creature) { } void AttackStart(Unit* who) override { @@ -861,14 +835,10 @@ struct npc_capernian : public ScriptedAI } } - void JustEngagedWith(Unit* /*who*/) override + void ScheduleEvents() override { - if (!_hasDied) + ScheduleTimedEvent(0ms, [&] { - Talk(SAY_CAPERNIAN_AGGRO); - } - ScheduleTimedEvent(0ms, [&]{ - if (!me->CanCastSpell(SPELL_CAPERNIAN_FIREBALL)) { me->ResumeChasingVictim(); @@ -878,7 +848,6 @@ struct npc_capernian : public ScriptedAI me->GetMotionMaster()->MoveChase(me->GetVictim(), 30.0f); DoCastVictim(SPELL_CAPERNIAN_FIREBALL); } - }, 2500ms); ScheduleTimedEvent(7000ms, 10000ms, [&]{ DoCastRandomTarget(SPELL_CONFLAGRATION, 0, 30.0f); @@ -887,63 +856,14 @@ struct npc_capernian : public ScriptedAI DoCastRandomTarget(SPELL_ARCANE_BURST, 0, 8.0f); }, 6s); } - - void JustDied(Unit* /*killer*/) override - { - if (Creature* kael = _instance->GetCreature(DATA_KAELTHAS)) - { - kael->AI()->DoAction(ACTION_PROGRESS_PHASE_CHECK); - if (!_hasDied) - { - Talk(SAY_CAPERNIAN_DEATH); - DoCastSelf(SPELL_KAEL_PHASE_TWO, true); - kael->AI()->DoAction(ACTION_START_TELONICUS); - _hasDied = true; - } - } - scheduler.CancelAll(); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - scheduler.Update(diff); - - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - DoMeleeAttackIfReady(); - } -private: - InstanceScript* _instance; - bool _hasDied; }; -struct npc_telonicus : public ScriptedAI +struct npc_telonicus : public advisor_baseAI { - npc_telonicus(Creature* creature) : ScriptedAI(creature) { - _instance = creature->GetInstanceScript(); - scheduler.SetValidator([this] - { - return !me->HasUnitState(UNIT_STATE_CASTING); - }); - } + npc_telonicus(Creature* creature) : advisor_baseAI(creature) { } - void Reset() override - { - scheduler.CancelAll(); - _hasDied = false; - me->SetReactState(REACT_PASSIVE); - } - - void JustEngagedWith(Unit* /*who*/) override + void ScheduleEvents() override { - if (!_hasDied) - { - Talk(SAY_TELONICUS_AGGRO); - } ScheduleTimedEvent(0ms, [&]{ DoCastVictim(SPELL_BOMB); }, 3600ms, 7100ms); @@ -951,63 +871,14 @@ struct npc_telonicus : public ScriptedAI DoCastRandomTarget(SPELL_REMOTE_TOY, 0, 100.0f); }, 15750ms); } - - void JustDied(Unit* /*killer*/) override - { - if (Creature* kael = _instance->GetCreature(DATA_KAELTHAS)) - { - kael->AI()->DoAction(ACTION_PROGRESS_PHASE_CHECK); - if (!_hasDied) - { - Talk(SAY_TELONICUS_DEATH); - DoCastSelf(SPELL_KAEL_PHASE_TWO, true); - kael->AI()->DoAction(ACTION_START_WEAPONS); - _hasDied = true; - } - } - scheduler.CancelAll(); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - scheduler.Update(diff); - - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - DoMeleeAttackIfReady(); - } -private: - InstanceScript* _instance; - bool _hasDied; }; -struct npc_thaladred : public ScriptedAI +struct npc_thaladred : public advisor_baseAI { - npc_thaladred(Creature* creature) : ScriptedAI(creature) { - _instance = creature->GetInstanceScript(); - scheduler.SetValidator([this] - { - return !me->HasUnitState(UNIT_STATE_CASTING); - }); - } - - void Reset() override - { - scheduler.CancelAll(); - me->SetReactState(REACT_PASSIVE); - _hasDied = false; - } + npc_thaladred(Creature* creature) : advisor_baseAI(creature) { } - void JustEngagedWith(Unit* /*who*/) override + void ScheduleEvents() override { - if (!_hasDied) - { - Talk(SAY_THALADRED_AGGRO); - } ScheduleTimedEvent(100ms, [&] { DoResetThreatList(); @@ -1036,56 +907,6 @@ struct npc_thaladred : public ScriptedAI } }, 3600ms, 15200ms); } - - void JustDied(Unit* /*killer*/) override - { - if (Creature* kael = _instance->GetCreature(DATA_KAELTHAS)) - { - kael->AI()->DoAction(ACTION_PROGRESS_PHASE_CHECK); - if (!_hasDied) - { - Talk(SAY_THALADRED_DEATH); - DoCastSelf(SPELL_KAEL_PHASE_TWO, true); - kael->AI()->DoAction(ACTION_START_SANGUINAR); - _hasDied = true; - } - } - scheduler.CancelAll(); - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim()) - return; - - scheduler.Update(diff); - - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; - - DoMeleeAttackIfReady(); - } -private: - InstanceScript* _instance; - bool _hasDied; -}; - -class spell_kaelthas_kael_phase_two : public SpellScript -{ - PrepareSpellScript(spell_kaelthas_kael_phase_two); - - bool Load() override - { - if (GetCaster()->IsCreature()) - if (InstanceScript* instance = GetCaster()->GetInstanceScript()) - if (Creature* kael = instance->GetCreature(DATA_KAELTHAS)) - kael->AI()->SummonedCreatureDies(GetCaster()->ToCreature(), nullptr); - return true; - } - - void Register() override - { - } }; class spell_kaelthas_remote_toy : public AuraScript @@ -1122,21 +943,6 @@ class spell_kaelthas_summon_weapons : public SpellScript } }; -class spell_kaelthas_resurrection : public SpellScript -{ - PrepareSpellScript(spell_kaelthas_resurrection); - - void HandleBeforeCast() - { - GetCaster()->GetAI()->SetData(DATA_RESURRECT_CAST, DATA_RESURRECT_CAST); - } - - void Register() override - { - BeforeCast += SpellCastFn(spell_kaelthas_resurrection::HandleBeforeCast); - } -}; - class spell_kaelthas_mind_control : public SpellScript { PrepareSpellScript(spell_kaelthas_mind_control); @@ -1380,10 +1186,8 @@ void AddSC_boss_kaelthas() RegisterTheEyeAI(npc_capernian); RegisterTheEyeAI(npc_telonicus); RegisterTheEyeAI(npc_thaladred); - RegisterSpellScript(spell_kaelthas_kael_phase_two); RegisterSpellScript(spell_kaelthas_remote_toy); RegisterSpellScript(spell_kaelthas_summon_weapons); - RegisterSpellScript(spell_kaelthas_resurrection); RegisterSpellScript(spell_kaelthas_mind_control); RegisterSpellScript(spell_kaelthas_burn); RegisterSpellScript(spell_kaelthas_flame_strike); From f22c06b84d84969f6dbe6c9e3f1af2e1381a75a4 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 14 Nov 2024 09:07:37 +0000 Subject: [PATCH 081/105] chore(DB): import pending files Referenced commit(s): 980b9246c8f207135feeed45e6a2a92ccea2a5e9 --- .../rev_1726878416572918109.sql => db_world/2024_11_14_02.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1726878416572918109.sql => db_world/2024_11_14_02.sql} (91%) diff --git a/data/sql/updates/pending_db_world/rev_1726878416572918109.sql b/data/sql/updates/db_world/2024_11_14_02.sql similarity index 91% rename from data/sql/updates/pending_db_world/rev_1726878416572918109.sql rename to data/sql/updates/db_world/2024_11_14_02.sql index db88fba2dea441..2f27ca668ee8b0 100644 --- a/data/sql/updates/pending_db_world/rev_1726878416572918109.sql +++ b/data/sql/updates/db_world/2024_11_14_02.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_14_01 -> 2024_11_14_02 -- DELETE FROM `spell_script_names` WHERE `spell_id`=36450 AND `ScriptName`='spell_kaelthas_resurrection'; DELETE FROM `spell_script_names` WHERE `spell_id`=36709 AND `ScriptName`='spell_kaelthas_kael_phase_two'; From 002ed25d498f7b5c14391c112d8c562e6a6a6e5f Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 12:24:40 -0300 Subject: [PATCH 082/105] fix(DB/SAI): Correct Dawnblade Summoner timers and combat movement (#20562) --- .../sql/updates/pending_db_world/rev_1731595481697504000.sql | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731595481697504000.sql diff --git a/data/sql/updates/pending_db_world/rev_1731595481697504000.sql b/data/sql/updates/pending_db_world/rev_1731595481697504000.sql new file mode 100644 index 00000000000000..251a921bd5c40e --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731595481697504000.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 24978) AND (`source_type` = 0) AND (`id` IN (3, 4)); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(24978, 0, 3, 0, 0, 0, 100, 0, 1000, 1000, 2000, 2000, 0, 0, 11, 32707, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Dawnblade Summoner - In Combat - Cast \'Incinerate\''), +(24978, 0, 4, 0, 0, 0, 100, 0, 4000, 6000, 4000, 6000, 0, 0, 11, 11962, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 'Dawnblade Summoner - In Combat - Cast \'Immolate\''); From 65d2ca31cf8c2fa96304487ce70042963ac4de93 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 14 Nov 2024 15:25:38 +0000 Subject: [PATCH 083/105] chore(DB): import pending files Referenced commit(s): 002ed25d498f7b5c14391c112d8c562e6a6a6e5f --- .../rev_1731595481697504000.sql => db_world/2024_11_14_03.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731595481697504000.sql => db_world/2024_11_14_03.sql} (95%) diff --git a/data/sql/updates/pending_db_world/rev_1731595481697504000.sql b/data/sql/updates/db_world/2024_11_14_03.sql similarity index 95% rename from data/sql/updates/pending_db_world/rev_1731595481697504000.sql rename to data/sql/updates/db_world/2024_11_14_03.sql index 251a921bd5c40e..b3e8081f10fa0e 100644 --- a/data/sql/updates/pending_db_world/rev_1731595481697504000.sql +++ b/data/sql/updates/db_world/2024_11_14_03.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_14_02 -> 2024_11_14_03 -- DELETE FROM `smart_scripts` WHERE (`entryorguid` = 24978) AND (`source_type` = 0) AND (`id` IN (3, 4)); 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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES From 5252e6cf5b155d058c3f3556d276e373d28e4c45 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 16:03:35 -0300 Subject: [PATCH 084/105] =?UTF-8?q?fix(Scripts/Spells):=20Spell=20school?= =?UTF-8?q?=20reflectors=20should=20have=20failure=20chan=E2=80=A6=20(#205?= =?UTF-8?q?60)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix(Scripts/Spells): Spell school reflectors should have failure chance at higher levels --- .../rev_1731586109166584600.sql | 6 +++++ src/server/scripts/Spells/spell_item.cpp | 22 +++++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731586109166584600.sql diff --git a/data/sql/updates/pending_db_world/rev_1731586109166584600.sql b/data/sql/updates/pending_db_world/rev_1731586109166584600.sql new file mode 100644 index 00000000000000..f2d832a095f46c --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731586109166584600.sql @@ -0,0 +1,6 @@ +-- +DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_item_spell_reflectors'; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(23132, 'spell_item_spell_reflectors'), +(23097, 'spell_item_spell_reflectors'), +(23131, 'spell_item_spell_reflectors'); diff --git a/src/server/scripts/Spells/spell_item.cpp b/src/server/scripts/Spells/spell_item.cpp index 90d8ceb03879e9..1d033aeee39e06 100644 --- a/src/server/scripts/Spells/spell_item.cpp +++ b/src/server/scripts/Spells/spell_item.cpp @@ -4141,6 +4141,27 @@ class spell_item_luffa : public SpellScript } }; +// 23097 - Fire Reflector +// 23131 - Frost Reflector +// 23132 - Shadow Reflector +class spell_item_spell_reflectors: public AuraScript +{ + PrepareAuraScript(spell_item_spell_reflectors); + + void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/) + { + if (GetCaster()->GetLevel() > 70) + amount = 4; + else if (GetCaster()->GetLevel() > 60) + amount = 50; + } + + void Register() override + { + DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_item_spell_reflectors::CalculateAmount, EFFECT_0, SPELL_AURA_REFLECT_SPELLS_SCHOOL); + } +}; + void AddSC_item_spell_scripts() { RegisterSpellScript(spell_item_massive_seaforium_charge); @@ -4267,4 +4288,5 @@ void AddSC_item_spell_scripts() RegisterSpellScript(spell_item_gor_dreks_ointment); RegisterSpellScript(spell_item_skyguard_blasting_charges); RegisterSpellScript(spell_item_luffa); + RegisterSpellScript(spell_item_spell_reflectors); } From e1766eb87f96b3b7b7c252d2687b87f05b23349d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 14 Nov 2024 19:04:30 +0000 Subject: [PATCH 085/105] chore(DB): import pending files Referenced commit(s): 5252e6cf5b155d058c3f3556d276e373d28e4c45 --- .../rev_1731586109166584600.sql => db_world/2024_11_14_04.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731586109166584600.sql => db_world/2024_11_14_04.sql} (86%) diff --git a/data/sql/updates/pending_db_world/rev_1731586109166584600.sql b/data/sql/updates/db_world/2024_11_14_04.sql similarity index 86% rename from data/sql/updates/pending_db_world/rev_1731586109166584600.sql rename to data/sql/updates/db_world/2024_11_14_04.sql index f2d832a095f46c..20afbde44ad4da 100644 --- a/data/sql/updates/pending_db_world/rev_1731586109166584600.sql +++ b/data/sql/updates/db_world/2024_11_14_04.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_14_03 -> 2024_11_14_04 -- DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_item_spell_reflectors'; INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES From 53cd41b938ebb6621d45734b37a7a18c853368c7 Mon Sep 17 00:00:00 2001 From: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> Date: Thu, 14 Nov 2024 15:14:28 -0500 Subject: [PATCH 086/105] feat(Core/Scripting): Add hook during command security evaluation. (#20564) --- src/server/game/Chat/ChatCommands/ChatCommand.cpp | 3 +++ .../game/Scripting/ScriptDefines/AllCommandScript.cpp | 6 ++++++ src/server/game/Scripting/ScriptDefines/AllCommandScript.h | 4 ++++ src/server/game/Scripting/ScriptMgr.h | 2 ++ 4 files changed, 15 insertions(+) diff --git a/src/server/game/Chat/ChatCommands/ChatCommand.cpp b/src/server/game/Chat/ChatCommands/ChatCommand.cpp index 93bcd25f408242..c15e4d9a8e6ed2 100644 --- a/src/server/game/Chat/ChatCommands/ChatCommand.cpp +++ b/src/server/game/Chat/ChatCommands/ChatCommand.cpp @@ -506,6 +506,9 @@ bool Acore::Impl::ChatCommands::ChatCommandNode::IsInvokerVisible(ChatHandler co if (!_invoker) return false; + if (!sScriptMgr->OnBeforeIsInvokerVisible(_name, _permission, who)) + return true; + if (who.IsConsole() && (_permission.AllowConsole == Acore::ChatCommands::Console::No)) return false; diff --git a/src/server/game/Scripting/ScriptDefines/AllCommandScript.cpp b/src/server/game/Scripting/ScriptDefines/AllCommandScript.cpp index 59b1395f5af97a..cf01d409191317 100644 --- a/src/server/game/Scripting/ScriptDefines/AllCommandScript.cpp +++ b/src/server/game/Scripting/ScriptDefines/AllCommandScript.cpp @@ -16,6 +16,7 @@ */ #include "AllCommandScript.h" +#include "ChatCommand.h" #include "ScriptMgr.h" #include "ScriptMgrMacros.h" @@ -29,6 +30,11 @@ bool ScriptMgr::OnTryExecuteCommand(ChatHandler& handler, std::string_view cmdSt CALL_ENABLED_BOOLEAN_HOOKS(AllCommandScript, ALLCOMMANDHOOK_ON_TRY_EXECUTE_COMMAND, !script->OnTryExecuteCommand(handler, cmdStr)); } +bool ScriptMgr::OnBeforeIsInvokerVisible(std::string name, Acore::Impl::ChatCommands::CommandPermissions permissions, ChatHandler const& who) +{ + CALL_ENABLED_BOOLEAN_HOOKS(AllCommandScript, ALLCOMMANDHOOK_ON_BEFORE_IS_INVOKER_VISIBLE, !script->OnBeforeIsInvokerVisible(name, permissions, who)); +} + AllCommandScript::AllCommandScript(const char* name, std::vector enabledHooks) : ScriptObject(name, ALLCOMMANDHOOK_END) { diff --git a/src/server/game/Scripting/ScriptDefines/AllCommandScript.h b/src/server/game/Scripting/ScriptDefines/AllCommandScript.h index 75002811536f32..e56615b1521b6f 100644 --- a/src/server/game/Scripting/ScriptDefines/AllCommandScript.h +++ b/src/server/game/Scripting/ScriptDefines/AllCommandScript.h @@ -19,12 +19,14 @@ #define SCRIPT_OBJECT_ALL_COMMAND_SCRIPT_H_ #include "ScriptObject.h" +#include "ChatCommand.h" #include enum AllCommandHook { ALLCOMMANDHOOK_ON_HANDLE_DEV_COMMAND, ALLCOMMANDHOOK_ON_TRY_EXECUTE_COMMAND, + ALLCOMMANDHOOK_ON_BEFORE_IS_INVOKER_VISIBLE, ALLCOMMANDHOOK_END }; @@ -45,6 +47,8 @@ class AllCommandScript : public ScriptObject * @param cmdStr Contains information about the command name */ [[nodiscard]] virtual bool OnTryExecuteCommand(ChatHandler& /*handler*/, std::string_view /*cmdStr*/) { return true; } + + [[nodiscard]] virtual bool OnBeforeIsInvokerVisible(std::string /*name*/, Acore::Impl::ChatCommands::CommandPermissions /*permissions*/, ChatHandler const& /*who*/) { return true; } }; // Compatibility for old scripts diff --git a/src/server/game/Scripting/ScriptMgr.h b/src/server/game/Scripting/ScriptMgr.h index 7d074dbf7804cb..1825319bbcfbc7 100644 --- a/src/server/game/Scripting/ScriptMgr.h +++ b/src/server/game/Scripting/ScriptMgr.h @@ -22,6 +22,7 @@ #include "ArenaTeam.h" #include "AuctionHouseMgr.h" #include "Battleground.h" +#include "ChatCommand.h" #include "Common.h" #include "DBCStores.h" #include "DynamicObject.h" @@ -672,6 +673,7 @@ class ScriptMgr void OnHandleDevCommand(Player* player, bool& enable); bool OnTryExecuteCommand(ChatHandler& handler, std::string_view cmdStr); + bool OnBeforeIsInvokerVisible(std::string name, Acore::Impl::ChatCommands::CommandPermissions permissions, ChatHandler const& who); public: /* DatabaseScript */ From 2c40c299a7b37456fc33af934f61038a00853608 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 18:31:03 -0300 Subject: [PATCH 087/105] fix(Scripts/ZulAman): Despawn Harisson Jones after he "dies" (#20565) --- src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp index 594d5fcebee3e9..08371312a78055 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp @@ -411,6 +411,7 @@ struct npc_harrison_jones : public ScriptedAI me->SetDynamicFlag(UNIT_DYNFLAG_DEAD); _instance->StorePersistentData(DATA_TIMED_RUN, 21); _instance->DoAction(ACTION_START_TIMED_RUN); + me->DespawnOrUnsummon(3min+30s, 0s); } } From 8e45014adafae1619f346216f57be71157abf365 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Thu, 14 Nov 2024 19:05:24 -0300 Subject: [PATCH 088/105] fix(DB/SAI): Remove SAI to set unselectable flag from Sunblade Protectors (#20563) fix(DB/SAI): Remove SAI to set unselectable flag from Sunwell Protectors --- data/sql/updates/pending_db_world/rev_1731611937411826300.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731611937411826300.sql diff --git a/data/sql/updates/pending_db_world/rev_1731611937411826300.sql b/data/sql/updates/pending_db_world/rev_1731611937411826300.sql new file mode 100644 index 00000000000000..80f331c1b06e23 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731611937411826300.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `smart_scripts` WHERE `entryorguid` IN +(-45537,-45570,-45571,-48394,-48400,-54994,-54996,-54999,-55062,-55064,-55065) +AND `event_type` = 61 AND `action_type` IN (18, 19); From a9267653801eecf0e46c501effa5fec7519d7012 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 14 Nov 2024 22:06:18 +0000 Subject: [PATCH 089/105] chore(DB): import pending files Referenced commit(s): 8e45014adafae1619f346216f57be71157abf365 --- .../rev_1731611937411826300.sql => db_world/2024_11_14_05.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1731611937411826300.sql => db_world/2024_11_14_05.sql} (80%) diff --git a/data/sql/updates/pending_db_world/rev_1731611937411826300.sql b/data/sql/updates/db_world/2024_11_14_05.sql similarity index 80% rename from data/sql/updates/pending_db_world/rev_1731611937411826300.sql rename to data/sql/updates/db_world/2024_11_14_05.sql index 80f331c1b06e23..0e28c0a97a7782 100644 --- a/data/sql/updates/pending_db_world/rev_1731611937411826300.sql +++ b/data/sql/updates/db_world/2024_11_14_05.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_14_04 -> 2024_11_14_05 -- DELETE FROM `smart_scripts` WHERE `entryorguid` IN (-45537,-45570,-45571,-48394,-48400,-54994,-54996,-54999,-55062,-55064,-55065) From 6fd034c8b3038a967e17136ece47df13009e1d68 Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Fri, 15 Nov 2024 02:25:13 +0100 Subject: [PATCH 090/105] fixup(Scripts/TheEye): spawn Kaelthas' advisors with full hp (#20573) --- src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp index 745bc2c95b883a..1971d6f0cf7922 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp @@ -768,6 +768,7 @@ struct advisor_baseAI : public ScriptedAI { me->RemoveAurasDueToSpell(SPELL_PERMANENT_FEIGN_DEATH); me->SetStandState(UNIT_STAND_STATE_STAND); + me->SetFullHealth(); scheduler.Schedule(6s, [&](TaskContext /*context*/) { _preventDeath = false; From 9f5821638338ad7f2b3e94ff543cc520712986e4 Mon Sep 17 00:00:00 2001 From: Jelle Meeus Date: Fri, 15 Nov 2024 07:47:41 +0100 Subject: [PATCH 091/105] fix(Core/Spell): EffectQuestComplete, set quest to rewarded instead of complete (#20358) set quest to rewarded instead of complete when targetted by SPELL_EFFECT_QUEST_COMPLETE Prevents people from ending up with strange quests in their quest logs. https://github.com/TrinityCore/TrinityCore/commit/6d62f852acf3e1a3ee57cde2442832280aee814 Co-authored-by: SnapperRy --- src/server/game/Entities/Player/Player.h | 1 + src/server/game/Entities/Player/PlayerQuest.cpp | 9 +++++++-- src/server/game/Spells/SpellEffects.cpp | 4 ++-- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/server/game/Entities/Player/Player.h b/src/server/game/Entities/Player/Player.h index b00468be5bd220..778ae0a83940da 100644 --- a/src/server/game/Entities/Player/Player.h +++ b/src/server/game/Entities/Player/Player.h @@ -1433,6 +1433,7 @@ class Player : public Unit, public GridObject void CompleteQuest(uint32 quest_id); void IncompleteQuest(uint32 quest_id); void RewardQuest(Quest const* quest, uint32 reward, Object* questGiver, bool announce = true, bool isLFGReward = false); + void SetRewardedQuest(uint32 quest_id); void FailQuest(uint32 quest_id); bool SatisfyQuestSkill(Quest const* qInfo, bool msg) const; bool SatisfyQuestLevel(Quest const* qInfo, bool msg) const; diff --git a/src/server/game/Entities/Player/PlayerQuest.cpp b/src/server/game/Entities/Player/PlayerQuest.cpp index b566d2d7630e39..ef2bbb9ed2c1e5 100644 --- a/src/server/game/Entities/Player/PlayerQuest.cpp +++ b/src/server/game/Entities/Player/PlayerQuest.cpp @@ -819,8 +819,7 @@ void Player::RewardQuest(Quest const* quest, uint32 reward, Object* questGiver, SetSeasonalQuestStatus(quest_id); RemoveActiveQuest(quest_id, false); - m_RewardedQuests.insert(quest_id); - m_RewardedQuestsSave[quest_id] = true; + SetRewardedQuest(quest_id); if (announce) SendQuestReward(quest, XP); @@ -877,6 +876,12 @@ void Player::RewardQuest(Quest const* quest, uint32 reward, Object* questGiver, sScriptMgr->OnPlayerCompleteQuest(this, quest); } +void Player::SetRewardedQuest(uint32 quest_id) +{ + m_RewardedQuests.insert(quest_id); + m_RewardedQuestsSave[quest_id] = true; +} + void Player::FailQuest(uint32 questId) { if (Quest const* quest = sObjectMgr->GetQuestTemplate(questId)) diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index 811dea160d4aaf..ace8a1b51ecf9b 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -4771,8 +4771,8 @@ void Spell::EffectQuestComplete(SpellEffIndex effIndex) uint16 logSlot = player->FindQuestSlot(questId); if (logSlot < MAX_QUEST_LOG_SIZE) player->AreaExploredOrEventHappens(questId); - else if (player->CanTakeQuest(quest, false)) // never rewarded before - player->CompleteQuest(questId); // quest not in log - for internal use + else if (player->CanTakeQuest(quest, false)) // Check if the quest has already been turned in. + player->SetRewardedQuest(questId); // If not, set status to rewarded without broadcasting it to client. } } From 5bbfd21e32eaa848eb78c48fb577e7fcb1794386 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Fri, 15 Nov 2024 04:38:48 -0300 Subject: [PATCH 092/105] fix(Scripts/ZulAman): Save Massive Gate state to DB (#20568) --- src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp index 08371312a78055..a583d1f6c7eb35 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp @@ -501,7 +501,10 @@ struct npc_harrison_jones : public ScriptedAI } if (GameObject* gate = _instance->GetGameObject(DATA_MASSIVE_GATE)) + { + gate->AllowSaveToDB(true); gate->SetGoState(GO_STATE_ACTIVE); + } _gongTimer = 2000; _gongEvent = GONG_EVENT_8; break; From a0a8b406aaae0710cc6f85bffbf05be9aa3e3418 Mon Sep 17 00:00:00 2001 From: daobashun <49193927+fangshun2004@users.noreply.github.com> Date: Fri, 15 Nov 2024 16:00:55 +0800 Subject: [PATCH 093/105] Fix(DB/SAI) Stonard talking to the NPCs in the refuge camp (#20301) * Swamp of Sorrows npc talk * Modify the note --- .../rev_1718404604171613900.sql | 186 ++++++++++++++++++ 1 file changed, 186 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1718404604171613900.sql diff --git a/data/sql/updates/pending_db_world/rev_1718404604171613900.sql b/data/sql/updates/pending_db_world/rev_1718404604171613900.sql new file mode 100644 index 00000000000000..b94d237a36a1d3 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1718404604171613900.sql @@ -0,0 +1,186 @@ +SET @entry := 17109; +SET @PATH := @entry * 10; +DELETE FROM `waypoints` WHERE `entry`= @PATH; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `orientation`, `delay`, `point_comment`) VALUES +(@PATH, 0+1, -10465.81, -3315.652, 21.13692, NULL, 0,'Cersei Dusksinger'), +(@PATH, 1+1, -10458.49, -3312.623, 21.13692, NULL, 0,'Cersei Dusksinger'), +(@PATH, 2+1, -10454.86, -3310.604, 21.27058, NULL, 0,'Cersei Dusksinger'), +(@PATH, 3+1, -10448.59, -3301.409, 20.17796, NULL, 0,'Cersei Dusksinger'), +(@PATH, 4+1, -10445.24, -3295.546, 20.17796, NULL, 0,'Cersei Dusksinger'), +(@PATH, 5+1, -10450, -3304.108, 20.17796, NULL, 0,'Cersei Dusksinger'), +(@PATH, 6+1, -10455.22, -3311.379, 21.13692, NULL, 0,'Cersei Dusksinger'), +(@PATH, 7+1, -10454.67, -3319.15, 21.17226, NULL, 0,'Cersei Dusksinger'), +(@PATH, 8+1, -10458.43, -3321.949, 21.13692, NULL, 0,'Cersei Dusksinger'), +(@PATH, 9+1, -10461.03, -3319.802, 21.13692, NULL, 0,'Cersei Dusksinger'); + +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 17109; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 17109); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(17109, 0, 0, 1, 25, 0, 100, 0, 0, 0, 0, 0, 0, 0, 11, 8722, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Reset - Cast \'Summon Succubus\''), +(17109, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Reset - Set Event Phase 1'), +(17109, 0, 2, 3, 1, 1, 100, 0, 0, 0, 260688, 260688, 0, 0, 22, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Out of Combat - Set Event Phase 2 (Phase 1)'), +(17109, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 87, 1710900, 1710900, 1710901, 1710901, 1710901, 1710901, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Out of Combat - Run Random Script (Phase 1)'), +(17109, 0, 4, 5, 40, 0, 100, 512, 5, 171090, 0, 0, 0, 0, 54, 8000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Point 5 of Path 171090 Reached - Pause Waypoint'), +(17109, 0, 5, 6, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 67, 1, 200, 200, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Point 5 of Path 171090 Reached - Create Timed Event'), +(17109, 0, 6, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 67, 2, 6450, 6450, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Point 5 of Path 171090 Reached - Create Timed Event'), +(17109, 0, 7, 0, 59, 0, 100, 0, 1, 0, 0, 0, 0, 0, 1, 4, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Timed Event 1 Triggered - Say Line 4'), +(17109, 0, 8, 0, 59, 0, 100, 0, 2, 0, 0, 0, 0, 0, 65, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Timed Event 2 Triggered - Resume Waypoint'), +(17109, 0, 9, 0, 58, 0, 100, 512, 0, 171090, 0, 0, 0, 0, 67, 3, 500, 500, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Path 171090 Finished - Create Timed Event'), +(17109, 0, 10, 11, 59, 0, 100, 0, 3, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0.907571, 'Cersei Dusksinger - On Timed Event 3 Triggered - Set Orientation 0.907571'), +(17109, 0, 11, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Timed Event 3 Triggered - Set Event Phase 1'), +(17109, 0, 12, 0, 38, 1, 100, 0, 0, 1, 0, 0, 0, 0, 22, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Data Set 0 1 - Set Event Phase 2 (Phase 1)'), +(17109, 0, 13, 0, 38, 2, 100, 0, 0, 2, 0, 0, 0, 0, 80, 1710902, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Data Set 0 2 - Run Script (Phase 2)'), +(17109, 0, 14, 0, 34, 0, 100, 0, 8, 1, 0, 0, 0, 0, 80, 1710903, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Reached Point 1 - Run Script'), +(17109, 0, 15, 0, 34, 0, 100, 0, 8, 2, 0, 0, 0, 0, 80, 1710904, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - On Reached Point 2 - Run Script'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1710900); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1710900, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 2.54818, 'Cersei Dusksinger - Actionlist - Set Orientation 2.54818'), +(1710900, 9, 1, 0, 0, 0, 100, 0, 1840, 1840, 0, 0, 0, 0, 1, 3, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Say Line 3'), +(1710900, 9, 2, 0, 0, 0, 100, 0, 7800, 7800, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 10, 94506, 27705, 0, 0, 0, 0, 0, 0, 'Creature Lorrin Foxfire (27705) with guid 94506 (fetching) - Talk 1 to invoker'), +(1710900, 9, 3, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 53, 0, 171090, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Start Waypoint Path 171090'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1710901); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1710901, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Say Line 0'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1710902); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1710902, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 22, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Set Event Phase 2'), +(1710902, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 59, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Set Run Off'), +(1710902, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 69, 1, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, -10469, -3332.55, 25.4708, 0, 'Cersei Dusksinger - Actionlist - Move To Position'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1710903); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1710903, 9, 3, 0, 0, 0, 100, 0, 7000, 7000, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Say Line 1'), +(1710903, 9, 4, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 1.23918, 'Cersei Dusksinger - Actionlist - Set Orientation 1.23918'), +(1710903, 9, 5, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 0, 0, 1, 2, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Say Line 2'), +(1710903, 9, 6, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 0, 0, 5, 14, 0, 0, 0, 0, 0, 10, 34151, 12807, 0, 0, 0, 0, 0, 0, 'Creature Greshka (12807) with guid 34151 (fetching): Play emote ONESHOT_RUDE(DNR) (14)'), +(1710903, 9, 7, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 5, 14, 0, 0, 0, 0, 0, 10, 32091, 988, 0, 0, 0, 0, 0, 0, 'Creature Kartosh (988) with guid 32091 (fetching): Play emote ONESHOT_RUDE(DNR) (14)'), +(1710903, 9, 8, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 5, 14, 0, 0, 0, 0, 0, 10, 31950, 1386, 0, 0, 0, 0, 0, 0, 'Creature Rogvar (1386) with guid 31950 (fetching): Play emote ONESHOT_RUDE(DNR) (14)'), +(1710903, 9, 9, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 69, 2, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, -10461.1, -3319.65, 20.9641, 0, 'Cersei Dusksinger - Actionlist - Move To Position'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1710904); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1710904, 9, 10, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Cersei Dusksinger - Actionlist - Set Event Phase 1'); + + +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 12807; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 12807); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(12807, 0, 0, 1, 1, 0, 100, 0, 60000, 60000, 270000, 570000, 0, 0, 45, 0, 1, 0, 0, 0, 0, 10, 34141, 17109, 0, 0, 0, 0, 0, 0, 'Creature Cersei Dusksinger (17109) with guid 34141 (fetching): Set creature data #0 to 1'), +(12807, 0, 1, 2, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 10, 34141, 17109, 0, 0, 0, 0, 0, 0, 'Self: Talk 0 to Creature Cersei Dusksinger (17109) with guid 34141 (fetching)'), +(12807, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 80, 1280700, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Greshka - Out of Combat - Run Script'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1280700); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1280700, 9, 0, 0, 0, 0, 100, 0, 8000, 8000, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 10, 32091, 988, 0, 0, 0, 0, 0, 0, 'Creature Kartosh (988) with guid 32091 (fetching): Talk 0 to invoker'), +(1280700, 9, 1, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 10, 31950, 1386, 0, 0, 0, 0, 0, 0, 'Creature Rogvar (1386) with guid 31950 (fetching): Talk 0 to invoker'), +(1280700, 9, 2, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 0, 0, 45, 0, 2, 0, 0, 0, 0, 10, 34141, 17109, 0, 0, 0, 0, 0, 0, 'Creature Cersei Dusksinger (17109) with guid 34141 (fetching): Set creature data #0 to 2'); + +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 27705; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 27705); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(27705, 0, 0, 1, 1, 0, 100, 0, 15000, 30000, 134878, 314350, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Lorrin Foxfire - Out of Combat - Say Line 0'), +(27705, 0, 1, 0, 61, 0, 100, 0, 0, 0, 0, 0, 0, 0, 67, 1, 3000, 3000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Lorrin Foxfire - Out of Combat - Create Timed Event'), +(27705, 0, 2, 0, 59, 0, 100, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 10, 31950, 1386, 0, 0, 0, 0, 0, 0, 'Lorrin Foxfire - On Timed Event 1 Triggered - Say Line 1'); + +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 17127; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 17127); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(17127, 0, 0, 0, 1, 0, 100, 0, 0, 169109, 169109, 241370, 0, 0, 88, 1712700, 1712703, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Every 169.109 - 241.37 seconds (0 - 169.109s initially) (OOC) - Self: Call random timed action list between range Anchorite Avuun #0 (1712700) and Anchorite Avuun #3 (1712703) (update always)'); + +DELETE FROM `smart_scripts` WHERE (`entryorguid` = 1712700) AND (`source_type` = 9) AND (`id` IN (0, 1, 2, 3)); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1712700, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Set Orientation Closest Creature \'Magtoor\''), +(1712700, 9, 1, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Say Line 0'), +(1712700, 9, 2, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 45, 0, 1, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Creature Magtoor (1776) with guid 34160 (fetching): Set creature data #0 to 1'), +(1712700, 9, 3, 0, 0, 0, 100, 0, 27410, 27410, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.92699, 'Anchorite Avuun - Actionlist - Set Orientation 3.92699'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1712701); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1712701, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Set Orientation Closest Creature \'Magtoor\''), +(1712701, 9, 1, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Say Line 1'), +(1712701, 9, 2, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 45, 0, 2, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Creature Magtoor (1776) with guid 34160 (fetching): Set creature data #0 to 2'), +(1712701, 9, 3, 0, 0, 0, 100, 0, 27410, 27410, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.92699, 'Anchorite Avuun - Actionlist - Set Orientation 3.92699'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1712702); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1712702, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Set Orientation Closest Creature \'Magtoor\''), +(1712702, 9, 1, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 1, 2, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Say Line 2'), +(1712702, 9, 2, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 45, 0, 3, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Creature Magtoor (1776) with guid 34160 (fetching): Set creature data #0 to 3'), +(1712702, 9, 3, 0, 0, 0, 100, 0, 27410, 27410, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.92699, 'Anchorite Avuun - Actionlist - Set Orientation 3.92699'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 1712703); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1712703, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Set Orientation Closest Creature \'Magtoor\''), +(1712703, 9, 1, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 1, 3, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Anchorite Avuun - Actionlist - Say Line 3'), +(1712703, 9, 2, 0, 0, 0, 100, 0, 3300, 3300, 0, 0, 0, 0, 45, 0, 4, 0, 0, 0, 0, 10, 34160, 1776, 0, 0, 0, 0, 0, 0, 'Creature Magtoor (1776) with guid 34160 (fetching): Set creature data #0 to 4'), +(1712703, 9, 3, 0, 0, 0, 100, 0, 27410, 27410, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.92699, 'Anchorite Avuun - Actionlist - Set Orientation 3.92699'); + +UPDATE `creature_template` SET `AIName` = 'SmartAI' WHERE `entry` = 1776; + +DELETE FROM `smart_scripts` WHERE (`source_type` = 0 AND `entryorguid` = 1776); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(1776, 0, 0, 0, 38, 0, 100, 0, 0, 1, 0, 0, 0, 0, 80, 177600, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Magtoor - On Data Set 0 1 - Run Script'), +(1776, 0, 1, 0, 38, 0, 100, 0, 0, 2, 0, 0, 0, 0, 80, 177601, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Magtoor - On Data Set 0 2 - Run Script'), +(1776, 0, 2, 0, 38, 0, 100, 0, 0, 3, 0, 0, 0, 0, 80, 177602, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Magtoor - On Data Set 0 3 - Run Script'), +(1776, 0, 3, 0, 38, 0, 100, 0, 0, 4, 0, 0, 0, 0, 80, 177603, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Magtoor - On Data Set 0 4 - Run Script'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 177600); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(177600, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Set Orientation Closest Creature \'Anchorite Avuun\''), +(177600, 9, 1, 0, 0, 0, 100, 0, 5590, 5590, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Say Line 0'), +(177600, 9, 2, 0, 0, 0, 100, 0, 14486, 14486, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.10669, 'Magtoor - Actionlist - Set Orientation 3.10669'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 177601); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(177601, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Set Orientation Closest Creature \'Anchorite Avuun\''), +(177601, 9, 1, 0, 0, 0, 100, 0, 5590, 5590, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Say Line 1'), +(177601, 9, 2, 0, 0, 0, 100, 0, 14486, 14486, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.10669, 'Magtoor - Actionlist - Set Orientation 3.10669'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 177602); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(177602, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Set Orientation Closest Creature \'Anchorite Avuun\''), +(177602, 9, 1, 0, 0, 0, 100, 0, 5590, 5590, 0, 0, 0, 0, 1, 2, 0, 1, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Say Line 2'), +(177602, 9, 2, 0, 0, 0, 100, 0, 14486, 14486, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.10669, 'Magtoor - Actionlist - Set Orientation 3.10669'); + +DELETE FROM `smart_scripts` WHERE (`source_type` = 9 AND `entryorguid` = 177603); +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`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(177603, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Set Orientation Closest Creature \'Anchorite Avuun\''), +(177603, 9, 1, 0, 0, 0, 100, 0, 5590, 5590, 0, 0, 0, 0, 1, 3, 0, 1, 0, 0, 0, 10, 32101, 17127, 0, 0, 0, 0, 0, 0, 'Magtoor - Actionlist - Say Line 3'), +(177603, 9, 2, 0, 0, 0, 100, 0, 14486, 14486, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 3.10669, 'Magtoor - Actionlist - Set Orientation 3.10669'); + +-- page_text_locale +DELETE FROM `page_text_locale` WHERE (`locale`='zhTW' AND `ID` IN (1958,1957,1956,1955,1954,1953,1952,1951,2038,2037,2036,2035,2034,2033,2032,2031,2030,2216,2215,2214,2213,2212,793,792,791,711)); +INSERT INTO `page_text_locale` (`ID`, `Text`, `locale`, `VerifiedBuild`) VALUES +(1958, '基爾加丹也意識到部落已經完全準備好了,獸人已經成為燃燒軍團手中最為強大的武器。他把這條消息告訴了他的主人,薩格拉斯也認為他復仇的時刻終於來臨了。', 'zhTW', 53788), +(1957, '幾個月之後,部落幾乎根除了德拉諾大陸上的所有德萊尼人,只有一小部分德萊尼人的倖存者苟延殘喘地躲避獸人那可怕的狂怒。因為勝利而得意的古爾丹整日沉迷於部落的力量和權力之中。然而,他清楚地知道,如果沒有可以殺戮的敵人,獸人部落就會因為自己無法控制的屠殺欲望在無休止的內戰中毀滅。', 'zhTW', 53788), +(1956, '然而,在考慮到某些大酋長比如葛羅·地獄吼和奧格林·末日錘可能會為了最高統帥的地位而互相爭執之後,古爾丹設立了一個傀儡大酋長來統治這個新的部落。『毀滅者』黑手,一個異常墮落和邪惡的督軍,被選中成為了古爾丹的傀儡。在黑手的指揮下,獸人部落開始以純樸的德萊尼人測試自己的戰鬥能力。', 'zhTW', 53788), +(1955, '獸人完全被這個嗜血的詛咒所吞沒,準備將怒氣發洩到任何阻擋他們的人身上。古爾丹覺得時機已經成熟了,就將互相征伐的各個氏族聯合成了一個統一的、無可阻擋的部落。', 'zhTW', 53788), +(1954, '除了杜洛坦之外,所有的氏族酋長都在葛羅·地獄吼的帶領下喝下了狂暴之血,就此將自己的命運徹底交給了惡魔,成為了燃燒軍團的奴隸。在瑪諾洛斯之血的引誘下,酋長們不自覺地將征服的欲望擴散到絕對信任他們的同胞之中。', 'zhTW', 53788), +(1953, '雖然基爾加丹知道獸人氏族已基本做好了準備,但他還是需要確認獸人對他的絕對忠誠。他通過暗影議會秘密召喚了破壞者瑪諾洛斯─一個充滿毀滅欲望的狂暴惡魔。同時古爾丹也將氏族酋長們召集到一起,並使他們確信自己在喝過瑪諾洛斯的狂暴之血後將變得所向無敵。', 'zhTW', 53788), +(1952, '其中霜狼氏族的酋長杜洛坦就告戒說,獸人已經迷失了自我而處於仇恨和狂暴之中。然而,他的警言卻沒有人聽取,一些強大氏族的酋長─例如戰歌氏族的葛羅·地獄吼─卻站出來迎接這個充滿戰爭和征服的新時代。', 'zhTW', 53788), +(1951, '在古爾丹和他的暗影議會的控制下,獸人們變得越來越具有侵略性。他們建造了宏大的競技場,使獸人們在其中磨練殺戮技能並體驗戰爭和死亡。在這段時期裡,一小部分氏族酋長對於種族的墮落表示了強烈的不滿。', 'zhTW', 53788), +(2038, '索爾拿起了末日錘那傳奇般的戰錘,穿上了他的黑色鎧甲,成為了新的部落大酋長。在接下來的幾個月裡,索爾小而靈活的部落掃平了許多收容所,並使聯盟花費了極大精力來應付他精明的戰術。在他最好的朋友兼顧問葛羅·地獄吼的鼓勵下,索爾為了確保沒有獸人再次成為奴隸─無論是人類還是惡魔的─而戰鬥著。', 'zhTW', 53788), +(2037, '作為他的人民所獲得新生的象徵,索爾回到了布拉克摩爾的敦霍爾德城堡並解放了收容所中的獸人。但是,在解放一座收容所的戰鬥中,末日錘戰死了。', 'zhTW', 53788), +(2036, '索爾在旅程中遇到了隱居多年的大酋長奧格林·末日錘。作為索爾的父親最要好的朋友,末日錘決定跟隨年輕有為的索爾並幫助他解放那些被囚禁的氏族。在許多經驗豐富的酋長的幫助下,索爾最終成功地使獸人重新充滿了活力,並為他的人民確立了新的精神信仰。', 'zhTW', 53788), +(2035, '在值得尊敬的薩滿德雷克塔爾的保護下,索爾學習了在古爾丹的邪惡統治下被獸人遺忘的古老薩滿文化。一段時間之後,索爾成為了一位強大的薩滿並成為了霜狼氏族的酋長。在元素的幫助下,索爾決定解放被囚禁的氏族並將他們從惡魔的誘惑中解救出來。', 'zhTW', 53788), +(2034, '為了找尋他自己的氏族,索爾向北方旅行,期望能碰到傳說中的霜狼氏族。索爾瞭解到古爾丹曾經在第一次獸人戰爭早期流放了霜狼氏族,他也瞭解到了他就是獸人英雄杜洛坦─在20年前被謀殺的霜狼氏族的酋長─的唯一子嗣。', 'zhTW', 53788), +(2033, '雖然人類在不斷追捕葛羅,但他仍然保持著獸人旺盛的戰鬥欲望。在他的戰歌氏族的幫助下,地獄吼為解放他那些被壓迫的同胞而不懈戰鬥。不幸的是,地獄吼永遠也找不到解救他們的辦法。索爾被地獄吼的堅定所感動,下定決心要找回獸人的戰鬥傳統。', 'zhTW', 53788), +(2032, '學識豐富但毫無經驗的索爾決定從布拉克摩爾的堡壘中逃跑並尋找他的同胞。在旅途中,索爾訪問了俘虜收容所,並發現他那一度強大的族群變得懶散虛弱,在這裡找不到他希望發現的值得驕傲的戰士。索爾繼續尋找最後的獸人酋長,葛羅·地獄吼。', 'zhTW', 53788), +(2031, '儘管典獄官的養育極其苛刻,年青的索爾仍然成長為一名健壯而聰明的獸人,但他心裡明白自己的一生決不應該作為奴隸度過。當索爾成年以後,他瞭解到了自己的種族,還有那些他從來都沒有見過的、在戰爭中被擊敗的同類們,他們中的大多數都被關入俘虜收容所中。有傳聞說獸人領袖奧格瑞姆·末日錘已經從羅德隆逃走並隱居了起來,只有一個流亡的氏族仍然試圖避開聯盟警惕的目光,秘密地進行著軍事活動。', 'zhTW', 53788), +(2030, '俘虜收容所的大典獄官埃德拉斯·布拉克摩爾在他的監獄堡壘敦霍爾德中監視著被俘的獸人們。有一個特殊的獸人總是引起他的興趣:他在十八年前撿到的那個失去雙親的嬰兒。布拉克摩爾將這個年青的男獸人培養成了一個才華橫溢的奴隸,並給他起名叫索爾。布拉克摩爾將關於戰術、哲學和格鬥的知識傳授給索爾,並將他訓練成為一名角鬥士。自始至終,這個邪惡的典獄官都在致力於將這名獸人青年鑄造成為一件武器。', 'zhTW', 53788), +(2216, '你很幸運,我有一條線索也許可以幫助你對付烏洛克的爪牙:$B$B這個法術是歐莫克用於對付巨魔的,它能一擊殺死他們,即使你殺掉了歐莫克,它也能繼續發揮功效。在你和烏洛克的爪牙作戰時,使用歐莫克的腦袋中蘊含著的力量─如果運氣好的話,歐莫克會擊倒烏洛克的爪牙!$B$B這可真具有諷刺性。', 'zhTW', 53788), +(2215, '到尖石巨魔營地上方那個充滿能量的地方去,就在隧道的旁邊。那裡堆積著曾經挑戰過烏洛克的巨魔的骸骨。你要在那裡插上掛著歐莫克頭顱的長矛!$B$B當你把頭顱安放就位之後,烏洛克必定會到來……但是,首先他會派他的爪牙來對付你。打敗他們,然後烏洛克就會現身了。$B$B殺了他,然後拿回我的魔法。當我奪回我的力量時,你也會得到獎勵的。', 'zhTW', 53788), +(2214, '到裂盾營地去找到一支尖銳的長矛。他們經常把這些長矛堆積在靠近尖石巨魔領地入口的地方,和那些日常用品堆在一起。$B$B當你拿到長矛之後,殺到歐莫克大王那裡,幹掉他,把他的頭顱掛在長矛上。$B$B然後就準備面對真正的挑戰吧。', 'zhTW', 53788), +(2213, '歐莫克大王統治著尖石部族,但是沒有烏洛克的魔法,他是做不到這一點的。烏洛克給歐莫克施加了特殊的魔法,讓他可以打死任何膽敢挑戰他的巨魔。他多次使用過那個法術,並且把那些受害者的頭骨堆在一起,放在歐莫克的房間頂部的一塊地方。$B$B那裡就是你要挑戰烏洛克的地方。', 'zhTW', 53788), +(2212, '啊,我受到了詛咒!我曾經是尖石氏族中的一個偉大的巨魔法師,我向烏洛克發起了挑戰,他偷走了我的魔法,而且還詛咒了我。現在,我只能以這種可笑的樣子在這裡遊蕩!$B$B幫幫我!找到烏洛克,偷回我的魔法!這不是一件簡單的事情,因為烏洛克會藏在暗處,你只有通過了一個極其困難的挑戰才能將其召喚出來。$B$B這個挑戰就是面對烏洛克的親信,歐莫克大王。$B$B繼續讀下去,你會瞭解更多細節的。', 'zhTW', 53788), +(793, '不用說就知道,我們卡加斯衛戍部隊,對能夠被部署在這裡,感到非常高興。我們已經在這裡堅強地紮下了根,因為只要我們略微示弱,就會死在這裡。\n\n在這裡也沒有別的辦法可以生存下去了。\n\n尼卡·血痕\n斥候隊長,卡加斯', 'zhTW', 53788), +(792, '荒蕪之地中滿是我們的敵人。巨魔會從沙中咆哮著突然鑽出,伏擊任何缺乏警惕的冒險者。黑鐵矮人則在卡加斯的東部,建立了一處基地,並和他們那些淺色皮膚的表親,在洛克莫丹北部地方交戰。某種野蠻且原始的、名為穴居怪的種族瘋狂地佔據這裡的每一片土地,並寸步不讓地保護著他們的領地。\n\n那麼荒蕪之地東部的萊瑟羅峽谷呢?它徹底被龍佔據了。我們不知道那裡的龍有多少,也不知道他們有多強大,因為派去那邊偵察的斥候,沒有一個能活著回來的。', 'zhTW', 53788), +(791, '身為卡加斯派出的斥候,我對周圍環境的描述如下:\n\n- 紅色的岩石丘陵與乾燥的平原,只有極少數生物才能在此生存。\n- 陽光熾烈,強風。\n- 沒有湖泊和溪流,也沒有任何池塘。想要找水的話,就必須挖出泥濘的深井,或者從仙人掌與其他針刺類植物中榨水。\n\n簡而言之:燥熱,難以生存。', 'zhTW', 53788), +(711, '赫格拉姆,\n\n無論是誰提議,在荒蕪之地的卡加斯建立一片基地,都將得到我的贊同。這個計畫將使我們在那裡擁有常備的駐軍。那裡的天氣很糟,到處都是兇惡的野生動物與好戰的土著,也沒有什麼補給,惟有我們最好的戰士與斥候,可以在那裡立足。\n\n這計畫很好。幹得漂亮。', 'zhTW', 53788); From 6a25a1d1a71f6aed87f8c021de319c16d992eb8a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 15 Nov 2024 08:01:51 +0000 Subject: [PATCH 094/105] chore(DB): import pending files Referenced commit(s): a0a8b406aaae0710cc6f85bffbf05be9aa3e3418 --- .../rev_1718404604171613900.sql => db_world/2024_11_15_00.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1718404604171613900.sql => db_world/2024_11_15_00.sql} (99%) diff --git a/data/sql/updates/pending_db_world/rev_1718404604171613900.sql b/data/sql/updates/db_world/2024_11_15_00.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1718404604171613900.sql rename to data/sql/updates/db_world/2024_11_15_00.sql index b94d237a36a1d3..5375b963c44845 100644 --- a/data/sql/updates/pending_db_world/rev_1718404604171613900.sql +++ b/data/sql/updates/db_world/2024_11_15_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_14_05 -> 2024_11_15_00 SET @entry := 17109; SET @PATH := @entry * 10; DELETE FROM `waypoints` WHERE `entry`= @PATH; From c5ae1ae88fd2a76e119e54cd896d0227f703117c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francesco=20Borz=C3=AC?= Date: Fri, 15 Nov 2024 11:27:45 +0100 Subject: [PATCH 095/105] chore(DB): move 2023 update files (#20470) * chore(DB): move 2023 update files * chore: flag files as archied --- data/sql/{updates => archive}/db_auth/2023_04_24_00.sql | 0 .../{updates => archive}/db_characters/2023_04_24_00.sql | 0 .../{updates => archive}/db_characters/2023_05_23_00.sql | 0 .../{updates => archive}/db_characters/2023_09_16_00.sql | 0 data/sql/{updates => archive}/db_world/2023_04_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_04_26_00.sql | 0 data/sql/{updates => archive}/db_world/2023_04_26_01.sql | 0 data/sql/{updates => archive}/db_world/2023_04_26_02.sql | 0 data/sql/{updates => archive}/db_world/2023_04_26_03.sql | 0 data/sql/{updates => archive}/db_world/2023_04_27_00.sql | 0 data/sql/{updates => archive}/db_world/2023_04_27_01.sql | 0 data/sql/{updates => archive}/db_world/2023_04_27_02.sql | 0 data/sql/{updates => archive}/db_world/2023_04_29_00.sql | 0 data/sql/{updates => archive}/db_world/2023_04_29_01.sql | 0 data/sql/{updates => archive}/db_world/2023_04_29_02.sql | 0 data/sql/{updates => archive}/db_world/2023_04_29_03.sql | 0 data/sql/{updates => archive}/db_world/2023_04_29_04.sql | 0 data/sql/{updates => archive}/db_world/2023_04_29_05.sql | 0 data/sql/{updates => archive}/db_world/2023_04_29_06.sql | 0 data/sql/{updates => archive}/db_world/2023_04_30_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_01_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_03_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_03_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_03_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_03_03.sql | 0 data/sql/{updates => archive}/db_world/2023_05_09_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_09_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_09_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_03.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_04.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_05.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_06.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_07.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_08.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_09.sql | 0 data/sql/{updates => archive}/db_world/2023_05_10_10.sql | 0 data/sql/{updates => archive}/db_world/2023_05_12_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_12_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_12_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_12_03.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_03.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_04.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_05.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_06.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_07.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_08.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_09.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_10.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_11.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_12.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_13.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_14.sql | 0 data/sql/{updates => archive}/db_world/2023_05_13_15.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_03.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_04.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_05.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_06.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_07.sql | 0 data/sql/{updates => archive}/db_world/2023_05_14_08.sql | 0 data/sql/{updates => archive}/db_world/2023_05_15_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_17_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_20_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_20_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_20_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_21_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_21_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_21_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_23_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_24_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_24_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_24_03.sql | 0 data/sql/{updates => archive}/db_world/2023_05_28_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_28_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_28_02.sql | 0 data/sql/{updates => archive}/db_world/2023_05_28_03.sql | 0 data/sql/{updates => archive}/db_world/2023_05_28_04.sql | 0 data/sql/{updates => archive}/db_world/2023_05_29_00.sql | 0 data/sql/{updates => archive}/db_world/2023_05_29_01.sql | 0 data/sql/{updates => archive}/db_world/2023_05_29_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_01_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_01_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_01_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_01_03.sql | 0 data/sql/{updates => archive}/db_world/2023_06_01_04.sql | 0 data/sql/{updates => archive}/db_world/2023_06_01_05.sql | 0 data/sql/{updates => archive}/db_world/2023_06_01_06.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_03.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_04.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_05.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_06.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_07.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_08.sql | 0 data/sql/{updates => archive}/db_world/2023_06_02_09.sql | 0 data/sql/{updates => archive}/db_world/2023_06_05_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_05_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_07_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_07_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_07_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_07_03.sql | 0 data/sql/{updates => archive}/db_world/2023_06_07_04.sql | 0 data/sql/{updates => archive}/db_world/2023_06_08_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_09_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_11_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_11_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_11_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_16_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_16_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_16_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_03.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_04.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_05.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_06.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_07.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_08.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_09.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_10.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_11.sql | 0 data/sql/{updates => archive}/db_world/2023_06_17_12.sql | 0 data/sql/{updates => archive}/db_world/2023_06_18_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_18_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_18_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_18_03.sql | 0 data/sql/{updates => archive}/db_world/2023_06_21_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_22_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_23_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_23_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_24_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_24_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_24_03.sql | 0 data/sql/{updates => archive}/db_world/2023_06_24_04.sql | 0 data/sql/{updates => archive}/db_world/2023_06_24_05.sql | 0 data/sql/{updates => archive}/db_world/2023_06_24_06.sql | 0 data/sql/{updates => archive}/db_world/2023_06_26_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_26_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_27_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_29_00.sql | 0 data/sql/{updates => archive}/db_world/2023_06_29_01.sql | 0 data/sql/{updates => archive}/db_world/2023_06_29_02.sql | 0 data/sql/{updates => archive}/db_world/2023_06_30_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_02_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_04.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_05.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_06.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_07.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_08.sql | 0 data/sql/{updates => archive}/db_world/2023_07_08_09.sql | 0 data/sql/{updates => archive}/db_world/2023_07_09_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_09_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_10_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_10_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_10_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_10_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_11_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_11_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_11_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_11_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_12_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_15_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_15_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_15_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_15_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_15_04.sql | 0 data/sql/{updates => archive}/db_world/2023_07_16_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_16_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_16_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_16_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_17_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_17_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_18_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_18_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_18_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_19_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_19_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_19_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_19_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_19_04.sql | 0 data/sql/{updates => archive}/db_world/2023_07_22_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_23_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_26_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_26_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_26_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_26_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_26_04.sql | 0 data/sql/{updates => archive}/db_world/2023_07_27_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_27_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_27_02.sql | 0 data/sql/{updates => archive}/db_world/2023_07_27_03.sql | 0 data/sql/{updates => archive}/db_world/2023_07_27_04.sql | 0 data/sql/{updates => archive}/db_world/2023_07_27_05.sql | 0 data/sql/{updates => archive}/db_world/2023_07_28_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_29_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_29_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_30_00.sql | 0 data/sql/{updates => archive}/db_world/2023_07_30_01.sql | 0 data/sql/{updates => archive}/db_world/2023_07_31_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_01_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_02_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_03_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_04_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_03.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_04.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_05.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_06.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_07.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_08.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_09.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_10.sql | 0 data/sql/{updates => archive}/db_world/2023_08_06_11.sql | 0 data/sql/{updates => archive}/db_world/2023_08_07_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_08_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_09_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_09_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_09_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_10_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_10_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_10_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_11_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_11_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_11_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_11_03.sql | 0 data/sql/{updates => archive}/db_world/2023_08_12_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_12_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_12_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_13_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_13_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_13_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_13_03.sql | 0 data/sql/{updates => archive}/db_world/2023_08_14_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_14_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_14_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_14_03.sql | 0 data/sql/{updates => archive}/db_world/2023_08_14_04.sql | 0 data/sql/{updates => archive}/db_world/2023_08_19_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_19_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_19_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_20_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_21_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_21_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_23_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_23_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_24_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_24_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_25_00.sql | 0 data/sql/{updates => archive}/db_world/2023_08_25_01.sql | 0 data/sql/{updates => archive}/db_world/2023_08_25_02.sql | 0 data/sql/{updates => archive}/db_world/2023_08_30_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_04_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_04_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_04_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_05_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_10_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_10_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_11_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_13_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_14_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_14_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_15_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_15_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_15_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_03.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_04.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_05.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_06.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_07.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_08.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_09.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_10.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_11.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_12.sql | 0 data/sql/{updates => archive}/db_world/2023_09_17_13.sql | 0 data/sql/{updates => archive}/db_world/2023_09_18_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_18_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_18_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_18_03.sql | 0 data/sql/{updates => archive}/db_world/2023_09_18_04.sql | 0 data/sql/{updates => archive}/db_world/2023_09_19_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_19_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_03.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_04.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_05.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_06.sql | 0 data/sql/{updates => archive}/db_world/2023_09_20_07.sql | 0 data/sql/{updates => archive}/db_world/2023_09_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_24_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_24_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_03.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_04.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_05.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_06.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_07.sql | 0 data/sql/{updates => archive}/db_world/2023_09_25_08.sql | 0 data/sql/{updates => archive}/db_world/2023_09_26_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_26_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_26_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_26_03.sql | 0 data/sql/{updates => archive}/db_world/2023_09_27_00.sql | 0 data/sql/{updates => archive}/db_world/2023_09_27_01.sql | 0 data/sql/{updates => archive}/db_world/2023_09_27_02.sql | 0 data/sql/{updates => archive}/db_world/2023_09_29_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_01_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_01_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_01_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_01_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_01_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_05_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_07_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_07_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_07_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_05.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_06.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_07.sql | 0 data/sql/{updates => archive}/db_world/2023_10_08_08.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_05.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_06.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_07.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_08.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_09.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_10.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_11.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_12.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_13.sql | 0 data/sql/{updates => archive}/db_world/2023_10_10_14.sql | 0 data/sql/{updates => archive}/db_world/2023_10_11_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_11_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_12_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_12_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_12_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_12_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_12_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_15_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_16_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_16_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_16_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_16_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_16_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_05.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_06.sql | 0 data/sql/{updates => archive}/db_world/2023_10_17_07.sql | 0 data/sql/{updates => archive}/db_world/2023_10_18_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_18_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_18_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_20_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_20_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_20_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_20_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_20_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_20_05.sql | 0 data/sql/{updates => archive}/db_world/2023_10_21_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_21_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_21_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_21_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_21_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_21_05.sql | 0 data/sql/{updates => archive}/db_world/2023_10_21_06.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_03.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_04.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_05.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_06.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_07.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_08.sql | 0 data/sql/{updates => archive}/db_world/2023_10_22_09.sql | 0 data/sql/{updates => archive}/db_world/2023_10_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_25_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_25_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_25_02.sql | 0 data/sql/{updates => archive}/db_world/2023_10_29_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_29_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_31_00.sql | 0 data/sql/{updates => archive}/db_world/2023_10_31_01.sql | 0 data/sql/{updates => archive}/db_world/2023_10_31_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_02_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_02_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_02_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_02_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_05_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_07_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_07_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_07_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_07_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_05.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_06.sql | 0 data/sql/{updates => archive}/db_world/2023_11_08_07.sql | 0 data/sql/{updates => archive}/db_world/2023_11_09_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_10_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_10_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_10_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_11_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_11_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_11_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_11_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_11_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_05.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_06.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_07.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_08.sql | 0 data/sql/{updates => archive}/db_world/2023_11_12_09.sql | 0 data/sql/{updates => archive}/db_world/2023_11_13_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_14_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_14_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_14_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_15_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_15_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_15_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_05.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_06.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_07.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_08.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_09.sql | 0 data/sql/{updates => archive}/db_world/2023_11_16_10.sql | 0 data/sql/{updates => archive}/db_world/2023_11_17_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_17_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_17_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_17_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_17_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_05.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_06.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_07.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_08.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_09.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_10.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_11.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_12.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_13.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_14.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_15.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_16.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_17.sql | 0 data/sql/{updates => archive}/db_world/2023_11_18_18.sql | 0 data/sql/{updates => archive}/db_world/2023_11_19_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_19_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_19_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_19_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_19_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_19_05.sql | 0 data/sql/{updates => archive}/db_world/2023_11_19_06.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_05.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_06.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_07.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_08.sql | 0 data/sql/{updates => archive}/db_world/2023_11_20_09.sql | 0 data/sql/{updates => archive}/db_world/2023_11_22_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_02.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_03.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_04.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_05.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_06.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_07.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_08.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_09.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_10.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_11.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_12.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_13.sql | 0 data/sql/{updates => archive}/db_world/2023_11_26_14.sql | 0 data/sql/{updates => archive}/db_world/2023_11_27_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_28_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_29_00.sql | 0 data/sql/{updates => archive}/db_world/2023_11_29_01.sql | 0 data/sql/{updates => archive}/db_world/2023_11_30_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_02_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_02.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_03.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_04.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_05.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_06.sql | 0 data/sql/{updates => archive}/db_world/2023_12_03_07.sql | 0 data/sql/{updates => archive}/db_world/2023_12_04_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_04_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_04_02.sql | 0 data/sql/{updates => archive}/db_world/2023_12_04_03.sql | 0 data/sql/{updates => archive}/db_world/2023_12_06_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_07_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_07_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_09_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_10_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_10_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_10_02.sql | 0 data/sql/{updates => archive}/db_world/2023_12_10_03.sql | 0 data/sql/{updates => archive}/db_world/2023_12_11_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_11_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_11_02.sql | 0 data/sql/{updates => archive}/db_world/2023_12_11_03.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_02.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_03.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_04.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_05.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_06.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_07.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_08.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_09.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_10.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_11.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_12.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_13.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_14.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_15.sql | 0 data/sql/{updates => archive}/db_world/2023_12_12_16.sql | 0 data/sql/{updates => archive}/db_world/2023_12_24_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_24_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_25_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_25_01.sql | 0 data/sql/{updates => archive}/db_world/2023_12_26_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_28_00.sql | 0 data/sql/{updates => archive}/db_world/2023_12_30_00.sql | 0 data/sql/base/database-squash.md | 8 +++++--- .../updates/pending_db_auth/rev_1730914996045617000.sql | 3 +++ .../pending_db_characters/rev_1730914990538967000.sql | 3 +++ .../updates/pending_db_world/rev_1730914980646466000.sql | 3 +++ 592 files changed, 14 insertions(+), 3 deletions(-) rename data/sql/{updates => archive}/db_auth/2023_04_24_00.sql (100%) rename data/sql/{updates => archive}/db_characters/2023_04_24_00.sql (100%) rename data/sql/{updates => archive}/db_characters/2023_05_23_00.sql (100%) rename data/sql/{updates => archive}/db_characters/2023_09_16_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_26_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_26_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_26_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_26_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_27_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_27_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_27_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_29_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_29_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_29_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_29_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_29_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_29_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_29_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_04_30_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_01_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_03_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_03_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_03_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_03_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_09_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_09_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_09_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_10_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_12_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_12_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_12_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_12_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_12.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_13.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_14.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_13_15.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_14_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_15_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_17_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_20_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_20_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_20_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_21_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_21_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_21_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_23_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_24_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_24_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_24_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_28_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_28_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_28_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_28_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_28_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_29_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_29_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_05_29_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_01_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_01_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_01_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_01_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_01_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_01_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_01_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_02_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_05_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_05_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_07_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_07_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_07_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_07_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_07_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_08_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_09_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_11_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_11_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_11_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_16_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_16_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_16_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_17_12.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_18_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_18_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_18_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_18_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_21_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_22_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_23_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_23_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_24_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_24_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_24_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_24_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_24_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_24_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_26_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_26_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_27_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_29_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_29_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_29_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_06_30_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_02_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_08_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_09_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_09_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_10_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_10_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_10_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_10_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_11_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_11_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_11_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_11_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_12_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_15_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_15_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_15_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_15_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_15_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_16_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_16_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_16_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_16_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_17_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_17_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_18_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_18_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_18_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_19_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_19_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_19_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_19_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_19_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_22_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_23_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_26_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_26_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_26_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_26_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_26_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_27_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_27_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_27_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_27_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_27_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_27_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_28_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_29_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_29_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_30_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_30_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_07_31_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_01_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_02_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_03_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_04_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_06_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_07_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_08_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_09_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_09_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_09_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_10_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_10_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_10_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_11_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_11_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_11_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_11_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_12_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_12_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_12_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_13_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_13_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_13_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_13_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_14_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_14_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_14_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_14_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_14_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_19_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_19_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_19_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_20_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_21_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_21_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_23_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_23_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_24_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_24_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_25_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_25_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_25_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_08_30_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_04_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_04_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_04_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_05_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_10_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_10_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_11_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_13_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_14_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_14_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_15_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_15_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_15_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_12.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_17_13.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_18_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_18_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_18_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_18_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_18_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_19_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_19_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_20_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_24_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_24_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_25_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_26_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_26_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_26_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_26_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_27_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_27_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_27_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_09_29_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_01_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_01_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_01_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_01_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_01_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_05_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_07_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_07_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_07_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_08_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_12.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_13.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_10_14.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_11_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_11_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_12_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_12_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_12_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_12_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_12_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_15_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_16_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_16_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_16_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_16_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_16_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_17_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_18_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_18_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_18_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_20_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_20_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_20_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_20_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_20_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_20_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_21_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_21_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_21_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_21_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_21_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_21_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_21_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_22_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_25_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_25_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_25_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_29_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_29_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_31_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_31_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_10_31_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_02_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_02_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_02_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_02_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_05_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_07_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_07_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_07_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_07_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_08_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_09_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_10_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_10_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_10_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_11_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_11_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_11_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_11_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_11_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_12_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_13_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_14_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_14_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_14_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_15_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_15_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_15_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_16_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_17_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_17_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_17_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_17_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_17_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_12.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_13.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_14.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_15.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_16.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_17.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_18_18.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_19_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_19_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_19_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_19_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_19_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_19_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_19_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_20_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_22_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_12.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_13.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_26_14.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_27_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_28_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_29_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_29_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_11_30_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_02_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_03_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_04_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_04_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_04_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_04_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_06_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_07_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_07_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_09_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_10_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_10_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_10_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_10_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_11_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_11_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_11_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_11_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_02.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_03.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_04.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_05.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_06.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_07.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_08.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_09.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_10.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_11.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_12.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_13.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_14.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_15.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_12_16.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_24_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_24_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_25_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_25_01.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_26_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_28_00.sql (100%) rename data/sql/{updates => archive}/db_world/2023_12_30_00.sql (100%) create mode 100644 data/sql/updates/pending_db_auth/rev_1730914996045617000.sql create mode 100644 data/sql/updates/pending_db_characters/rev_1730914990538967000.sql create mode 100644 data/sql/updates/pending_db_world/rev_1730914980646466000.sql diff --git a/data/sql/updates/db_auth/2023_04_24_00.sql b/data/sql/archive/db_auth/2023_04_24_00.sql similarity index 100% rename from data/sql/updates/db_auth/2023_04_24_00.sql rename to data/sql/archive/db_auth/2023_04_24_00.sql diff --git a/data/sql/updates/db_characters/2023_04_24_00.sql b/data/sql/archive/db_characters/2023_04_24_00.sql similarity index 100% rename from data/sql/updates/db_characters/2023_04_24_00.sql rename to data/sql/archive/db_characters/2023_04_24_00.sql diff --git a/data/sql/updates/db_characters/2023_05_23_00.sql b/data/sql/archive/db_characters/2023_05_23_00.sql similarity index 100% rename from data/sql/updates/db_characters/2023_05_23_00.sql rename to data/sql/archive/db_characters/2023_05_23_00.sql diff --git a/data/sql/updates/db_characters/2023_09_16_00.sql b/data/sql/archive/db_characters/2023_09_16_00.sql similarity index 100% rename from data/sql/updates/db_characters/2023_09_16_00.sql rename to data/sql/archive/db_characters/2023_09_16_00.sql diff --git a/data/sql/updates/db_world/2023_04_24_00.sql b/data/sql/archive/db_world/2023_04_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_24_00.sql rename to data/sql/archive/db_world/2023_04_24_00.sql diff --git a/data/sql/updates/db_world/2023_04_26_00.sql b/data/sql/archive/db_world/2023_04_26_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_26_00.sql rename to data/sql/archive/db_world/2023_04_26_00.sql diff --git a/data/sql/updates/db_world/2023_04_26_01.sql b/data/sql/archive/db_world/2023_04_26_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_26_01.sql rename to data/sql/archive/db_world/2023_04_26_01.sql diff --git a/data/sql/updates/db_world/2023_04_26_02.sql b/data/sql/archive/db_world/2023_04_26_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_26_02.sql rename to data/sql/archive/db_world/2023_04_26_02.sql diff --git a/data/sql/updates/db_world/2023_04_26_03.sql b/data/sql/archive/db_world/2023_04_26_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_26_03.sql rename to data/sql/archive/db_world/2023_04_26_03.sql diff --git a/data/sql/updates/db_world/2023_04_27_00.sql b/data/sql/archive/db_world/2023_04_27_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_27_00.sql rename to data/sql/archive/db_world/2023_04_27_00.sql diff --git a/data/sql/updates/db_world/2023_04_27_01.sql b/data/sql/archive/db_world/2023_04_27_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_27_01.sql rename to data/sql/archive/db_world/2023_04_27_01.sql diff --git a/data/sql/updates/db_world/2023_04_27_02.sql b/data/sql/archive/db_world/2023_04_27_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_27_02.sql rename to data/sql/archive/db_world/2023_04_27_02.sql diff --git a/data/sql/updates/db_world/2023_04_29_00.sql b/data/sql/archive/db_world/2023_04_29_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_29_00.sql rename to data/sql/archive/db_world/2023_04_29_00.sql diff --git a/data/sql/updates/db_world/2023_04_29_01.sql b/data/sql/archive/db_world/2023_04_29_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_29_01.sql rename to data/sql/archive/db_world/2023_04_29_01.sql diff --git a/data/sql/updates/db_world/2023_04_29_02.sql b/data/sql/archive/db_world/2023_04_29_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_29_02.sql rename to data/sql/archive/db_world/2023_04_29_02.sql diff --git a/data/sql/updates/db_world/2023_04_29_03.sql b/data/sql/archive/db_world/2023_04_29_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_29_03.sql rename to data/sql/archive/db_world/2023_04_29_03.sql diff --git a/data/sql/updates/db_world/2023_04_29_04.sql b/data/sql/archive/db_world/2023_04_29_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_29_04.sql rename to data/sql/archive/db_world/2023_04_29_04.sql diff --git a/data/sql/updates/db_world/2023_04_29_05.sql b/data/sql/archive/db_world/2023_04_29_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_29_05.sql rename to data/sql/archive/db_world/2023_04_29_05.sql diff --git a/data/sql/updates/db_world/2023_04_29_06.sql b/data/sql/archive/db_world/2023_04_29_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_29_06.sql rename to data/sql/archive/db_world/2023_04_29_06.sql diff --git a/data/sql/updates/db_world/2023_04_30_00.sql b/data/sql/archive/db_world/2023_04_30_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_04_30_00.sql rename to data/sql/archive/db_world/2023_04_30_00.sql diff --git a/data/sql/updates/db_world/2023_05_01_00.sql b/data/sql/archive/db_world/2023_05_01_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_01_00.sql rename to data/sql/archive/db_world/2023_05_01_00.sql diff --git a/data/sql/updates/db_world/2023_05_03_00.sql b/data/sql/archive/db_world/2023_05_03_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_03_00.sql rename to data/sql/archive/db_world/2023_05_03_00.sql diff --git a/data/sql/updates/db_world/2023_05_03_01.sql b/data/sql/archive/db_world/2023_05_03_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_03_01.sql rename to data/sql/archive/db_world/2023_05_03_01.sql diff --git a/data/sql/updates/db_world/2023_05_03_02.sql b/data/sql/archive/db_world/2023_05_03_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_03_02.sql rename to data/sql/archive/db_world/2023_05_03_02.sql diff --git a/data/sql/updates/db_world/2023_05_03_03.sql b/data/sql/archive/db_world/2023_05_03_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_03_03.sql rename to data/sql/archive/db_world/2023_05_03_03.sql diff --git a/data/sql/updates/db_world/2023_05_09_00.sql b/data/sql/archive/db_world/2023_05_09_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_09_00.sql rename to data/sql/archive/db_world/2023_05_09_00.sql diff --git a/data/sql/updates/db_world/2023_05_09_01.sql b/data/sql/archive/db_world/2023_05_09_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_09_01.sql rename to data/sql/archive/db_world/2023_05_09_01.sql diff --git a/data/sql/updates/db_world/2023_05_09_02.sql b/data/sql/archive/db_world/2023_05_09_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_09_02.sql rename to data/sql/archive/db_world/2023_05_09_02.sql diff --git a/data/sql/updates/db_world/2023_05_10_00.sql b/data/sql/archive/db_world/2023_05_10_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_00.sql rename to data/sql/archive/db_world/2023_05_10_00.sql diff --git a/data/sql/updates/db_world/2023_05_10_01.sql b/data/sql/archive/db_world/2023_05_10_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_01.sql rename to data/sql/archive/db_world/2023_05_10_01.sql diff --git a/data/sql/updates/db_world/2023_05_10_02.sql b/data/sql/archive/db_world/2023_05_10_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_02.sql rename to data/sql/archive/db_world/2023_05_10_02.sql diff --git a/data/sql/updates/db_world/2023_05_10_03.sql b/data/sql/archive/db_world/2023_05_10_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_03.sql rename to data/sql/archive/db_world/2023_05_10_03.sql diff --git a/data/sql/updates/db_world/2023_05_10_04.sql b/data/sql/archive/db_world/2023_05_10_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_04.sql rename to data/sql/archive/db_world/2023_05_10_04.sql diff --git a/data/sql/updates/db_world/2023_05_10_05.sql b/data/sql/archive/db_world/2023_05_10_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_05.sql rename to data/sql/archive/db_world/2023_05_10_05.sql diff --git a/data/sql/updates/db_world/2023_05_10_06.sql b/data/sql/archive/db_world/2023_05_10_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_06.sql rename to data/sql/archive/db_world/2023_05_10_06.sql diff --git a/data/sql/updates/db_world/2023_05_10_07.sql b/data/sql/archive/db_world/2023_05_10_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_07.sql rename to data/sql/archive/db_world/2023_05_10_07.sql diff --git a/data/sql/updates/db_world/2023_05_10_08.sql b/data/sql/archive/db_world/2023_05_10_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_08.sql rename to data/sql/archive/db_world/2023_05_10_08.sql diff --git a/data/sql/updates/db_world/2023_05_10_09.sql b/data/sql/archive/db_world/2023_05_10_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_09.sql rename to data/sql/archive/db_world/2023_05_10_09.sql diff --git a/data/sql/updates/db_world/2023_05_10_10.sql b/data/sql/archive/db_world/2023_05_10_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_10_10.sql rename to data/sql/archive/db_world/2023_05_10_10.sql diff --git a/data/sql/updates/db_world/2023_05_12_00.sql b/data/sql/archive/db_world/2023_05_12_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_12_00.sql rename to data/sql/archive/db_world/2023_05_12_00.sql diff --git a/data/sql/updates/db_world/2023_05_12_01.sql b/data/sql/archive/db_world/2023_05_12_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_12_01.sql rename to data/sql/archive/db_world/2023_05_12_01.sql diff --git a/data/sql/updates/db_world/2023_05_12_02.sql b/data/sql/archive/db_world/2023_05_12_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_12_02.sql rename to data/sql/archive/db_world/2023_05_12_02.sql diff --git a/data/sql/updates/db_world/2023_05_12_03.sql b/data/sql/archive/db_world/2023_05_12_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_12_03.sql rename to data/sql/archive/db_world/2023_05_12_03.sql diff --git a/data/sql/updates/db_world/2023_05_13_00.sql b/data/sql/archive/db_world/2023_05_13_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_00.sql rename to data/sql/archive/db_world/2023_05_13_00.sql diff --git a/data/sql/updates/db_world/2023_05_13_01.sql b/data/sql/archive/db_world/2023_05_13_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_01.sql rename to data/sql/archive/db_world/2023_05_13_01.sql diff --git a/data/sql/updates/db_world/2023_05_13_02.sql b/data/sql/archive/db_world/2023_05_13_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_02.sql rename to data/sql/archive/db_world/2023_05_13_02.sql diff --git a/data/sql/updates/db_world/2023_05_13_03.sql b/data/sql/archive/db_world/2023_05_13_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_03.sql rename to data/sql/archive/db_world/2023_05_13_03.sql diff --git a/data/sql/updates/db_world/2023_05_13_04.sql b/data/sql/archive/db_world/2023_05_13_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_04.sql rename to data/sql/archive/db_world/2023_05_13_04.sql diff --git a/data/sql/updates/db_world/2023_05_13_05.sql b/data/sql/archive/db_world/2023_05_13_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_05.sql rename to data/sql/archive/db_world/2023_05_13_05.sql diff --git a/data/sql/updates/db_world/2023_05_13_06.sql b/data/sql/archive/db_world/2023_05_13_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_06.sql rename to data/sql/archive/db_world/2023_05_13_06.sql diff --git a/data/sql/updates/db_world/2023_05_13_07.sql b/data/sql/archive/db_world/2023_05_13_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_07.sql rename to data/sql/archive/db_world/2023_05_13_07.sql diff --git a/data/sql/updates/db_world/2023_05_13_08.sql b/data/sql/archive/db_world/2023_05_13_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_08.sql rename to data/sql/archive/db_world/2023_05_13_08.sql diff --git a/data/sql/updates/db_world/2023_05_13_09.sql b/data/sql/archive/db_world/2023_05_13_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_09.sql rename to data/sql/archive/db_world/2023_05_13_09.sql diff --git a/data/sql/updates/db_world/2023_05_13_10.sql b/data/sql/archive/db_world/2023_05_13_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_10.sql rename to data/sql/archive/db_world/2023_05_13_10.sql diff --git a/data/sql/updates/db_world/2023_05_13_11.sql b/data/sql/archive/db_world/2023_05_13_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_11.sql rename to data/sql/archive/db_world/2023_05_13_11.sql diff --git a/data/sql/updates/db_world/2023_05_13_12.sql b/data/sql/archive/db_world/2023_05_13_12.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_12.sql rename to data/sql/archive/db_world/2023_05_13_12.sql diff --git a/data/sql/updates/db_world/2023_05_13_13.sql b/data/sql/archive/db_world/2023_05_13_13.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_13.sql rename to data/sql/archive/db_world/2023_05_13_13.sql diff --git a/data/sql/updates/db_world/2023_05_13_14.sql b/data/sql/archive/db_world/2023_05_13_14.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_14.sql rename to data/sql/archive/db_world/2023_05_13_14.sql diff --git a/data/sql/updates/db_world/2023_05_13_15.sql b/data/sql/archive/db_world/2023_05_13_15.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_13_15.sql rename to data/sql/archive/db_world/2023_05_13_15.sql diff --git a/data/sql/updates/db_world/2023_05_14_00.sql b/data/sql/archive/db_world/2023_05_14_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_00.sql rename to data/sql/archive/db_world/2023_05_14_00.sql diff --git a/data/sql/updates/db_world/2023_05_14_01.sql b/data/sql/archive/db_world/2023_05_14_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_01.sql rename to data/sql/archive/db_world/2023_05_14_01.sql diff --git a/data/sql/updates/db_world/2023_05_14_02.sql b/data/sql/archive/db_world/2023_05_14_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_02.sql rename to data/sql/archive/db_world/2023_05_14_02.sql diff --git a/data/sql/updates/db_world/2023_05_14_03.sql b/data/sql/archive/db_world/2023_05_14_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_03.sql rename to data/sql/archive/db_world/2023_05_14_03.sql diff --git a/data/sql/updates/db_world/2023_05_14_04.sql b/data/sql/archive/db_world/2023_05_14_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_04.sql rename to data/sql/archive/db_world/2023_05_14_04.sql diff --git a/data/sql/updates/db_world/2023_05_14_05.sql b/data/sql/archive/db_world/2023_05_14_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_05.sql rename to data/sql/archive/db_world/2023_05_14_05.sql diff --git a/data/sql/updates/db_world/2023_05_14_06.sql b/data/sql/archive/db_world/2023_05_14_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_06.sql rename to data/sql/archive/db_world/2023_05_14_06.sql diff --git a/data/sql/updates/db_world/2023_05_14_07.sql b/data/sql/archive/db_world/2023_05_14_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_07.sql rename to data/sql/archive/db_world/2023_05_14_07.sql diff --git a/data/sql/updates/db_world/2023_05_14_08.sql b/data/sql/archive/db_world/2023_05_14_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_14_08.sql rename to data/sql/archive/db_world/2023_05_14_08.sql diff --git a/data/sql/updates/db_world/2023_05_15_00.sql b/data/sql/archive/db_world/2023_05_15_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_15_00.sql rename to data/sql/archive/db_world/2023_05_15_00.sql diff --git a/data/sql/updates/db_world/2023_05_17_00.sql b/data/sql/archive/db_world/2023_05_17_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_17_00.sql rename to data/sql/archive/db_world/2023_05_17_00.sql diff --git a/data/sql/updates/db_world/2023_05_20_00.sql b/data/sql/archive/db_world/2023_05_20_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_20_00.sql rename to data/sql/archive/db_world/2023_05_20_00.sql diff --git a/data/sql/updates/db_world/2023_05_20_01.sql b/data/sql/archive/db_world/2023_05_20_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_20_01.sql rename to data/sql/archive/db_world/2023_05_20_01.sql diff --git a/data/sql/updates/db_world/2023_05_20_02.sql b/data/sql/archive/db_world/2023_05_20_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_20_02.sql rename to data/sql/archive/db_world/2023_05_20_02.sql diff --git a/data/sql/updates/db_world/2023_05_21_00.sql b/data/sql/archive/db_world/2023_05_21_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_21_00.sql rename to data/sql/archive/db_world/2023_05_21_00.sql diff --git a/data/sql/updates/db_world/2023_05_21_01.sql b/data/sql/archive/db_world/2023_05_21_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_21_01.sql rename to data/sql/archive/db_world/2023_05_21_01.sql diff --git a/data/sql/updates/db_world/2023_05_21_02.sql b/data/sql/archive/db_world/2023_05_21_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_21_02.sql rename to data/sql/archive/db_world/2023_05_21_02.sql diff --git a/data/sql/updates/db_world/2023_05_23_00.sql b/data/sql/archive/db_world/2023_05_23_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_23_00.sql rename to data/sql/archive/db_world/2023_05_23_00.sql diff --git a/data/sql/updates/db_world/2023_05_24_00.sql b/data/sql/archive/db_world/2023_05_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_24_00.sql rename to data/sql/archive/db_world/2023_05_24_00.sql diff --git a/data/sql/updates/db_world/2023_05_24_01.sql b/data/sql/archive/db_world/2023_05_24_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_24_01.sql rename to data/sql/archive/db_world/2023_05_24_01.sql diff --git a/data/sql/updates/db_world/2023_05_24_02.sql b/data/sql/archive/db_world/2023_05_24_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_24_02.sql rename to data/sql/archive/db_world/2023_05_24_02.sql diff --git a/data/sql/updates/db_world/2023_05_24_03.sql b/data/sql/archive/db_world/2023_05_24_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_24_03.sql rename to data/sql/archive/db_world/2023_05_24_03.sql diff --git a/data/sql/updates/db_world/2023_05_28_00.sql b/data/sql/archive/db_world/2023_05_28_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_28_00.sql rename to data/sql/archive/db_world/2023_05_28_00.sql diff --git a/data/sql/updates/db_world/2023_05_28_01.sql b/data/sql/archive/db_world/2023_05_28_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_28_01.sql rename to data/sql/archive/db_world/2023_05_28_01.sql diff --git a/data/sql/updates/db_world/2023_05_28_02.sql b/data/sql/archive/db_world/2023_05_28_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_28_02.sql rename to data/sql/archive/db_world/2023_05_28_02.sql diff --git a/data/sql/updates/db_world/2023_05_28_03.sql b/data/sql/archive/db_world/2023_05_28_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_28_03.sql rename to data/sql/archive/db_world/2023_05_28_03.sql diff --git a/data/sql/updates/db_world/2023_05_28_04.sql b/data/sql/archive/db_world/2023_05_28_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_28_04.sql rename to data/sql/archive/db_world/2023_05_28_04.sql diff --git a/data/sql/updates/db_world/2023_05_29_00.sql b/data/sql/archive/db_world/2023_05_29_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_29_00.sql rename to data/sql/archive/db_world/2023_05_29_00.sql diff --git a/data/sql/updates/db_world/2023_05_29_01.sql b/data/sql/archive/db_world/2023_05_29_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_29_01.sql rename to data/sql/archive/db_world/2023_05_29_01.sql diff --git a/data/sql/updates/db_world/2023_05_29_02.sql b/data/sql/archive/db_world/2023_05_29_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_05_29_02.sql rename to data/sql/archive/db_world/2023_05_29_02.sql diff --git a/data/sql/updates/db_world/2023_06_01_00.sql b/data/sql/archive/db_world/2023_06_01_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_01_00.sql rename to data/sql/archive/db_world/2023_06_01_00.sql diff --git a/data/sql/updates/db_world/2023_06_01_01.sql b/data/sql/archive/db_world/2023_06_01_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_01_01.sql rename to data/sql/archive/db_world/2023_06_01_01.sql diff --git a/data/sql/updates/db_world/2023_06_01_02.sql b/data/sql/archive/db_world/2023_06_01_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_01_02.sql rename to data/sql/archive/db_world/2023_06_01_02.sql diff --git a/data/sql/updates/db_world/2023_06_01_03.sql b/data/sql/archive/db_world/2023_06_01_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_01_03.sql rename to data/sql/archive/db_world/2023_06_01_03.sql diff --git a/data/sql/updates/db_world/2023_06_01_04.sql b/data/sql/archive/db_world/2023_06_01_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_01_04.sql rename to data/sql/archive/db_world/2023_06_01_04.sql diff --git a/data/sql/updates/db_world/2023_06_01_05.sql b/data/sql/archive/db_world/2023_06_01_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_01_05.sql rename to data/sql/archive/db_world/2023_06_01_05.sql diff --git a/data/sql/updates/db_world/2023_06_01_06.sql b/data/sql/archive/db_world/2023_06_01_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_01_06.sql rename to data/sql/archive/db_world/2023_06_01_06.sql diff --git a/data/sql/updates/db_world/2023_06_02_00.sql b/data/sql/archive/db_world/2023_06_02_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_00.sql rename to data/sql/archive/db_world/2023_06_02_00.sql diff --git a/data/sql/updates/db_world/2023_06_02_01.sql b/data/sql/archive/db_world/2023_06_02_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_01.sql rename to data/sql/archive/db_world/2023_06_02_01.sql diff --git a/data/sql/updates/db_world/2023_06_02_02.sql b/data/sql/archive/db_world/2023_06_02_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_02.sql rename to data/sql/archive/db_world/2023_06_02_02.sql diff --git a/data/sql/updates/db_world/2023_06_02_03.sql b/data/sql/archive/db_world/2023_06_02_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_03.sql rename to data/sql/archive/db_world/2023_06_02_03.sql diff --git a/data/sql/updates/db_world/2023_06_02_04.sql b/data/sql/archive/db_world/2023_06_02_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_04.sql rename to data/sql/archive/db_world/2023_06_02_04.sql diff --git a/data/sql/updates/db_world/2023_06_02_05.sql b/data/sql/archive/db_world/2023_06_02_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_05.sql rename to data/sql/archive/db_world/2023_06_02_05.sql diff --git a/data/sql/updates/db_world/2023_06_02_06.sql b/data/sql/archive/db_world/2023_06_02_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_06.sql rename to data/sql/archive/db_world/2023_06_02_06.sql diff --git a/data/sql/updates/db_world/2023_06_02_07.sql b/data/sql/archive/db_world/2023_06_02_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_07.sql rename to data/sql/archive/db_world/2023_06_02_07.sql diff --git a/data/sql/updates/db_world/2023_06_02_08.sql b/data/sql/archive/db_world/2023_06_02_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_08.sql rename to data/sql/archive/db_world/2023_06_02_08.sql diff --git a/data/sql/updates/db_world/2023_06_02_09.sql b/data/sql/archive/db_world/2023_06_02_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_02_09.sql rename to data/sql/archive/db_world/2023_06_02_09.sql diff --git a/data/sql/updates/db_world/2023_06_05_00.sql b/data/sql/archive/db_world/2023_06_05_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_05_00.sql rename to data/sql/archive/db_world/2023_06_05_00.sql diff --git a/data/sql/updates/db_world/2023_06_05_01.sql b/data/sql/archive/db_world/2023_06_05_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_05_01.sql rename to data/sql/archive/db_world/2023_06_05_01.sql diff --git a/data/sql/updates/db_world/2023_06_07_00.sql b/data/sql/archive/db_world/2023_06_07_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_07_00.sql rename to data/sql/archive/db_world/2023_06_07_00.sql diff --git a/data/sql/updates/db_world/2023_06_07_01.sql b/data/sql/archive/db_world/2023_06_07_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_07_01.sql rename to data/sql/archive/db_world/2023_06_07_01.sql diff --git a/data/sql/updates/db_world/2023_06_07_02.sql b/data/sql/archive/db_world/2023_06_07_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_07_02.sql rename to data/sql/archive/db_world/2023_06_07_02.sql diff --git a/data/sql/updates/db_world/2023_06_07_03.sql b/data/sql/archive/db_world/2023_06_07_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_07_03.sql rename to data/sql/archive/db_world/2023_06_07_03.sql diff --git a/data/sql/updates/db_world/2023_06_07_04.sql b/data/sql/archive/db_world/2023_06_07_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_07_04.sql rename to data/sql/archive/db_world/2023_06_07_04.sql diff --git a/data/sql/updates/db_world/2023_06_08_00.sql b/data/sql/archive/db_world/2023_06_08_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_08_00.sql rename to data/sql/archive/db_world/2023_06_08_00.sql diff --git a/data/sql/updates/db_world/2023_06_09_00.sql b/data/sql/archive/db_world/2023_06_09_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_09_00.sql rename to data/sql/archive/db_world/2023_06_09_00.sql diff --git a/data/sql/updates/db_world/2023_06_11_00.sql b/data/sql/archive/db_world/2023_06_11_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_11_00.sql rename to data/sql/archive/db_world/2023_06_11_00.sql diff --git a/data/sql/updates/db_world/2023_06_11_01.sql b/data/sql/archive/db_world/2023_06_11_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_11_01.sql rename to data/sql/archive/db_world/2023_06_11_01.sql diff --git a/data/sql/updates/db_world/2023_06_11_02.sql b/data/sql/archive/db_world/2023_06_11_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_11_02.sql rename to data/sql/archive/db_world/2023_06_11_02.sql diff --git a/data/sql/updates/db_world/2023_06_16_00.sql b/data/sql/archive/db_world/2023_06_16_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_16_00.sql rename to data/sql/archive/db_world/2023_06_16_00.sql diff --git a/data/sql/updates/db_world/2023_06_16_01.sql b/data/sql/archive/db_world/2023_06_16_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_16_01.sql rename to data/sql/archive/db_world/2023_06_16_01.sql diff --git a/data/sql/updates/db_world/2023_06_16_02.sql b/data/sql/archive/db_world/2023_06_16_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_16_02.sql rename to data/sql/archive/db_world/2023_06_16_02.sql diff --git a/data/sql/updates/db_world/2023_06_17_00.sql b/data/sql/archive/db_world/2023_06_17_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_00.sql rename to data/sql/archive/db_world/2023_06_17_00.sql diff --git a/data/sql/updates/db_world/2023_06_17_01.sql b/data/sql/archive/db_world/2023_06_17_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_01.sql rename to data/sql/archive/db_world/2023_06_17_01.sql diff --git a/data/sql/updates/db_world/2023_06_17_02.sql b/data/sql/archive/db_world/2023_06_17_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_02.sql rename to data/sql/archive/db_world/2023_06_17_02.sql diff --git a/data/sql/updates/db_world/2023_06_17_03.sql b/data/sql/archive/db_world/2023_06_17_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_03.sql rename to data/sql/archive/db_world/2023_06_17_03.sql diff --git a/data/sql/updates/db_world/2023_06_17_04.sql b/data/sql/archive/db_world/2023_06_17_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_04.sql rename to data/sql/archive/db_world/2023_06_17_04.sql diff --git a/data/sql/updates/db_world/2023_06_17_05.sql b/data/sql/archive/db_world/2023_06_17_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_05.sql rename to data/sql/archive/db_world/2023_06_17_05.sql diff --git a/data/sql/updates/db_world/2023_06_17_06.sql b/data/sql/archive/db_world/2023_06_17_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_06.sql rename to data/sql/archive/db_world/2023_06_17_06.sql diff --git a/data/sql/updates/db_world/2023_06_17_07.sql b/data/sql/archive/db_world/2023_06_17_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_07.sql rename to data/sql/archive/db_world/2023_06_17_07.sql diff --git a/data/sql/updates/db_world/2023_06_17_08.sql b/data/sql/archive/db_world/2023_06_17_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_08.sql rename to data/sql/archive/db_world/2023_06_17_08.sql diff --git a/data/sql/updates/db_world/2023_06_17_09.sql b/data/sql/archive/db_world/2023_06_17_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_09.sql rename to data/sql/archive/db_world/2023_06_17_09.sql diff --git a/data/sql/updates/db_world/2023_06_17_10.sql b/data/sql/archive/db_world/2023_06_17_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_10.sql rename to data/sql/archive/db_world/2023_06_17_10.sql diff --git a/data/sql/updates/db_world/2023_06_17_11.sql b/data/sql/archive/db_world/2023_06_17_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_11.sql rename to data/sql/archive/db_world/2023_06_17_11.sql diff --git a/data/sql/updates/db_world/2023_06_17_12.sql b/data/sql/archive/db_world/2023_06_17_12.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_17_12.sql rename to data/sql/archive/db_world/2023_06_17_12.sql diff --git a/data/sql/updates/db_world/2023_06_18_00.sql b/data/sql/archive/db_world/2023_06_18_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_18_00.sql rename to data/sql/archive/db_world/2023_06_18_00.sql diff --git a/data/sql/updates/db_world/2023_06_18_01.sql b/data/sql/archive/db_world/2023_06_18_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_18_01.sql rename to data/sql/archive/db_world/2023_06_18_01.sql diff --git a/data/sql/updates/db_world/2023_06_18_02.sql b/data/sql/archive/db_world/2023_06_18_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_18_02.sql rename to data/sql/archive/db_world/2023_06_18_02.sql diff --git a/data/sql/updates/db_world/2023_06_18_03.sql b/data/sql/archive/db_world/2023_06_18_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_18_03.sql rename to data/sql/archive/db_world/2023_06_18_03.sql diff --git a/data/sql/updates/db_world/2023_06_21_00.sql b/data/sql/archive/db_world/2023_06_21_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_21_00.sql rename to data/sql/archive/db_world/2023_06_21_00.sql diff --git a/data/sql/updates/db_world/2023_06_22_00.sql b/data/sql/archive/db_world/2023_06_22_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_22_00.sql rename to data/sql/archive/db_world/2023_06_22_00.sql diff --git a/data/sql/updates/db_world/2023_06_23_00.sql b/data/sql/archive/db_world/2023_06_23_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_23_00.sql rename to data/sql/archive/db_world/2023_06_23_00.sql diff --git a/data/sql/updates/db_world/2023_06_23_01.sql b/data/sql/archive/db_world/2023_06_23_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_23_01.sql rename to data/sql/archive/db_world/2023_06_23_01.sql diff --git a/data/sql/updates/db_world/2023_06_24_00.sql b/data/sql/archive/db_world/2023_06_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_24_00.sql rename to data/sql/archive/db_world/2023_06_24_00.sql diff --git a/data/sql/updates/db_world/2023_06_24_01.sql b/data/sql/archive/db_world/2023_06_24_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_24_01.sql rename to data/sql/archive/db_world/2023_06_24_01.sql diff --git a/data/sql/updates/db_world/2023_06_24_02.sql b/data/sql/archive/db_world/2023_06_24_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_24_02.sql rename to data/sql/archive/db_world/2023_06_24_02.sql diff --git a/data/sql/updates/db_world/2023_06_24_03.sql b/data/sql/archive/db_world/2023_06_24_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_24_03.sql rename to data/sql/archive/db_world/2023_06_24_03.sql diff --git a/data/sql/updates/db_world/2023_06_24_04.sql b/data/sql/archive/db_world/2023_06_24_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_24_04.sql rename to data/sql/archive/db_world/2023_06_24_04.sql diff --git a/data/sql/updates/db_world/2023_06_24_05.sql b/data/sql/archive/db_world/2023_06_24_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_24_05.sql rename to data/sql/archive/db_world/2023_06_24_05.sql diff --git a/data/sql/updates/db_world/2023_06_24_06.sql b/data/sql/archive/db_world/2023_06_24_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_24_06.sql rename to data/sql/archive/db_world/2023_06_24_06.sql diff --git a/data/sql/updates/db_world/2023_06_26_00.sql b/data/sql/archive/db_world/2023_06_26_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_26_00.sql rename to data/sql/archive/db_world/2023_06_26_00.sql diff --git a/data/sql/updates/db_world/2023_06_26_01.sql b/data/sql/archive/db_world/2023_06_26_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_26_01.sql rename to data/sql/archive/db_world/2023_06_26_01.sql diff --git a/data/sql/updates/db_world/2023_06_27_00.sql b/data/sql/archive/db_world/2023_06_27_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_27_00.sql rename to data/sql/archive/db_world/2023_06_27_00.sql diff --git a/data/sql/updates/db_world/2023_06_29_00.sql b/data/sql/archive/db_world/2023_06_29_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_29_00.sql rename to data/sql/archive/db_world/2023_06_29_00.sql diff --git a/data/sql/updates/db_world/2023_06_29_01.sql b/data/sql/archive/db_world/2023_06_29_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_29_01.sql rename to data/sql/archive/db_world/2023_06_29_01.sql diff --git a/data/sql/updates/db_world/2023_06_29_02.sql b/data/sql/archive/db_world/2023_06_29_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_29_02.sql rename to data/sql/archive/db_world/2023_06_29_02.sql diff --git a/data/sql/updates/db_world/2023_06_30_00.sql b/data/sql/archive/db_world/2023_06_30_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_06_30_00.sql rename to data/sql/archive/db_world/2023_06_30_00.sql diff --git a/data/sql/updates/db_world/2023_07_02_00.sql b/data/sql/archive/db_world/2023_07_02_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_02_00.sql rename to data/sql/archive/db_world/2023_07_02_00.sql diff --git a/data/sql/updates/db_world/2023_07_08_00.sql b/data/sql/archive/db_world/2023_07_08_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_00.sql rename to data/sql/archive/db_world/2023_07_08_00.sql diff --git a/data/sql/updates/db_world/2023_07_08_01.sql b/data/sql/archive/db_world/2023_07_08_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_01.sql rename to data/sql/archive/db_world/2023_07_08_01.sql diff --git a/data/sql/updates/db_world/2023_07_08_02.sql b/data/sql/archive/db_world/2023_07_08_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_02.sql rename to data/sql/archive/db_world/2023_07_08_02.sql diff --git a/data/sql/updates/db_world/2023_07_08_03.sql b/data/sql/archive/db_world/2023_07_08_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_03.sql rename to data/sql/archive/db_world/2023_07_08_03.sql diff --git a/data/sql/updates/db_world/2023_07_08_04.sql b/data/sql/archive/db_world/2023_07_08_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_04.sql rename to data/sql/archive/db_world/2023_07_08_04.sql diff --git a/data/sql/updates/db_world/2023_07_08_05.sql b/data/sql/archive/db_world/2023_07_08_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_05.sql rename to data/sql/archive/db_world/2023_07_08_05.sql diff --git a/data/sql/updates/db_world/2023_07_08_06.sql b/data/sql/archive/db_world/2023_07_08_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_06.sql rename to data/sql/archive/db_world/2023_07_08_06.sql diff --git a/data/sql/updates/db_world/2023_07_08_07.sql b/data/sql/archive/db_world/2023_07_08_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_07.sql rename to data/sql/archive/db_world/2023_07_08_07.sql diff --git a/data/sql/updates/db_world/2023_07_08_08.sql b/data/sql/archive/db_world/2023_07_08_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_08.sql rename to data/sql/archive/db_world/2023_07_08_08.sql diff --git a/data/sql/updates/db_world/2023_07_08_09.sql b/data/sql/archive/db_world/2023_07_08_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_08_09.sql rename to data/sql/archive/db_world/2023_07_08_09.sql diff --git a/data/sql/updates/db_world/2023_07_09_00.sql b/data/sql/archive/db_world/2023_07_09_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_09_00.sql rename to data/sql/archive/db_world/2023_07_09_00.sql diff --git a/data/sql/updates/db_world/2023_07_09_01.sql b/data/sql/archive/db_world/2023_07_09_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_09_01.sql rename to data/sql/archive/db_world/2023_07_09_01.sql diff --git a/data/sql/updates/db_world/2023_07_10_00.sql b/data/sql/archive/db_world/2023_07_10_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_10_00.sql rename to data/sql/archive/db_world/2023_07_10_00.sql diff --git a/data/sql/updates/db_world/2023_07_10_01.sql b/data/sql/archive/db_world/2023_07_10_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_10_01.sql rename to data/sql/archive/db_world/2023_07_10_01.sql diff --git a/data/sql/updates/db_world/2023_07_10_02.sql b/data/sql/archive/db_world/2023_07_10_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_10_02.sql rename to data/sql/archive/db_world/2023_07_10_02.sql diff --git a/data/sql/updates/db_world/2023_07_10_03.sql b/data/sql/archive/db_world/2023_07_10_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_10_03.sql rename to data/sql/archive/db_world/2023_07_10_03.sql diff --git a/data/sql/updates/db_world/2023_07_11_00.sql b/data/sql/archive/db_world/2023_07_11_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_11_00.sql rename to data/sql/archive/db_world/2023_07_11_00.sql diff --git a/data/sql/updates/db_world/2023_07_11_01.sql b/data/sql/archive/db_world/2023_07_11_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_11_01.sql rename to data/sql/archive/db_world/2023_07_11_01.sql diff --git a/data/sql/updates/db_world/2023_07_11_02.sql b/data/sql/archive/db_world/2023_07_11_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_11_02.sql rename to data/sql/archive/db_world/2023_07_11_02.sql diff --git a/data/sql/updates/db_world/2023_07_11_03.sql b/data/sql/archive/db_world/2023_07_11_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_11_03.sql rename to data/sql/archive/db_world/2023_07_11_03.sql diff --git a/data/sql/updates/db_world/2023_07_12_00.sql b/data/sql/archive/db_world/2023_07_12_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_12_00.sql rename to data/sql/archive/db_world/2023_07_12_00.sql diff --git a/data/sql/updates/db_world/2023_07_15_00.sql b/data/sql/archive/db_world/2023_07_15_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_15_00.sql rename to data/sql/archive/db_world/2023_07_15_00.sql diff --git a/data/sql/updates/db_world/2023_07_15_01.sql b/data/sql/archive/db_world/2023_07_15_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_15_01.sql rename to data/sql/archive/db_world/2023_07_15_01.sql diff --git a/data/sql/updates/db_world/2023_07_15_02.sql b/data/sql/archive/db_world/2023_07_15_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_15_02.sql rename to data/sql/archive/db_world/2023_07_15_02.sql diff --git a/data/sql/updates/db_world/2023_07_15_03.sql b/data/sql/archive/db_world/2023_07_15_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_15_03.sql rename to data/sql/archive/db_world/2023_07_15_03.sql diff --git a/data/sql/updates/db_world/2023_07_15_04.sql b/data/sql/archive/db_world/2023_07_15_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_15_04.sql rename to data/sql/archive/db_world/2023_07_15_04.sql diff --git a/data/sql/updates/db_world/2023_07_16_00.sql b/data/sql/archive/db_world/2023_07_16_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_16_00.sql rename to data/sql/archive/db_world/2023_07_16_00.sql diff --git a/data/sql/updates/db_world/2023_07_16_01.sql b/data/sql/archive/db_world/2023_07_16_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_16_01.sql rename to data/sql/archive/db_world/2023_07_16_01.sql diff --git a/data/sql/updates/db_world/2023_07_16_02.sql b/data/sql/archive/db_world/2023_07_16_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_16_02.sql rename to data/sql/archive/db_world/2023_07_16_02.sql diff --git a/data/sql/updates/db_world/2023_07_16_03.sql b/data/sql/archive/db_world/2023_07_16_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_16_03.sql rename to data/sql/archive/db_world/2023_07_16_03.sql diff --git a/data/sql/updates/db_world/2023_07_17_00.sql b/data/sql/archive/db_world/2023_07_17_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_17_00.sql rename to data/sql/archive/db_world/2023_07_17_00.sql diff --git a/data/sql/updates/db_world/2023_07_17_01.sql b/data/sql/archive/db_world/2023_07_17_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_17_01.sql rename to data/sql/archive/db_world/2023_07_17_01.sql diff --git a/data/sql/updates/db_world/2023_07_18_00.sql b/data/sql/archive/db_world/2023_07_18_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_18_00.sql rename to data/sql/archive/db_world/2023_07_18_00.sql diff --git a/data/sql/updates/db_world/2023_07_18_01.sql b/data/sql/archive/db_world/2023_07_18_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_18_01.sql rename to data/sql/archive/db_world/2023_07_18_01.sql diff --git a/data/sql/updates/db_world/2023_07_18_02.sql b/data/sql/archive/db_world/2023_07_18_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_18_02.sql rename to data/sql/archive/db_world/2023_07_18_02.sql diff --git a/data/sql/updates/db_world/2023_07_19_00.sql b/data/sql/archive/db_world/2023_07_19_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_19_00.sql rename to data/sql/archive/db_world/2023_07_19_00.sql diff --git a/data/sql/updates/db_world/2023_07_19_01.sql b/data/sql/archive/db_world/2023_07_19_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_19_01.sql rename to data/sql/archive/db_world/2023_07_19_01.sql diff --git a/data/sql/updates/db_world/2023_07_19_02.sql b/data/sql/archive/db_world/2023_07_19_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_19_02.sql rename to data/sql/archive/db_world/2023_07_19_02.sql diff --git a/data/sql/updates/db_world/2023_07_19_03.sql b/data/sql/archive/db_world/2023_07_19_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_19_03.sql rename to data/sql/archive/db_world/2023_07_19_03.sql diff --git a/data/sql/updates/db_world/2023_07_19_04.sql b/data/sql/archive/db_world/2023_07_19_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_19_04.sql rename to data/sql/archive/db_world/2023_07_19_04.sql diff --git a/data/sql/updates/db_world/2023_07_22_00.sql b/data/sql/archive/db_world/2023_07_22_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_22_00.sql rename to data/sql/archive/db_world/2023_07_22_00.sql diff --git a/data/sql/updates/db_world/2023_07_23_00.sql b/data/sql/archive/db_world/2023_07_23_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_23_00.sql rename to data/sql/archive/db_world/2023_07_23_00.sql diff --git a/data/sql/updates/db_world/2023_07_24_00.sql b/data/sql/archive/db_world/2023_07_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_24_00.sql rename to data/sql/archive/db_world/2023_07_24_00.sql diff --git a/data/sql/updates/db_world/2023_07_26_00.sql b/data/sql/archive/db_world/2023_07_26_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_26_00.sql rename to data/sql/archive/db_world/2023_07_26_00.sql diff --git a/data/sql/updates/db_world/2023_07_26_01.sql b/data/sql/archive/db_world/2023_07_26_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_26_01.sql rename to data/sql/archive/db_world/2023_07_26_01.sql diff --git a/data/sql/updates/db_world/2023_07_26_02.sql b/data/sql/archive/db_world/2023_07_26_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_26_02.sql rename to data/sql/archive/db_world/2023_07_26_02.sql diff --git a/data/sql/updates/db_world/2023_07_26_03.sql b/data/sql/archive/db_world/2023_07_26_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_26_03.sql rename to data/sql/archive/db_world/2023_07_26_03.sql diff --git a/data/sql/updates/db_world/2023_07_26_04.sql b/data/sql/archive/db_world/2023_07_26_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_26_04.sql rename to data/sql/archive/db_world/2023_07_26_04.sql diff --git a/data/sql/updates/db_world/2023_07_27_00.sql b/data/sql/archive/db_world/2023_07_27_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_27_00.sql rename to data/sql/archive/db_world/2023_07_27_00.sql diff --git a/data/sql/updates/db_world/2023_07_27_01.sql b/data/sql/archive/db_world/2023_07_27_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_27_01.sql rename to data/sql/archive/db_world/2023_07_27_01.sql diff --git a/data/sql/updates/db_world/2023_07_27_02.sql b/data/sql/archive/db_world/2023_07_27_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_27_02.sql rename to data/sql/archive/db_world/2023_07_27_02.sql diff --git a/data/sql/updates/db_world/2023_07_27_03.sql b/data/sql/archive/db_world/2023_07_27_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_27_03.sql rename to data/sql/archive/db_world/2023_07_27_03.sql diff --git a/data/sql/updates/db_world/2023_07_27_04.sql b/data/sql/archive/db_world/2023_07_27_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_27_04.sql rename to data/sql/archive/db_world/2023_07_27_04.sql diff --git a/data/sql/updates/db_world/2023_07_27_05.sql b/data/sql/archive/db_world/2023_07_27_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_27_05.sql rename to data/sql/archive/db_world/2023_07_27_05.sql diff --git a/data/sql/updates/db_world/2023_07_28_00.sql b/data/sql/archive/db_world/2023_07_28_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_28_00.sql rename to data/sql/archive/db_world/2023_07_28_00.sql diff --git a/data/sql/updates/db_world/2023_07_29_00.sql b/data/sql/archive/db_world/2023_07_29_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_29_00.sql rename to data/sql/archive/db_world/2023_07_29_00.sql diff --git a/data/sql/updates/db_world/2023_07_29_01.sql b/data/sql/archive/db_world/2023_07_29_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_29_01.sql rename to data/sql/archive/db_world/2023_07_29_01.sql diff --git a/data/sql/updates/db_world/2023_07_30_00.sql b/data/sql/archive/db_world/2023_07_30_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_30_00.sql rename to data/sql/archive/db_world/2023_07_30_00.sql diff --git a/data/sql/updates/db_world/2023_07_30_01.sql b/data/sql/archive/db_world/2023_07_30_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_30_01.sql rename to data/sql/archive/db_world/2023_07_30_01.sql diff --git a/data/sql/updates/db_world/2023_07_31_00.sql b/data/sql/archive/db_world/2023_07_31_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_07_31_00.sql rename to data/sql/archive/db_world/2023_07_31_00.sql diff --git a/data/sql/updates/db_world/2023_08_01_00.sql b/data/sql/archive/db_world/2023_08_01_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_01_00.sql rename to data/sql/archive/db_world/2023_08_01_00.sql diff --git a/data/sql/updates/db_world/2023_08_02_00.sql b/data/sql/archive/db_world/2023_08_02_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_02_00.sql rename to data/sql/archive/db_world/2023_08_02_00.sql diff --git a/data/sql/updates/db_world/2023_08_03_00.sql b/data/sql/archive/db_world/2023_08_03_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_03_00.sql rename to data/sql/archive/db_world/2023_08_03_00.sql diff --git a/data/sql/updates/db_world/2023_08_04_00.sql b/data/sql/archive/db_world/2023_08_04_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_04_00.sql rename to data/sql/archive/db_world/2023_08_04_00.sql diff --git a/data/sql/updates/db_world/2023_08_06_00.sql b/data/sql/archive/db_world/2023_08_06_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_00.sql rename to data/sql/archive/db_world/2023_08_06_00.sql diff --git a/data/sql/updates/db_world/2023_08_06_01.sql b/data/sql/archive/db_world/2023_08_06_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_01.sql rename to data/sql/archive/db_world/2023_08_06_01.sql diff --git a/data/sql/updates/db_world/2023_08_06_02.sql b/data/sql/archive/db_world/2023_08_06_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_02.sql rename to data/sql/archive/db_world/2023_08_06_02.sql diff --git a/data/sql/updates/db_world/2023_08_06_03.sql b/data/sql/archive/db_world/2023_08_06_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_03.sql rename to data/sql/archive/db_world/2023_08_06_03.sql diff --git a/data/sql/updates/db_world/2023_08_06_04.sql b/data/sql/archive/db_world/2023_08_06_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_04.sql rename to data/sql/archive/db_world/2023_08_06_04.sql diff --git a/data/sql/updates/db_world/2023_08_06_05.sql b/data/sql/archive/db_world/2023_08_06_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_05.sql rename to data/sql/archive/db_world/2023_08_06_05.sql diff --git a/data/sql/updates/db_world/2023_08_06_06.sql b/data/sql/archive/db_world/2023_08_06_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_06.sql rename to data/sql/archive/db_world/2023_08_06_06.sql diff --git a/data/sql/updates/db_world/2023_08_06_07.sql b/data/sql/archive/db_world/2023_08_06_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_07.sql rename to data/sql/archive/db_world/2023_08_06_07.sql diff --git a/data/sql/updates/db_world/2023_08_06_08.sql b/data/sql/archive/db_world/2023_08_06_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_08.sql rename to data/sql/archive/db_world/2023_08_06_08.sql diff --git a/data/sql/updates/db_world/2023_08_06_09.sql b/data/sql/archive/db_world/2023_08_06_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_09.sql rename to data/sql/archive/db_world/2023_08_06_09.sql diff --git a/data/sql/updates/db_world/2023_08_06_10.sql b/data/sql/archive/db_world/2023_08_06_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_10.sql rename to data/sql/archive/db_world/2023_08_06_10.sql diff --git a/data/sql/updates/db_world/2023_08_06_11.sql b/data/sql/archive/db_world/2023_08_06_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_06_11.sql rename to data/sql/archive/db_world/2023_08_06_11.sql diff --git a/data/sql/updates/db_world/2023_08_07_00.sql b/data/sql/archive/db_world/2023_08_07_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_07_00.sql rename to data/sql/archive/db_world/2023_08_07_00.sql diff --git a/data/sql/updates/db_world/2023_08_08_00.sql b/data/sql/archive/db_world/2023_08_08_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_08_00.sql rename to data/sql/archive/db_world/2023_08_08_00.sql diff --git a/data/sql/updates/db_world/2023_08_09_00.sql b/data/sql/archive/db_world/2023_08_09_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_09_00.sql rename to data/sql/archive/db_world/2023_08_09_00.sql diff --git a/data/sql/updates/db_world/2023_08_09_01.sql b/data/sql/archive/db_world/2023_08_09_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_09_01.sql rename to data/sql/archive/db_world/2023_08_09_01.sql diff --git a/data/sql/updates/db_world/2023_08_09_02.sql b/data/sql/archive/db_world/2023_08_09_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_09_02.sql rename to data/sql/archive/db_world/2023_08_09_02.sql diff --git a/data/sql/updates/db_world/2023_08_10_00.sql b/data/sql/archive/db_world/2023_08_10_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_10_00.sql rename to data/sql/archive/db_world/2023_08_10_00.sql diff --git a/data/sql/updates/db_world/2023_08_10_01.sql b/data/sql/archive/db_world/2023_08_10_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_10_01.sql rename to data/sql/archive/db_world/2023_08_10_01.sql diff --git a/data/sql/updates/db_world/2023_08_10_02.sql b/data/sql/archive/db_world/2023_08_10_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_10_02.sql rename to data/sql/archive/db_world/2023_08_10_02.sql diff --git a/data/sql/updates/db_world/2023_08_11_00.sql b/data/sql/archive/db_world/2023_08_11_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_11_00.sql rename to data/sql/archive/db_world/2023_08_11_00.sql diff --git a/data/sql/updates/db_world/2023_08_11_01.sql b/data/sql/archive/db_world/2023_08_11_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_11_01.sql rename to data/sql/archive/db_world/2023_08_11_01.sql diff --git a/data/sql/updates/db_world/2023_08_11_02.sql b/data/sql/archive/db_world/2023_08_11_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_11_02.sql rename to data/sql/archive/db_world/2023_08_11_02.sql diff --git a/data/sql/updates/db_world/2023_08_11_03.sql b/data/sql/archive/db_world/2023_08_11_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_11_03.sql rename to data/sql/archive/db_world/2023_08_11_03.sql diff --git a/data/sql/updates/db_world/2023_08_12_00.sql b/data/sql/archive/db_world/2023_08_12_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_12_00.sql rename to data/sql/archive/db_world/2023_08_12_00.sql diff --git a/data/sql/updates/db_world/2023_08_12_01.sql b/data/sql/archive/db_world/2023_08_12_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_12_01.sql rename to data/sql/archive/db_world/2023_08_12_01.sql diff --git a/data/sql/updates/db_world/2023_08_12_02.sql b/data/sql/archive/db_world/2023_08_12_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_12_02.sql rename to data/sql/archive/db_world/2023_08_12_02.sql diff --git a/data/sql/updates/db_world/2023_08_13_00.sql b/data/sql/archive/db_world/2023_08_13_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_13_00.sql rename to data/sql/archive/db_world/2023_08_13_00.sql diff --git a/data/sql/updates/db_world/2023_08_13_01.sql b/data/sql/archive/db_world/2023_08_13_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_13_01.sql rename to data/sql/archive/db_world/2023_08_13_01.sql diff --git a/data/sql/updates/db_world/2023_08_13_02.sql b/data/sql/archive/db_world/2023_08_13_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_13_02.sql rename to data/sql/archive/db_world/2023_08_13_02.sql diff --git a/data/sql/updates/db_world/2023_08_13_03.sql b/data/sql/archive/db_world/2023_08_13_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_13_03.sql rename to data/sql/archive/db_world/2023_08_13_03.sql diff --git a/data/sql/updates/db_world/2023_08_14_00.sql b/data/sql/archive/db_world/2023_08_14_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_14_00.sql rename to data/sql/archive/db_world/2023_08_14_00.sql diff --git a/data/sql/updates/db_world/2023_08_14_01.sql b/data/sql/archive/db_world/2023_08_14_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_14_01.sql rename to data/sql/archive/db_world/2023_08_14_01.sql diff --git a/data/sql/updates/db_world/2023_08_14_02.sql b/data/sql/archive/db_world/2023_08_14_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_14_02.sql rename to data/sql/archive/db_world/2023_08_14_02.sql diff --git a/data/sql/updates/db_world/2023_08_14_03.sql b/data/sql/archive/db_world/2023_08_14_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_14_03.sql rename to data/sql/archive/db_world/2023_08_14_03.sql diff --git a/data/sql/updates/db_world/2023_08_14_04.sql b/data/sql/archive/db_world/2023_08_14_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_14_04.sql rename to data/sql/archive/db_world/2023_08_14_04.sql diff --git a/data/sql/updates/db_world/2023_08_19_00.sql b/data/sql/archive/db_world/2023_08_19_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_19_00.sql rename to data/sql/archive/db_world/2023_08_19_00.sql diff --git a/data/sql/updates/db_world/2023_08_19_01.sql b/data/sql/archive/db_world/2023_08_19_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_19_01.sql rename to data/sql/archive/db_world/2023_08_19_01.sql diff --git a/data/sql/updates/db_world/2023_08_19_02.sql b/data/sql/archive/db_world/2023_08_19_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_19_02.sql rename to data/sql/archive/db_world/2023_08_19_02.sql diff --git a/data/sql/updates/db_world/2023_08_20_00.sql b/data/sql/archive/db_world/2023_08_20_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_20_00.sql rename to data/sql/archive/db_world/2023_08_20_00.sql diff --git a/data/sql/updates/db_world/2023_08_21_00.sql b/data/sql/archive/db_world/2023_08_21_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_21_00.sql rename to data/sql/archive/db_world/2023_08_21_00.sql diff --git a/data/sql/updates/db_world/2023_08_21_01.sql b/data/sql/archive/db_world/2023_08_21_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_21_01.sql rename to data/sql/archive/db_world/2023_08_21_01.sql diff --git a/data/sql/updates/db_world/2023_08_23_00.sql b/data/sql/archive/db_world/2023_08_23_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_23_00.sql rename to data/sql/archive/db_world/2023_08_23_00.sql diff --git a/data/sql/updates/db_world/2023_08_23_01.sql b/data/sql/archive/db_world/2023_08_23_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_23_01.sql rename to data/sql/archive/db_world/2023_08_23_01.sql diff --git a/data/sql/updates/db_world/2023_08_24_00.sql b/data/sql/archive/db_world/2023_08_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_24_00.sql rename to data/sql/archive/db_world/2023_08_24_00.sql diff --git a/data/sql/updates/db_world/2023_08_24_01.sql b/data/sql/archive/db_world/2023_08_24_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_24_01.sql rename to data/sql/archive/db_world/2023_08_24_01.sql diff --git a/data/sql/updates/db_world/2023_08_24_02.sql b/data/sql/archive/db_world/2023_08_24_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_24_02.sql rename to data/sql/archive/db_world/2023_08_24_02.sql diff --git a/data/sql/updates/db_world/2023_08_25_00.sql b/data/sql/archive/db_world/2023_08_25_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_25_00.sql rename to data/sql/archive/db_world/2023_08_25_00.sql diff --git a/data/sql/updates/db_world/2023_08_25_01.sql b/data/sql/archive/db_world/2023_08_25_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_25_01.sql rename to data/sql/archive/db_world/2023_08_25_01.sql diff --git a/data/sql/updates/db_world/2023_08_25_02.sql b/data/sql/archive/db_world/2023_08_25_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_25_02.sql rename to data/sql/archive/db_world/2023_08_25_02.sql diff --git a/data/sql/updates/db_world/2023_08_30_00.sql b/data/sql/archive/db_world/2023_08_30_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_08_30_00.sql rename to data/sql/archive/db_world/2023_08_30_00.sql diff --git a/data/sql/updates/db_world/2023_09_04_00.sql b/data/sql/archive/db_world/2023_09_04_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_04_00.sql rename to data/sql/archive/db_world/2023_09_04_00.sql diff --git a/data/sql/updates/db_world/2023_09_04_01.sql b/data/sql/archive/db_world/2023_09_04_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_04_01.sql rename to data/sql/archive/db_world/2023_09_04_01.sql diff --git a/data/sql/updates/db_world/2023_09_04_02.sql b/data/sql/archive/db_world/2023_09_04_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_04_02.sql rename to data/sql/archive/db_world/2023_09_04_02.sql diff --git a/data/sql/updates/db_world/2023_09_05_00.sql b/data/sql/archive/db_world/2023_09_05_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_05_00.sql rename to data/sql/archive/db_world/2023_09_05_00.sql diff --git a/data/sql/updates/db_world/2023_09_10_00.sql b/data/sql/archive/db_world/2023_09_10_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_10_00.sql rename to data/sql/archive/db_world/2023_09_10_00.sql diff --git a/data/sql/updates/db_world/2023_09_10_01.sql b/data/sql/archive/db_world/2023_09_10_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_10_01.sql rename to data/sql/archive/db_world/2023_09_10_01.sql diff --git a/data/sql/updates/db_world/2023_09_11_00.sql b/data/sql/archive/db_world/2023_09_11_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_11_00.sql rename to data/sql/archive/db_world/2023_09_11_00.sql diff --git a/data/sql/updates/db_world/2023_09_13_00.sql b/data/sql/archive/db_world/2023_09_13_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_13_00.sql rename to data/sql/archive/db_world/2023_09_13_00.sql diff --git a/data/sql/updates/db_world/2023_09_14_00.sql b/data/sql/archive/db_world/2023_09_14_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_14_00.sql rename to data/sql/archive/db_world/2023_09_14_00.sql diff --git a/data/sql/updates/db_world/2023_09_14_01.sql b/data/sql/archive/db_world/2023_09_14_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_14_01.sql rename to data/sql/archive/db_world/2023_09_14_01.sql diff --git a/data/sql/updates/db_world/2023_09_15_00.sql b/data/sql/archive/db_world/2023_09_15_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_15_00.sql rename to data/sql/archive/db_world/2023_09_15_00.sql diff --git a/data/sql/updates/db_world/2023_09_15_01.sql b/data/sql/archive/db_world/2023_09_15_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_15_01.sql rename to data/sql/archive/db_world/2023_09_15_01.sql diff --git a/data/sql/updates/db_world/2023_09_15_02.sql b/data/sql/archive/db_world/2023_09_15_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_15_02.sql rename to data/sql/archive/db_world/2023_09_15_02.sql diff --git a/data/sql/updates/db_world/2023_09_17_00.sql b/data/sql/archive/db_world/2023_09_17_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_00.sql rename to data/sql/archive/db_world/2023_09_17_00.sql diff --git a/data/sql/updates/db_world/2023_09_17_01.sql b/data/sql/archive/db_world/2023_09_17_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_01.sql rename to data/sql/archive/db_world/2023_09_17_01.sql diff --git a/data/sql/updates/db_world/2023_09_17_02.sql b/data/sql/archive/db_world/2023_09_17_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_02.sql rename to data/sql/archive/db_world/2023_09_17_02.sql diff --git a/data/sql/updates/db_world/2023_09_17_03.sql b/data/sql/archive/db_world/2023_09_17_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_03.sql rename to data/sql/archive/db_world/2023_09_17_03.sql diff --git a/data/sql/updates/db_world/2023_09_17_04.sql b/data/sql/archive/db_world/2023_09_17_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_04.sql rename to data/sql/archive/db_world/2023_09_17_04.sql diff --git a/data/sql/updates/db_world/2023_09_17_05.sql b/data/sql/archive/db_world/2023_09_17_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_05.sql rename to data/sql/archive/db_world/2023_09_17_05.sql diff --git a/data/sql/updates/db_world/2023_09_17_06.sql b/data/sql/archive/db_world/2023_09_17_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_06.sql rename to data/sql/archive/db_world/2023_09_17_06.sql diff --git a/data/sql/updates/db_world/2023_09_17_07.sql b/data/sql/archive/db_world/2023_09_17_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_07.sql rename to data/sql/archive/db_world/2023_09_17_07.sql diff --git a/data/sql/updates/db_world/2023_09_17_08.sql b/data/sql/archive/db_world/2023_09_17_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_08.sql rename to data/sql/archive/db_world/2023_09_17_08.sql diff --git a/data/sql/updates/db_world/2023_09_17_09.sql b/data/sql/archive/db_world/2023_09_17_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_09.sql rename to data/sql/archive/db_world/2023_09_17_09.sql diff --git a/data/sql/updates/db_world/2023_09_17_10.sql b/data/sql/archive/db_world/2023_09_17_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_10.sql rename to data/sql/archive/db_world/2023_09_17_10.sql diff --git a/data/sql/updates/db_world/2023_09_17_11.sql b/data/sql/archive/db_world/2023_09_17_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_11.sql rename to data/sql/archive/db_world/2023_09_17_11.sql diff --git a/data/sql/updates/db_world/2023_09_17_12.sql b/data/sql/archive/db_world/2023_09_17_12.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_12.sql rename to data/sql/archive/db_world/2023_09_17_12.sql diff --git a/data/sql/updates/db_world/2023_09_17_13.sql b/data/sql/archive/db_world/2023_09_17_13.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_17_13.sql rename to data/sql/archive/db_world/2023_09_17_13.sql diff --git a/data/sql/updates/db_world/2023_09_18_00.sql b/data/sql/archive/db_world/2023_09_18_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_18_00.sql rename to data/sql/archive/db_world/2023_09_18_00.sql diff --git a/data/sql/updates/db_world/2023_09_18_01.sql b/data/sql/archive/db_world/2023_09_18_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_18_01.sql rename to data/sql/archive/db_world/2023_09_18_01.sql diff --git a/data/sql/updates/db_world/2023_09_18_02.sql b/data/sql/archive/db_world/2023_09_18_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_18_02.sql rename to data/sql/archive/db_world/2023_09_18_02.sql diff --git a/data/sql/updates/db_world/2023_09_18_03.sql b/data/sql/archive/db_world/2023_09_18_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_18_03.sql rename to data/sql/archive/db_world/2023_09_18_03.sql diff --git a/data/sql/updates/db_world/2023_09_18_04.sql b/data/sql/archive/db_world/2023_09_18_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_18_04.sql rename to data/sql/archive/db_world/2023_09_18_04.sql diff --git a/data/sql/updates/db_world/2023_09_19_00.sql b/data/sql/archive/db_world/2023_09_19_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_19_00.sql rename to data/sql/archive/db_world/2023_09_19_00.sql diff --git a/data/sql/updates/db_world/2023_09_19_01.sql b/data/sql/archive/db_world/2023_09_19_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_19_01.sql rename to data/sql/archive/db_world/2023_09_19_01.sql diff --git a/data/sql/updates/db_world/2023_09_20_00.sql b/data/sql/archive/db_world/2023_09_20_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_00.sql rename to data/sql/archive/db_world/2023_09_20_00.sql diff --git a/data/sql/updates/db_world/2023_09_20_01.sql b/data/sql/archive/db_world/2023_09_20_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_01.sql rename to data/sql/archive/db_world/2023_09_20_01.sql diff --git a/data/sql/updates/db_world/2023_09_20_02.sql b/data/sql/archive/db_world/2023_09_20_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_02.sql rename to data/sql/archive/db_world/2023_09_20_02.sql diff --git a/data/sql/updates/db_world/2023_09_20_03.sql b/data/sql/archive/db_world/2023_09_20_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_03.sql rename to data/sql/archive/db_world/2023_09_20_03.sql diff --git a/data/sql/updates/db_world/2023_09_20_04.sql b/data/sql/archive/db_world/2023_09_20_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_04.sql rename to data/sql/archive/db_world/2023_09_20_04.sql diff --git a/data/sql/updates/db_world/2023_09_20_05.sql b/data/sql/archive/db_world/2023_09_20_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_05.sql rename to data/sql/archive/db_world/2023_09_20_05.sql diff --git a/data/sql/updates/db_world/2023_09_20_06.sql b/data/sql/archive/db_world/2023_09_20_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_06.sql rename to data/sql/archive/db_world/2023_09_20_06.sql diff --git a/data/sql/updates/db_world/2023_09_20_07.sql b/data/sql/archive/db_world/2023_09_20_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_20_07.sql rename to data/sql/archive/db_world/2023_09_20_07.sql diff --git a/data/sql/updates/db_world/2023_09_24_00.sql b/data/sql/archive/db_world/2023_09_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_24_00.sql rename to data/sql/archive/db_world/2023_09_24_00.sql diff --git a/data/sql/updates/db_world/2023_09_24_01.sql b/data/sql/archive/db_world/2023_09_24_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_24_01.sql rename to data/sql/archive/db_world/2023_09_24_01.sql diff --git a/data/sql/updates/db_world/2023_09_24_02.sql b/data/sql/archive/db_world/2023_09_24_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_24_02.sql rename to data/sql/archive/db_world/2023_09_24_02.sql diff --git a/data/sql/updates/db_world/2023_09_25_00.sql b/data/sql/archive/db_world/2023_09_25_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_00.sql rename to data/sql/archive/db_world/2023_09_25_00.sql diff --git a/data/sql/updates/db_world/2023_09_25_01.sql b/data/sql/archive/db_world/2023_09_25_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_01.sql rename to data/sql/archive/db_world/2023_09_25_01.sql diff --git a/data/sql/updates/db_world/2023_09_25_02.sql b/data/sql/archive/db_world/2023_09_25_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_02.sql rename to data/sql/archive/db_world/2023_09_25_02.sql diff --git a/data/sql/updates/db_world/2023_09_25_03.sql b/data/sql/archive/db_world/2023_09_25_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_03.sql rename to data/sql/archive/db_world/2023_09_25_03.sql diff --git a/data/sql/updates/db_world/2023_09_25_04.sql b/data/sql/archive/db_world/2023_09_25_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_04.sql rename to data/sql/archive/db_world/2023_09_25_04.sql diff --git a/data/sql/updates/db_world/2023_09_25_05.sql b/data/sql/archive/db_world/2023_09_25_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_05.sql rename to data/sql/archive/db_world/2023_09_25_05.sql diff --git a/data/sql/updates/db_world/2023_09_25_06.sql b/data/sql/archive/db_world/2023_09_25_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_06.sql rename to data/sql/archive/db_world/2023_09_25_06.sql diff --git a/data/sql/updates/db_world/2023_09_25_07.sql b/data/sql/archive/db_world/2023_09_25_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_07.sql rename to data/sql/archive/db_world/2023_09_25_07.sql diff --git a/data/sql/updates/db_world/2023_09_25_08.sql b/data/sql/archive/db_world/2023_09_25_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_25_08.sql rename to data/sql/archive/db_world/2023_09_25_08.sql diff --git a/data/sql/updates/db_world/2023_09_26_00.sql b/data/sql/archive/db_world/2023_09_26_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_26_00.sql rename to data/sql/archive/db_world/2023_09_26_00.sql diff --git a/data/sql/updates/db_world/2023_09_26_01.sql b/data/sql/archive/db_world/2023_09_26_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_26_01.sql rename to data/sql/archive/db_world/2023_09_26_01.sql diff --git a/data/sql/updates/db_world/2023_09_26_02.sql b/data/sql/archive/db_world/2023_09_26_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_26_02.sql rename to data/sql/archive/db_world/2023_09_26_02.sql diff --git a/data/sql/updates/db_world/2023_09_26_03.sql b/data/sql/archive/db_world/2023_09_26_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_26_03.sql rename to data/sql/archive/db_world/2023_09_26_03.sql diff --git a/data/sql/updates/db_world/2023_09_27_00.sql b/data/sql/archive/db_world/2023_09_27_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_27_00.sql rename to data/sql/archive/db_world/2023_09_27_00.sql diff --git a/data/sql/updates/db_world/2023_09_27_01.sql b/data/sql/archive/db_world/2023_09_27_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_27_01.sql rename to data/sql/archive/db_world/2023_09_27_01.sql diff --git a/data/sql/updates/db_world/2023_09_27_02.sql b/data/sql/archive/db_world/2023_09_27_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_27_02.sql rename to data/sql/archive/db_world/2023_09_27_02.sql diff --git a/data/sql/updates/db_world/2023_09_29_00.sql b/data/sql/archive/db_world/2023_09_29_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_09_29_00.sql rename to data/sql/archive/db_world/2023_09_29_00.sql diff --git a/data/sql/updates/db_world/2023_10_01_00.sql b/data/sql/archive/db_world/2023_10_01_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_01_00.sql rename to data/sql/archive/db_world/2023_10_01_00.sql diff --git a/data/sql/updates/db_world/2023_10_01_01.sql b/data/sql/archive/db_world/2023_10_01_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_01_01.sql rename to data/sql/archive/db_world/2023_10_01_01.sql diff --git a/data/sql/updates/db_world/2023_10_01_02.sql b/data/sql/archive/db_world/2023_10_01_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_01_02.sql rename to data/sql/archive/db_world/2023_10_01_02.sql diff --git a/data/sql/updates/db_world/2023_10_01_03.sql b/data/sql/archive/db_world/2023_10_01_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_01_03.sql rename to data/sql/archive/db_world/2023_10_01_03.sql diff --git a/data/sql/updates/db_world/2023_10_01_04.sql b/data/sql/archive/db_world/2023_10_01_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_01_04.sql rename to data/sql/archive/db_world/2023_10_01_04.sql diff --git a/data/sql/updates/db_world/2023_10_05_00.sql b/data/sql/archive/db_world/2023_10_05_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_05_00.sql rename to data/sql/archive/db_world/2023_10_05_00.sql diff --git a/data/sql/updates/db_world/2023_10_07_00.sql b/data/sql/archive/db_world/2023_10_07_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_07_00.sql rename to data/sql/archive/db_world/2023_10_07_00.sql diff --git a/data/sql/updates/db_world/2023_10_07_01.sql b/data/sql/archive/db_world/2023_10_07_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_07_01.sql rename to data/sql/archive/db_world/2023_10_07_01.sql diff --git a/data/sql/updates/db_world/2023_10_07_02.sql b/data/sql/archive/db_world/2023_10_07_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_07_02.sql rename to data/sql/archive/db_world/2023_10_07_02.sql diff --git a/data/sql/updates/db_world/2023_10_08_00.sql b/data/sql/archive/db_world/2023_10_08_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_00.sql rename to data/sql/archive/db_world/2023_10_08_00.sql diff --git a/data/sql/updates/db_world/2023_10_08_01.sql b/data/sql/archive/db_world/2023_10_08_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_01.sql rename to data/sql/archive/db_world/2023_10_08_01.sql diff --git a/data/sql/updates/db_world/2023_10_08_02.sql b/data/sql/archive/db_world/2023_10_08_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_02.sql rename to data/sql/archive/db_world/2023_10_08_02.sql diff --git a/data/sql/updates/db_world/2023_10_08_03.sql b/data/sql/archive/db_world/2023_10_08_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_03.sql rename to data/sql/archive/db_world/2023_10_08_03.sql diff --git a/data/sql/updates/db_world/2023_10_08_04.sql b/data/sql/archive/db_world/2023_10_08_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_04.sql rename to data/sql/archive/db_world/2023_10_08_04.sql diff --git a/data/sql/updates/db_world/2023_10_08_05.sql b/data/sql/archive/db_world/2023_10_08_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_05.sql rename to data/sql/archive/db_world/2023_10_08_05.sql diff --git a/data/sql/updates/db_world/2023_10_08_06.sql b/data/sql/archive/db_world/2023_10_08_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_06.sql rename to data/sql/archive/db_world/2023_10_08_06.sql diff --git a/data/sql/updates/db_world/2023_10_08_07.sql b/data/sql/archive/db_world/2023_10_08_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_07.sql rename to data/sql/archive/db_world/2023_10_08_07.sql diff --git a/data/sql/updates/db_world/2023_10_08_08.sql b/data/sql/archive/db_world/2023_10_08_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_08_08.sql rename to data/sql/archive/db_world/2023_10_08_08.sql diff --git a/data/sql/updates/db_world/2023_10_10_00.sql b/data/sql/archive/db_world/2023_10_10_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_00.sql rename to data/sql/archive/db_world/2023_10_10_00.sql diff --git a/data/sql/updates/db_world/2023_10_10_01.sql b/data/sql/archive/db_world/2023_10_10_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_01.sql rename to data/sql/archive/db_world/2023_10_10_01.sql diff --git a/data/sql/updates/db_world/2023_10_10_02.sql b/data/sql/archive/db_world/2023_10_10_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_02.sql rename to data/sql/archive/db_world/2023_10_10_02.sql diff --git a/data/sql/updates/db_world/2023_10_10_03.sql b/data/sql/archive/db_world/2023_10_10_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_03.sql rename to data/sql/archive/db_world/2023_10_10_03.sql diff --git a/data/sql/updates/db_world/2023_10_10_04.sql b/data/sql/archive/db_world/2023_10_10_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_04.sql rename to data/sql/archive/db_world/2023_10_10_04.sql diff --git a/data/sql/updates/db_world/2023_10_10_05.sql b/data/sql/archive/db_world/2023_10_10_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_05.sql rename to data/sql/archive/db_world/2023_10_10_05.sql diff --git a/data/sql/updates/db_world/2023_10_10_06.sql b/data/sql/archive/db_world/2023_10_10_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_06.sql rename to data/sql/archive/db_world/2023_10_10_06.sql diff --git a/data/sql/updates/db_world/2023_10_10_07.sql b/data/sql/archive/db_world/2023_10_10_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_07.sql rename to data/sql/archive/db_world/2023_10_10_07.sql diff --git a/data/sql/updates/db_world/2023_10_10_08.sql b/data/sql/archive/db_world/2023_10_10_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_08.sql rename to data/sql/archive/db_world/2023_10_10_08.sql diff --git a/data/sql/updates/db_world/2023_10_10_09.sql b/data/sql/archive/db_world/2023_10_10_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_09.sql rename to data/sql/archive/db_world/2023_10_10_09.sql diff --git a/data/sql/updates/db_world/2023_10_10_10.sql b/data/sql/archive/db_world/2023_10_10_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_10.sql rename to data/sql/archive/db_world/2023_10_10_10.sql diff --git a/data/sql/updates/db_world/2023_10_10_11.sql b/data/sql/archive/db_world/2023_10_10_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_11.sql rename to data/sql/archive/db_world/2023_10_10_11.sql diff --git a/data/sql/updates/db_world/2023_10_10_12.sql b/data/sql/archive/db_world/2023_10_10_12.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_12.sql rename to data/sql/archive/db_world/2023_10_10_12.sql diff --git a/data/sql/updates/db_world/2023_10_10_13.sql b/data/sql/archive/db_world/2023_10_10_13.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_13.sql rename to data/sql/archive/db_world/2023_10_10_13.sql diff --git a/data/sql/updates/db_world/2023_10_10_14.sql b/data/sql/archive/db_world/2023_10_10_14.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_10_14.sql rename to data/sql/archive/db_world/2023_10_10_14.sql diff --git a/data/sql/updates/db_world/2023_10_11_00.sql b/data/sql/archive/db_world/2023_10_11_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_11_00.sql rename to data/sql/archive/db_world/2023_10_11_00.sql diff --git a/data/sql/updates/db_world/2023_10_11_01.sql b/data/sql/archive/db_world/2023_10_11_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_11_01.sql rename to data/sql/archive/db_world/2023_10_11_01.sql diff --git a/data/sql/updates/db_world/2023_10_12_00.sql b/data/sql/archive/db_world/2023_10_12_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_12_00.sql rename to data/sql/archive/db_world/2023_10_12_00.sql diff --git a/data/sql/updates/db_world/2023_10_12_01.sql b/data/sql/archive/db_world/2023_10_12_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_12_01.sql rename to data/sql/archive/db_world/2023_10_12_01.sql diff --git a/data/sql/updates/db_world/2023_10_12_02.sql b/data/sql/archive/db_world/2023_10_12_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_12_02.sql rename to data/sql/archive/db_world/2023_10_12_02.sql diff --git a/data/sql/updates/db_world/2023_10_12_03.sql b/data/sql/archive/db_world/2023_10_12_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_12_03.sql rename to data/sql/archive/db_world/2023_10_12_03.sql diff --git a/data/sql/updates/db_world/2023_10_12_04.sql b/data/sql/archive/db_world/2023_10_12_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_12_04.sql rename to data/sql/archive/db_world/2023_10_12_04.sql diff --git a/data/sql/updates/db_world/2023_10_15_00.sql b/data/sql/archive/db_world/2023_10_15_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_15_00.sql rename to data/sql/archive/db_world/2023_10_15_00.sql diff --git a/data/sql/updates/db_world/2023_10_16_00.sql b/data/sql/archive/db_world/2023_10_16_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_16_00.sql rename to data/sql/archive/db_world/2023_10_16_00.sql diff --git a/data/sql/updates/db_world/2023_10_16_01.sql b/data/sql/archive/db_world/2023_10_16_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_16_01.sql rename to data/sql/archive/db_world/2023_10_16_01.sql diff --git a/data/sql/updates/db_world/2023_10_16_02.sql b/data/sql/archive/db_world/2023_10_16_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_16_02.sql rename to data/sql/archive/db_world/2023_10_16_02.sql diff --git a/data/sql/updates/db_world/2023_10_16_03.sql b/data/sql/archive/db_world/2023_10_16_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_16_03.sql rename to data/sql/archive/db_world/2023_10_16_03.sql diff --git a/data/sql/updates/db_world/2023_10_16_04.sql b/data/sql/archive/db_world/2023_10_16_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_16_04.sql rename to data/sql/archive/db_world/2023_10_16_04.sql diff --git a/data/sql/updates/db_world/2023_10_17_00.sql b/data/sql/archive/db_world/2023_10_17_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_00.sql rename to data/sql/archive/db_world/2023_10_17_00.sql diff --git a/data/sql/updates/db_world/2023_10_17_01.sql b/data/sql/archive/db_world/2023_10_17_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_01.sql rename to data/sql/archive/db_world/2023_10_17_01.sql diff --git a/data/sql/updates/db_world/2023_10_17_02.sql b/data/sql/archive/db_world/2023_10_17_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_02.sql rename to data/sql/archive/db_world/2023_10_17_02.sql diff --git a/data/sql/updates/db_world/2023_10_17_03.sql b/data/sql/archive/db_world/2023_10_17_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_03.sql rename to data/sql/archive/db_world/2023_10_17_03.sql diff --git a/data/sql/updates/db_world/2023_10_17_04.sql b/data/sql/archive/db_world/2023_10_17_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_04.sql rename to data/sql/archive/db_world/2023_10_17_04.sql diff --git a/data/sql/updates/db_world/2023_10_17_05.sql b/data/sql/archive/db_world/2023_10_17_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_05.sql rename to data/sql/archive/db_world/2023_10_17_05.sql diff --git a/data/sql/updates/db_world/2023_10_17_06.sql b/data/sql/archive/db_world/2023_10_17_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_06.sql rename to data/sql/archive/db_world/2023_10_17_06.sql diff --git a/data/sql/updates/db_world/2023_10_17_07.sql b/data/sql/archive/db_world/2023_10_17_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_17_07.sql rename to data/sql/archive/db_world/2023_10_17_07.sql diff --git a/data/sql/updates/db_world/2023_10_18_00.sql b/data/sql/archive/db_world/2023_10_18_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_18_00.sql rename to data/sql/archive/db_world/2023_10_18_00.sql diff --git a/data/sql/updates/db_world/2023_10_18_01.sql b/data/sql/archive/db_world/2023_10_18_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_18_01.sql rename to data/sql/archive/db_world/2023_10_18_01.sql diff --git a/data/sql/updates/db_world/2023_10_18_02.sql b/data/sql/archive/db_world/2023_10_18_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_18_02.sql rename to data/sql/archive/db_world/2023_10_18_02.sql diff --git a/data/sql/updates/db_world/2023_10_20_00.sql b/data/sql/archive/db_world/2023_10_20_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_20_00.sql rename to data/sql/archive/db_world/2023_10_20_00.sql diff --git a/data/sql/updates/db_world/2023_10_20_01.sql b/data/sql/archive/db_world/2023_10_20_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_20_01.sql rename to data/sql/archive/db_world/2023_10_20_01.sql diff --git a/data/sql/updates/db_world/2023_10_20_02.sql b/data/sql/archive/db_world/2023_10_20_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_20_02.sql rename to data/sql/archive/db_world/2023_10_20_02.sql diff --git a/data/sql/updates/db_world/2023_10_20_03.sql b/data/sql/archive/db_world/2023_10_20_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_20_03.sql rename to data/sql/archive/db_world/2023_10_20_03.sql diff --git a/data/sql/updates/db_world/2023_10_20_04.sql b/data/sql/archive/db_world/2023_10_20_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_20_04.sql rename to data/sql/archive/db_world/2023_10_20_04.sql diff --git a/data/sql/updates/db_world/2023_10_20_05.sql b/data/sql/archive/db_world/2023_10_20_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_20_05.sql rename to data/sql/archive/db_world/2023_10_20_05.sql diff --git a/data/sql/updates/db_world/2023_10_21_00.sql b/data/sql/archive/db_world/2023_10_21_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_21_00.sql rename to data/sql/archive/db_world/2023_10_21_00.sql diff --git a/data/sql/updates/db_world/2023_10_21_01.sql b/data/sql/archive/db_world/2023_10_21_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_21_01.sql rename to data/sql/archive/db_world/2023_10_21_01.sql diff --git a/data/sql/updates/db_world/2023_10_21_02.sql b/data/sql/archive/db_world/2023_10_21_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_21_02.sql rename to data/sql/archive/db_world/2023_10_21_02.sql diff --git a/data/sql/updates/db_world/2023_10_21_03.sql b/data/sql/archive/db_world/2023_10_21_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_21_03.sql rename to data/sql/archive/db_world/2023_10_21_03.sql diff --git a/data/sql/updates/db_world/2023_10_21_04.sql b/data/sql/archive/db_world/2023_10_21_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_21_04.sql rename to data/sql/archive/db_world/2023_10_21_04.sql diff --git a/data/sql/updates/db_world/2023_10_21_05.sql b/data/sql/archive/db_world/2023_10_21_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_21_05.sql rename to data/sql/archive/db_world/2023_10_21_05.sql diff --git a/data/sql/updates/db_world/2023_10_21_06.sql b/data/sql/archive/db_world/2023_10_21_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_21_06.sql rename to data/sql/archive/db_world/2023_10_21_06.sql diff --git a/data/sql/updates/db_world/2023_10_22_00.sql b/data/sql/archive/db_world/2023_10_22_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_00.sql rename to data/sql/archive/db_world/2023_10_22_00.sql diff --git a/data/sql/updates/db_world/2023_10_22_01.sql b/data/sql/archive/db_world/2023_10_22_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_01.sql rename to data/sql/archive/db_world/2023_10_22_01.sql diff --git a/data/sql/updates/db_world/2023_10_22_02.sql b/data/sql/archive/db_world/2023_10_22_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_02.sql rename to data/sql/archive/db_world/2023_10_22_02.sql diff --git a/data/sql/updates/db_world/2023_10_22_03.sql b/data/sql/archive/db_world/2023_10_22_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_03.sql rename to data/sql/archive/db_world/2023_10_22_03.sql diff --git a/data/sql/updates/db_world/2023_10_22_04.sql b/data/sql/archive/db_world/2023_10_22_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_04.sql rename to data/sql/archive/db_world/2023_10_22_04.sql diff --git a/data/sql/updates/db_world/2023_10_22_05.sql b/data/sql/archive/db_world/2023_10_22_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_05.sql rename to data/sql/archive/db_world/2023_10_22_05.sql diff --git a/data/sql/updates/db_world/2023_10_22_06.sql b/data/sql/archive/db_world/2023_10_22_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_06.sql rename to data/sql/archive/db_world/2023_10_22_06.sql diff --git a/data/sql/updates/db_world/2023_10_22_07.sql b/data/sql/archive/db_world/2023_10_22_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_07.sql rename to data/sql/archive/db_world/2023_10_22_07.sql diff --git a/data/sql/updates/db_world/2023_10_22_08.sql b/data/sql/archive/db_world/2023_10_22_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_08.sql rename to data/sql/archive/db_world/2023_10_22_08.sql diff --git a/data/sql/updates/db_world/2023_10_22_09.sql b/data/sql/archive/db_world/2023_10_22_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_22_09.sql rename to data/sql/archive/db_world/2023_10_22_09.sql diff --git a/data/sql/updates/db_world/2023_10_24_00.sql b/data/sql/archive/db_world/2023_10_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_24_00.sql rename to data/sql/archive/db_world/2023_10_24_00.sql diff --git a/data/sql/updates/db_world/2023_10_25_00.sql b/data/sql/archive/db_world/2023_10_25_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_25_00.sql rename to data/sql/archive/db_world/2023_10_25_00.sql diff --git a/data/sql/updates/db_world/2023_10_25_01.sql b/data/sql/archive/db_world/2023_10_25_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_25_01.sql rename to data/sql/archive/db_world/2023_10_25_01.sql diff --git a/data/sql/updates/db_world/2023_10_25_02.sql b/data/sql/archive/db_world/2023_10_25_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_25_02.sql rename to data/sql/archive/db_world/2023_10_25_02.sql diff --git a/data/sql/updates/db_world/2023_10_29_00.sql b/data/sql/archive/db_world/2023_10_29_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_29_00.sql rename to data/sql/archive/db_world/2023_10_29_00.sql diff --git a/data/sql/updates/db_world/2023_10_29_01.sql b/data/sql/archive/db_world/2023_10_29_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_29_01.sql rename to data/sql/archive/db_world/2023_10_29_01.sql diff --git a/data/sql/updates/db_world/2023_10_31_00.sql b/data/sql/archive/db_world/2023_10_31_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_31_00.sql rename to data/sql/archive/db_world/2023_10_31_00.sql diff --git a/data/sql/updates/db_world/2023_10_31_01.sql b/data/sql/archive/db_world/2023_10_31_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_31_01.sql rename to data/sql/archive/db_world/2023_10_31_01.sql diff --git a/data/sql/updates/db_world/2023_10_31_02.sql b/data/sql/archive/db_world/2023_10_31_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_10_31_02.sql rename to data/sql/archive/db_world/2023_10_31_02.sql diff --git a/data/sql/updates/db_world/2023_11_02_00.sql b/data/sql/archive/db_world/2023_11_02_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_02_00.sql rename to data/sql/archive/db_world/2023_11_02_00.sql diff --git a/data/sql/updates/db_world/2023_11_02_01.sql b/data/sql/archive/db_world/2023_11_02_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_02_01.sql rename to data/sql/archive/db_world/2023_11_02_01.sql diff --git a/data/sql/updates/db_world/2023_11_02_02.sql b/data/sql/archive/db_world/2023_11_02_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_02_02.sql rename to data/sql/archive/db_world/2023_11_02_02.sql diff --git a/data/sql/updates/db_world/2023_11_02_03.sql b/data/sql/archive/db_world/2023_11_02_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_02_03.sql rename to data/sql/archive/db_world/2023_11_02_03.sql diff --git a/data/sql/updates/db_world/2023_11_05_00.sql b/data/sql/archive/db_world/2023_11_05_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_05_00.sql rename to data/sql/archive/db_world/2023_11_05_00.sql diff --git a/data/sql/updates/db_world/2023_11_07_00.sql b/data/sql/archive/db_world/2023_11_07_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_07_00.sql rename to data/sql/archive/db_world/2023_11_07_00.sql diff --git a/data/sql/updates/db_world/2023_11_07_01.sql b/data/sql/archive/db_world/2023_11_07_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_07_01.sql rename to data/sql/archive/db_world/2023_11_07_01.sql diff --git a/data/sql/updates/db_world/2023_11_07_02.sql b/data/sql/archive/db_world/2023_11_07_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_07_02.sql rename to data/sql/archive/db_world/2023_11_07_02.sql diff --git a/data/sql/updates/db_world/2023_11_07_03.sql b/data/sql/archive/db_world/2023_11_07_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_07_03.sql rename to data/sql/archive/db_world/2023_11_07_03.sql diff --git a/data/sql/updates/db_world/2023_11_08_00.sql b/data/sql/archive/db_world/2023_11_08_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_00.sql rename to data/sql/archive/db_world/2023_11_08_00.sql diff --git a/data/sql/updates/db_world/2023_11_08_01.sql b/data/sql/archive/db_world/2023_11_08_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_01.sql rename to data/sql/archive/db_world/2023_11_08_01.sql diff --git a/data/sql/updates/db_world/2023_11_08_02.sql b/data/sql/archive/db_world/2023_11_08_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_02.sql rename to data/sql/archive/db_world/2023_11_08_02.sql diff --git a/data/sql/updates/db_world/2023_11_08_03.sql b/data/sql/archive/db_world/2023_11_08_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_03.sql rename to data/sql/archive/db_world/2023_11_08_03.sql diff --git a/data/sql/updates/db_world/2023_11_08_04.sql b/data/sql/archive/db_world/2023_11_08_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_04.sql rename to data/sql/archive/db_world/2023_11_08_04.sql diff --git a/data/sql/updates/db_world/2023_11_08_05.sql b/data/sql/archive/db_world/2023_11_08_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_05.sql rename to data/sql/archive/db_world/2023_11_08_05.sql diff --git a/data/sql/updates/db_world/2023_11_08_06.sql b/data/sql/archive/db_world/2023_11_08_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_06.sql rename to data/sql/archive/db_world/2023_11_08_06.sql diff --git a/data/sql/updates/db_world/2023_11_08_07.sql b/data/sql/archive/db_world/2023_11_08_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_08_07.sql rename to data/sql/archive/db_world/2023_11_08_07.sql diff --git a/data/sql/updates/db_world/2023_11_09_00.sql b/data/sql/archive/db_world/2023_11_09_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_09_00.sql rename to data/sql/archive/db_world/2023_11_09_00.sql diff --git a/data/sql/updates/db_world/2023_11_10_00.sql b/data/sql/archive/db_world/2023_11_10_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_10_00.sql rename to data/sql/archive/db_world/2023_11_10_00.sql diff --git a/data/sql/updates/db_world/2023_11_10_01.sql b/data/sql/archive/db_world/2023_11_10_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_10_01.sql rename to data/sql/archive/db_world/2023_11_10_01.sql diff --git a/data/sql/updates/db_world/2023_11_10_02.sql b/data/sql/archive/db_world/2023_11_10_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_10_02.sql rename to data/sql/archive/db_world/2023_11_10_02.sql diff --git a/data/sql/updates/db_world/2023_11_11_00.sql b/data/sql/archive/db_world/2023_11_11_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_11_00.sql rename to data/sql/archive/db_world/2023_11_11_00.sql diff --git a/data/sql/updates/db_world/2023_11_11_01.sql b/data/sql/archive/db_world/2023_11_11_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_11_01.sql rename to data/sql/archive/db_world/2023_11_11_01.sql diff --git a/data/sql/updates/db_world/2023_11_11_02.sql b/data/sql/archive/db_world/2023_11_11_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_11_02.sql rename to data/sql/archive/db_world/2023_11_11_02.sql diff --git a/data/sql/updates/db_world/2023_11_11_03.sql b/data/sql/archive/db_world/2023_11_11_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_11_03.sql rename to data/sql/archive/db_world/2023_11_11_03.sql diff --git a/data/sql/updates/db_world/2023_11_11_04.sql b/data/sql/archive/db_world/2023_11_11_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_11_04.sql rename to data/sql/archive/db_world/2023_11_11_04.sql diff --git a/data/sql/updates/db_world/2023_11_12_00.sql b/data/sql/archive/db_world/2023_11_12_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_00.sql rename to data/sql/archive/db_world/2023_11_12_00.sql diff --git a/data/sql/updates/db_world/2023_11_12_01.sql b/data/sql/archive/db_world/2023_11_12_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_01.sql rename to data/sql/archive/db_world/2023_11_12_01.sql diff --git a/data/sql/updates/db_world/2023_11_12_02.sql b/data/sql/archive/db_world/2023_11_12_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_02.sql rename to data/sql/archive/db_world/2023_11_12_02.sql diff --git a/data/sql/updates/db_world/2023_11_12_03.sql b/data/sql/archive/db_world/2023_11_12_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_03.sql rename to data/sql/archive/db_world/2023_11_12_03.sql diff --git a/data/sql/updates/db_world/2023_11_12_04.sql b/data/sql/archive/db_world/2023_11_12_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_04.sql rename to data/sql/archive/db_world/2023_11_12_04.sql diff --git a/data/sql/updates/db_world/2023_11_12_05.sql b/data/sql/archive/db_world/2023_11_12_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_05.sql rename to data/sql/archive/db_world/2023_11_12_05.sql diff --git a/data/sql/updates/db_world/2023_11_12_06.sql b/data/sql/archive/db_world/2023_11_12_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_06.sql rename to data/sql/archive/db_world/2023_11_12_06.sql diff --git a/data/sql/updates/db_world/2023_11_12_07.sql b/data/sql/archive/db_world/2023_11_12_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_07.sql rename to data/sql/archive/db_world/2023_11_12_07.sql diff --git a/data/sql/updates/db_world/2023_11_12_08.sql b/data/sql/archive/db_world/2023_11_12_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_08.sql rename to data/sql/archive/db_world/2023_11_12_08.sql diff --git a/data/sql/updates/db_world/2023_11_12_09.sql b/data/sql/archive/db_world/2023_11_12_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_12_09.sql rename to data/sql/archive/db_world/2023_11_12_09.sql diff --git a/data/sql/updates/db_world/2023_11_13_00.sql b/data/sql/archive/db_world/2023_11_13_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_13_00.sql rename to data/sql/archive/db_world/2023_11_13_00.sql diff --git a/data/sql/updates/db_world/2023_11_14_00.sql b/data/sql/archive/db_world/2023_11_14_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_14_00.sql rename to data/sql/archive/db_world/2023_11_14_00.sql diff --git a/data/sql/updates/db_world/2023_11_14_01.sql b/data/sql/archive/db_world/2023_11_14_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_14_01.sql rename to data/sql/archive/db_world/2023_11_14_01.sql diff --git a/data/sql/updates/db_world/2023_11_14_02.sql b/data/sql/archive/db_world/2023_11_14_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_14_02.sql rename to data/sql/archive/db_world/2023_11_14_02.sql diff --git a/data/sql/updates/db_world/2023_11_15_00.sql b/data/sql/archive/db_world/2023_11_15_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_15_00.sql rename to data/sql/archive/db_world/2023_11_15_00.sql diff --git a/data/sql/updates/db_world/2023_11_15_01.sql b/data/sql/archive/db_world/2023_11_15_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_15_01.sql rename to data/sql/archive/db_world/2023_11_15_01.sql diff --git a/data/sql/updates/db_world/2023_11_15_02.sql b/data/sql/archive/db_world/2023_11_15_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_15_02.sql rename to data/sql/archive/db_world/2023_11_15_02.sql diff --git a/data/sql/updates/db_world/2023_11_16_00.sql b/data/sql/archive/db_world/2023_11_16_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_00.sql rename to data/sql/archive/db_world/2023_11_16_00.sql diff --git a/data/sql/updates/db_world/2023_11_16_01.sql b/data/sql/archive/db_world/2023_11_16_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_01.sql rename to data/sql/archive/db_world/2023_11_16_01.sql diff --git a/data/sql/updates/db_world/2023_11_16_02.sql b/data/sql/archive/db_world/2023_11_16_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_02.sql rename to data/sql/archive/db_world/2023_11_16_02.sql diff --git a/data/sql/updates/db_world/2023_11_16_03.sql b/data/sql/archive/db_world/2023_11_16_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_03.sql rename to data/sql/archive/db_world/2023_11_16_03.sql diff --git a/data/sql/updates/db_world/2023_11_16_04.sql b/data/sql/archive/db_world/2023_11_16_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_04.sql rename to data/sql/archive/db_world/2023_11_16_04.sql diff --git a/data/sql/updates/db_world/2023_11_16_05.sql b/data/sql/archive/db_world/2023_11_16_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_05.sql rename to data/sql/archive/db_world/2023_11_16_05.sql diff --git a/data/sql/updates/db_world/2023_11_16_06.sql b/data/sql/archive/db_world/2023_11_16_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_06.sql rename to data/sql/archive/db_world/2023_11_16_06.sql diff --git a/data/sql/updates/db_world/2023_11_16_07.sql b/data/sql/archive/db_world/2023_11_16_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_07.sql rename to data/sql/archive/db_world/2023_11_16_07.sql diff --git a/data/sql/updates/db_world/2023_11_16_08.sql b/data/sql/archive/db_world/2023_11_16_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_08.sql rename to data/sql/archive/db_world/2023_11_16_08.sql diff --git a/data/sql/updates/db_world/2023_11_16_09.sql b/data/sql/archive/db_world/2023_11_16_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_09.sql rename to data/sql/archive/db_world/2023_11_16_09.sql diff --git a/data/sql/updates/db_world/2023_11_16_10.sql b/data/sql/archive/db_world/2023_11_16_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_16_10.sql rename to data/sql/archive/db_world/2023_11_16_10.sql diff --git a/data/sql/updates/db_world/2023_11_17_00.sql b/data/sql/archive/db_world/2023_11_17_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_17_00.sql rename to data/sql/archive/db_world/2023_11_17_00.sql diff --git a/data/sql/updates/db_world/2023_11_17_01.sql b/data/sql/archive/db_world/2023_11_17_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_17_01.sql rename to data/sql/archive/db_world/2023_11_17_01.sql diff --git a/data/sql/updates/db_world/2023_11_17_02.sql b/data/sql/archive/db_world/2023_11_17_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_17_02.sql rename to data/sql/archive/db_world/2023_11_17_02.sql diff --git a/data/sql/updates/db_world/2023_11_17_03.sql b/data/sql/archive/db_world/2023_11_17_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_17_03.sql rename to data/sql/archive/db_world/2023_11_17_03.sql diff --git a/data/sql/updates/db_world/2023_11_17_04.sql b/data/sql/archive/db_world/2023_11_17_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_17_04.sql rename to data/sql/archive/db_world/2023_11_17_04.sql diff --git a/data/sql/updates/db_world/2023_11_18_00.sql b/data/sql/archive/db_world/2023_11_18_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_00.sql rename to data/sql/archive/db_world/2023_11_18_00.sql diff --git a/data/sql/updates/db_world/2023_11_18_01.sql b/data/sql/archive/db_world/2023_11_18_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_01.sql rename to data/sql/archive/db_world/2023_11_18_01.sql diff --git a/data/sql/updates/db_world/2023_11_18_02.sql b/data/sql/archive/db_world/2023_11_18_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_02.sql rename to data/sql/archive/db_world/2023_11_18_02.sql diff --git a/data/sql/updates/db_world/2023_11_18_03.sql b/data/sql/archive/db_world/2023_11_18_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_03.sql rename to data/sql/archive/db_world/2023_11_18_03.sql diff --git a/data/sql/updates/db_world/2023_11_18_04.sql b/data/sql/archive/db_world/2023_11_18_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_04.sql rename to data/sql/archive/db_world/2023_11_18_04.sql diff --git a/data/sql/updates/db_world/2023_11_18_05.sql b/data/sql/archive/db_world/2023_11_18_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_05.sql rename to data/sql/archive/db_world/2023_11_18_05.sql diff --git a/data/sql/updates/db_world/2023_11_18_06.sql b/data/sql/archive/db_world/2023_11_18_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_06.sql rename to data/sql/archive/db_world/2023_11_18_06.sql diff --git a/data/sql/updates/db_world/2023_11_18_07.sql b/data/sql/archive/db_world/2023_11_18_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_07.sql rename to data/sql/archive/db_world/2023_11_18_07.sql diff --git a/data/sql/updates/db_world/2023_11_18_08.sql b/data/sql/archive/db_world/2023_11_18_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_08.sql rename to data/sql/archive/db_world/2023_11_18_08.sql diff --git a/data/sql/updates/db_world/2023_11_18_09.sql b/data/sql/archive/db_world/2023_11_18_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_09.sql rename to data/sql/archive/db_world/2023_11_18_09.sql diff --git a/data/sql/updates/db_world/2023_11_18_10.sql b/data/sql/archive/db_world/2023_11_18_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_10.sql rename to data/sql/archive/db_world/2023_11_18_10.sql diff --git a/data/sql/updates/db_world/2023_11_18_11.sql b/data/sql/archive/db_world/2023_11_18_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_11.sql rename to data/sql/archive/db_world/2023_11_18_11.sql diff --git a/data/sql/updates/db_world/2023_11_18_12.sql b/data/sql/archive/db_world/2023_11_18_12.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_12.sql rename to data/sql/archive/db_world/2023_11_18_12.sql diff --git a/data/sql/updates/db_world/2023_11_18_13.sql b/data/sql/archive/db_world/2023_11_18_13.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_13.sql rename to data/sql/archive/db_world/2023_11_18_13.sql diff --git a/data/sql/updates/db_world/2023_11_18_14.sql b/data/sql/archive/db_world/2023_11_18_14.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_14.sql rename to data/sql/archive/db_world/2023_11_18_14.sql diff --git a/data/sql/updates/db_world/2023_11_18_15.sql b/data/sql/archive/db_world/2023_11_18_15.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_15.sql rename to data/sql/archive/db_world/2023_11_18_15.sql diff --git a/data/sql/updates/db_world/2023_11_18_16.sql b/data/sql/archive/db_world/2023_11_18_16.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_16.sql rename to data/sql/archive/db_world/2023_11_18_16.sql diff --git a/data/sql/updates/db_world/2023_11_18_17.sql b/data/sql/archive/db_world/2023_11_18_17.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_17.sql rename to data/sql/archive/db_world/2023_11_18_17.sql diff --git a/data/sql/updates/db_world/2023_11_18_18.sql b/data/sql/archive/db_world/2023_11_18_18.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_18_18.sql rename to data/sql/archive/db_world/2023_11_18_18.sql diff --git a/data/sql/updates/db_world/2023_11_19_00.sql b/data/sql/archive/db_world/2023_11_19_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_19_00.sql rename to data/sql/archive/db_world/2023_11_19_00.sql diff --git a/data/sql/updates/db_world/2023_11_19_01.sql b/data/sql/archive/db_world/2023_11_19_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_19_01.sql rename to data/sql/archive/db_world/2023_11_19_01.sql diff --git a/data/sql/updates/db_world/2023_11_19_02.sql b/data/sql/archive/db_world/2023_11_19_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_19_02.sql rename to data/sql/archive/db_world/2023_11_19_02.sql diff --git a/data/sql/updates/db_world/2023_11_19_03.sql b/data/sql/archive/db_world/2023_11_19_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_19_03.sql rename to data/sql/archive/db_world/2023_11_19_03.sql diff --git a/data/sql/updates/db_world/2023_11_19_04.sql b/data/sql/archive/db_world/2023_11_19_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_19_04.sql rename to data/sql/archive/db_world/2023_11_19_04.sql diff --git a/data/sql/updates/db_world/2023_11_19_05.sql b/data/sql/archive/db_world/2023_11_19_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_19_05.sql rename to data/sql/archive/db_world/2023_11_19_05.sql diff --git a/data/sql/updates/db_world/2023_11_19_06.sql b/data/sql/archive/db_world/2023_11_19_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_19_06.sql rename to data/sql/archive/db_world/2023_11_19_06.sql diff --git a/data/sql/updates/db_world/2023_11_20_00.sql b/data/sql/archive/db_world/2023_11_20_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_00.sql rename to data/sql/archive/db_world/2023_11_20_00.sql diff --git a/data/sql/updates/db_world/2023_11_20_01.sql b/data/sql/archive/db_world/2023_11_20_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_01.sql rename to data/sql/archive/db_world/2023_11_20_01.sql diff --git a/data/sql/updates/db_world/2023_11_20_02.sql b/data/sql/archive/db_world/2023_11_20_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_02.sql rename to data/sql/archive/db_world/2023_11_20_02.sql diff --git a/data/sql/updates/db_world/2023_11_20_03.sql b/data/sql/archive/db_world/2023_11_20_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_03.sql rename to data/sql/archive/db_world/2023_11_20_03.sql diff --git a/data/sql/updates/db_world/2023_11_20_04.sql b/data/sql/archive/db_world/2023_11_20_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_04.sql rename to data/sql/archive/db_world/2023_11_20_04.sql diff --git a/data/sql/updates/db_world/2023_11_20_05.sql b/data/sql/archive/db_world/2023_11_20_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_05.sql rename to data/sql/archive/db_world/2023_11_20_05.sql diff --git a/data/sql/updates/db_world/2023_11_20_06.sql b/data/sql/archive/db_world/2023_11_20_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_06.sql rename to data/sql/archive/db_world/2023_11_20_06.sql diff --git a/data/sql/updates/db_world/2023_11_20_07.sql b/data/sql/archive/db_world/2023_11_20_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_07.sql rename to data/sql/archive/db_world/2023_11_20_07.sql diff --git a/data/sql/updates/db_world/2023_11_20_08.sql b/data/sql/archive/db_world/2023_11_20_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_08.sql rename to data/sql/archive/db_world/2023_11_20_08.sql diff --git a/data/sql/updates/db_world/2023_11_20_09.sql b/data/sql/archive/db_world/2023_11_20_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_20_09.sql rename to data/sql/archive/db_world/2023_11_20_09.sql diff --git a/data/sql/updates/db_world/2023_11_22_00.sql b/data/sql/archive/db_world/2023_11_22_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_22_00.sql rename to data/sql/archive/db_world/2023_11_22_00.sql diff --git a/data/sql/updates/db_world/2023_11_26_00.sql b/data/sql/archive/db_world/2023_11_26_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_00.sql rename to data/sql/archive/db_world/2023_11_26_00.sql diff --git a/data/sql/updates/db_world/2023_11_26_01.sql b/data/sql/archive/db_world/2023_11_26_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_01.sql rename to data/sql/archive/db_world/2023_11_26_01.sql diff --git a/data/sql/updates/db_world/2023_11_26_02.sql b/data/sql/archive/db_world/2023_11_26_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_02.sql rename to data/sql/archive/db_world/2023_11_26_02.sql diff --git a/data/sql/updates/db_world/2023_11_26_03.sql b/data/sql/archive/db_world/2023_11_26_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_03.sql rename to data/sql/archive/db_world/2023_11_26_03.sql diff --git a/data/sql/updates/db_world/2023_11_26_04.sql b/data/sql/archive/db_world/2023_11_26_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_04.sql rename to data/sql/archive/db_world/2023_11_26_04.sql diff --git a/data/sql/updates/db_world/2023_11_26_05.sql b/data/sql/archive/db_world/2023_11_26_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_05.sql rename to data/sql/archive/db_world/2023_11_26_05.sql diff --git a/data/sql/updates/db_world/2023_11_26_06.sql b/data/sql/archive/db_world/2023_11_26_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_06.sql rename to data/sql/archive/db_world/2023_11_26_06.sql diff --git a/data/sql/updates/db_world/2023_11_26_07.sql b/data/sql/archive/db_world/2023_11_26_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_07.sql rename to data/sql/archive/db_world/2023_11_26_07.sql diff --git a/data/sql/updates/db_world/2023_11_26_08.sql b/data/sql/archive/db_world/2023_11_26_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_08.sql rename to data/sql/archive/db_world/2023_11_26_08.sql diff --git a/data/sql/updates/db_world/2023_11_26_09.sql b/data/sql/archive/db_world/2023_11_26_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_09.sql rename to data/sql/archive/db_world/2023_11_26_09.sql diff --git a/data/sql/updates/db_world/2023_11_26_10.sql b/data/sql/archive/db_world/2023_11_26_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_10.sql rename to data/sql/archive/db_world/2023_11_26_10.sql diff --git a/data/sql/updates/db_world/2023_11_26_11.sql b/data/sql/archive/db_world/2023_11_26_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_11.sql rename to data/sql/archive/db_world/2023_11_26_11.sql diff --git a/data/sql/updates/db_world/2023_11_26_12.sql b/data/sql/archive/db_world/2023_11_26_12.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_12.sql rename to data/sql/archive/db_world/2023_11_26_12.sql diff --git a/data/sql/updates/db_world/2023_11_26_13.sql b/data/sql/archive/db_world/2023_11_26_13.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_13.sql rename to data/sql/archive/db_world/2023_11_26_13.sql diff --git a/data/sql/updates/db_world/2023_11_26_14.sql b/data/sql/archive/db_world/2023_11_26_14.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_26_14.sql rename to data/sql/archive/db_world/2023_11_26_14.sql diff --git a/data/sql/updates/db_world/2023_11_27_00.sql b/data/sql/archive/db_world/2023_11_27_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_27_00.sql rename to data/sql/archive/db_world/2023_11_27_00.sql diff --git a/data/sql/updates/db_world/2023_11_28_00.sql b/data/sql/archive/db_world/2023_11_28_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_28_00.sql rename to data/sql/archive/db_world/2023_11_28_00.sql diff --git a/data/sql/updates/db_world/2023_11_29_00.sql b/data/sql/archive/db_world/2023_11_29_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_29_00.sql rename to data/sql/archive/db_world/2023_11_29_00.sql diff --git a/data/sql/updates/db_world/2023_11_29_01.sql b/data/sql/archive/db_world/2023_11_29_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_29_01.sql rename to data/sql/archive/db_world/2023_11_29_01.sql diff --git a/data/sql/updates/db_world/2023_11_30_00.sql b/data/sql/archive/db_world/2023_11_30_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_11_30_00.sql rename to data/sql/archive/db_world/2023_11_30_00.sql diff --git a/data/sql/updates/db_world/2023_12_02_00.sql b/data/sql/archive/db_world/2023_12_02_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_02_00.sql rename to data/sql/archive/db_world/2023_12_02_00.sql diff --git a/data/sql/updates/db_world/2023_12_03_00.sql b/data/sql/archive/db_world/2023_12_03_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_00.sql rename to data/sql/archive/db_world/2023_12_03_00.sql diff --git a/data/sql/updates/db_world/2023_12_03_01.sql b/data/sql/archive/db_world/2023_12_03_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_01.sql rename to data/sql/archive/db_world/2023_12_03_01.sql diff --git a/data/sql/updates/db_world/2023_12_03_02.sql b/data/sql/archive/db_world/2023_12_03_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_02.sql rename to data/sql/archive/db_world/2023_12_03_02.sql diff --git a/data/sql/updates/db_world/2023_12_03_03.sql b/data/sql/archive/db_world/2023_12_03_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_03.sql rename to data/sql/archive/db_world/2023_12_03_03.sql diff --git a/data/sql/updates/db_world/2023_12_03_04.sql b/data/sql/archive/db_world/2023_12_03_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_04.sql rename to data/sql/archive/db_world/2023_12_03_04.sql diff --git a/data/sql/updates/db_world/2023_12_03_05.sql b/data/sql/archive/db_world/2023_12_03_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_05.sql rename to data/sql/archive/db_world/2023_12_03_05.sql diff --git a/data/sql/updates/db_world/2023_12_03_06.sql b/data/sql/archive/db_world/2023_12_03_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_06.sql rename to data/sql/archive/db_world/2023_12_03_06.sql diff --git a/data/sql/updates/db_world/2023_12_03_07.sql b/data/sql/archive/db_world/2023_12_03_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_03_07.sql rename to data/sql/archive/db_world/2023_12_03_07.sql diff --git a/data/sql/updates/db_world/2023_12_04_00.sql b/data/sql/archive/db_world/2023_12_04_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_04_00.sql rename to data/sql/archive/db_world/2023_12_04_00.sql diff --git a/data/sql/updates/db_world/2023_12_04_01.sql b/data/sql/archive/db_world/2023_12_04_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_04_01.sql rename to data/sql/archive/db_world/2023_12_04_01.sql diff --git a/data/sql/updates/db_world/2023_12_04_02.sql b/data/sql/archive/db_world/2023_12_04_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_04_02.sql rename to data/sql/archive/db_world/2023_12_04_02.sql diff --git a/data/sql/updates/db_world/2023_12_04_03.sql b/data/sql/archive/db_world/2023_12_04_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_04_03.sql rename to data/sql/archive/db_world/2023_12_04_03.sql diff --git a/data/sql/updates/db_world/2023_12_06_00.sql b/data/sql/archive/db_world/2023_12_06_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_06_00.sql rename to data/sql/archive/db_world/2023_12_06_00.sql diff --git a/data/sql/updates/db_world/2023_12_07_00.sql b/data/sql/archive/db_world/2023_12_07_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_07_00.sql rename to data/sql/archive/db_world/2023_12_07_00.sql diff --git a/data/sql/updates/db_world/2023_12_07_01.sql b/data/sql/archive/db_world/2023_12_07_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_07_01.sql rename to data/sql/archive/db_world/2023_12_07_01.sql diff --git a/data/sql/updates/db_world/2023_12_09_00.sql b/data/sql/archive/db_world/2023_12_09_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_09_00.sql rename to data/sql/archive/db_world/2023_12_09_00.sql diff --git a/data/sql/updates/db_world/2023_12_10_00.sql b/data/sql/archive/db_world/2023_12_10_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_10_00.sql rename to data/sql/archive/db_world/2023_12_10_00.sql diff --git a/data/sql/updates/db_world/2023_12_10_01.sql b/data/sql/archive/db_world/2023_12_10_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_10_01.sql rename to data/sql/archive/db_world/2023_12_10_01.sql diff --git a/data/sql/updates/db_world/2023_12_10_02.sql b/data/sql/archive/db_world/2023_12_10_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_10_02.sql rename to data/sql/archive/db_world/2023_12_10_02.sql diff --git a/data/sql/updates/db_world/2023_12_10_03.sql b/data/sql/archive/db_world/2023_12_10_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_10_03.sql rename to data/sql/archive/db_world/2023_12_10_03.sql diff --git a/data/sql/updates/db_world/2023_12_11_00.sql b/data/sql/archive/db_world/2023_12_11_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_11_00.sql rename to data/sql/archive/db_world/2023_12_11_00.sql diff --git a/data/sql/updates/db_world/2023_12_11_01.sql b/data/sql/archive/db_world/2023_12_11_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_11_01.sql rename to data/sql/archive/db_world/2023_12_11_01.sql diff --git a/data/sql/updates/db_world/2023_12_11_02.sql b/data/sql/archive/db_world/2023_12_11_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_11_02.sql rename to data/sql/archive/db_world/2023_12_11_02.sql diff --git a/data/sql/updates/db_world/2023_12_11_03.sql b/data/sql/archive/db_world/2023_12_11_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_11_03.sql rename to data/sql/archive/db_world/2023_12_11_03.sql diff --git a/data/sql/updates/db_world/2023_12_12_00.sql b/data/sql/archive/db_world/2023_12_12_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_00.sql rename to data/sql/archive/db_world/2023_12_12_00.sql diff --git a/data/sql/updates/db_world/2023_12_12_01.sql b/data/sql/archive/db_world/2023_12_12_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_01.sql rename to data/sql/archive/db_world/2023_12_12_01.sql diff --git a/data/sql/updates/db_world/2023_12_12_02.sql b/data/sql/archive/db_world/2023_12_12_02.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_02.sql rename to data/sql/archive/db_world/2023_12_12_02.sql diff --git a/data/sql/updates/db_world/2023_12_12_03.sql b/data/sql/archive/db_world/2023_12_12_03.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_03.sql rename to data/sql/archive/db_world/2023_12_12_03.sql diff --git a/data/sql/updates/db_world/2023_12_12_04.sql b/data/sql/archive/db_world/2023_12_12_04.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_04.sql rename to data/sql/archive/db_world/2023_12_12_04.sql diff --git a/data/sql/updates/db_world/2023_12_12_05.sql b/data/sql/archive/db_world/2023_12_12_05.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_05.sql rename to data/sql/archive/db_world/2023_12_12_05.sql diff --git a/data/sql/updates/db_world/2023_12_12_06.sql b/data/sql/archive/db_world/2023_12_12_06.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_06.sql rename to data/sql/archive/db_world/2023_12_12_06.sql diff --git a/data/sql/updates/db_world/2023_12_12_07.sql b/data/sql/archive/db_world/2023_12_12_07.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_07.sql rename to data/sql/archive/db_world/2023_12_12_07.sql diff --git a/data/sql/updates/db_world/2023_12_12_08.sql b/data/sql/archive/db_world/2023_12_12_08.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_08.sql rename to data/sql/archive/db_world/2023_12_12_08.sql diff --git a/data/sql/updates/db_world/2023_12_12_09.sql b/data/sql/archive/db_world/2023_12_12_09.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_09.sql rename to data/sql/archive/db_world/2023_12_12_09.sql diff --git a/data/sql/updates/db_world/2023_12_12_10.sql b/data/sql/archive/db_world/2023_12_12_10.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_10.sql rename to data/sql/archive/db_world/2023_12_12_10.sql diff --git a/data/sql/updates/db_world/2023_12_12_11.sql b/data/sql/archive/db_world/2023_12_12_11.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_11.sql rename to data/sql/archive/db_world/2023_12_12_11.sql diff --git a/data/sql/updates/db_world/2023_12_12_12.sql b/data/sql/archive/db_world/2023_12_12_12.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_12.sql rename to data/sql/archive/db_world/2023_12_12_12.sql diff --git a/data/sql/updates/db_world/2023_12_12_13.sql b/data/sql/archive/db_world/2023_12_12_13.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_13.sql rename to data/sql/archive/db_world/2023_12_12_13.sql diff --git a/data/sql/updates/db_world/2023_12_12_14.sql b/data/sql/archive/db_world/2023_12_12_14.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_14.sql rename to data/sql/archive/db_world/2023_12_12_14.sql diff --git a/data/sql/updates/db_world/2023_12_12_15.sql b/data/sql/archive/db_world/2023_12_12_15.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_15.sql rename to data/sql/archive/db_world/2023_12_12_15.sql diff --git a/data/sql/updates/db_world/2023_12_12_16.sql b/data/sql/archive/db_world/2023_12_12_16.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_12_16.sql rename to data/sql/archive/db_world/2023_12_12_16.sql diff --git a/data/sql/updates/db_world/2023_12_24_00.sql b/data/sql/archive/db_world/2023_12_24_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_24_00.sql rename to data/sql/archive/db_world/2023_12_24_00.sql diff --git a/data/sql/updates/db_world/2023_12_24_01.sql b/data/sql/archive/db_world/2023_12_24_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_24_01.sql rename to data/sql/archive/db_world/2023_12_24_01.sql diff --git a/data/sql/updates/db_world/2023_12_25_00.sql b/data/sql/archive/db_world/2023_12_25_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_25_00.sql rename to data/sql/archive/db_world/2023_12_25_00.sql diff --git a/data/sql/updates/db_world/2023_12_25_01.sql b/data/sql/archive/db_world/2023_12_25_01.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_25_01.sql rename to data/sql/archive/db_world/2023_12_25_01.sql diff --git a/data/sql/updates/db_world/2023_12_26_00.sql b/data/sql/archive/db_world/2023_12_26_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_26_00.sql rename to data/sql/archive/db_world/2023_12_26_00.sql diff --git a/data/sql/updates/db_world/2023_12_28_00.sql b/data/sql/archive/db_world/2023_12_28_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_28_00.sql rename to data/sql/archive/db_world/2023_12_28_00.sql diff --git a/data/sql/updates/db_world/2023_12_30_00.sql b/data/sql/archive/db_world/2023_12_30_00.sql similarity index 100% rename from data/sql/updates/db_world/2023_12_30_00.sql rename to data/sql/archive/db_world/2023_12_30_00.sql diff --git a/data/sql/base/database-squash.md b/data/sql/base/database-squash.md index 3275e727f65bc6..a09a9a8f8af0d6 100644 --- a/data/sql/base/database-squash.md +++ b/data/sql/base/database-squash.md @@ -3,9 +3,11 @@ New routines around handling database squashes since https://github.com/azerothc > [!CAUTION] > These steps are only for project maintainers who intend to update base files. -We ONLY squash into BASE files. We never move files. -ARCHIVE dir is UNUSED. -All update files ALWAYS exist in the updates dir. +During the DB squash procedure, we do NOT move files. +The archive dir is NO longer used as part of the DB squash procedure, +but simply as a place where to move update files when they get too many. + +Moving files to the archive folder is NOT part of the squash procedure anymore. as the `updates` table in base files always will contain the entries from the updates dir they will never be run again on a clean setup. diff --git a/data/sql/updates/pending_db_auth/rev_1730914996045617000.sql b/data/sql/updates/pending_db_auth/rev_1730914996045617000.sql new file mode 100644 index 00000000000000..93784a9facb2a6 --- /dev/null +++ b/data/sql/updates/pending_db_auth/rev_1730914996045617000.sql @@ -0,0 +1,3 @@ +UPDATE `updates` +SET `state` = 'ARCHIVED' +WHERE `name` LIKE '2023_%'; diff --git a/data/sql/updates/pending_db_characters/rev_1730914990538967000.sql b/data/sql/updates/pending_db_characters/rev_1730914990538967000.sql new file mode 100644 index 00000000000000..93784a9facb2a6 --- /dev/null +++ b/data/sql/updates/pending_db_characters/rev_1730914990538967000.sql @@ -0,0 +1,3 @@ +UPDATE `updates` +SET `state` = 'ARCHIVED' +WHERE `name` LIKE '2023_%'; diff --git a/data/sql/updates/pending_db_world/rev_1730914980646466000.sql b/data/sql/updates/pending_db_world/rev_1730914980646466000.sql new file mode 100644 index 00000000000000..93784a9facb2a6 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730914980646466000.sql @@ -0,0 +1,3 @@ +UPDATE `updates` +SET `state` = 'ARCHIVED' +WHERE `name` LIKE '2023_%'; From c27c0badc8bc635c98398d946b98725b24c5dc16 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 15 Nov 2024 10:28:37 +0000 Subject: [PATCH 096/105] chore(DB): import pending files Referenced commit(s): c5ae1ae88fd2a76e119e54cd896d0227f703117c --- .../rev_1730914996045617000.sql => db_auth/2024_11_15_00.sql} | 1 + .../2024_11_15_00.sql} | 1 + .../rev_1730914980646466000.sql => db_world/2024_11_15_01.sql} | 1 + 3 files changed, 3 insertions(+) rename data/sql/updates/{pending_db_auth/rev_1730914996045617000.sql => db_auth/2024_11_15_00.sql} (61%) rename data/sql/updates/{pending_db_characters/rev_1730914990538967000.sql => db_characters/2024_11_15_00.sql} (61%) rename data/sql/updates/{pending_db_world/rev_1730914980646466000.sql => db_world/2024_11_15_01.sql} (61%) diff --git a/data/sql/updates/pending_db_auth/rev_1730914996045617000.sql b/data/sql/updates/db_auth/2024_11_15_00.sql similarity index 61% rename from data/sql/updates/pending_db_auth/rev_1730914996045617000.sql rename to data/sql/updates/db_auth/2024_11_15_00.sql index 93784a9facb2a6..2321e4fa0369f3 100644 --- a/data/sql/updates/pending_db_auth/rev_1730914996045617000.sql +++ b/data/sql/updates/db_auth/2024_11_15_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_01_20_00 -> 2024_11_15_00 UPDATE `updates` SET `state` = 'ARCHIVED' WHERE `name` LIKE '2023_%'; diff --git a/data/sql/updates/pending_db_characters/rev_1730914990538967000.sql b/data/sql/updates/db_characters/2024_11_15_00.sql similarity index 61% rename from data/sql/updates/pending_db_characters/rev_1730914990538967000.sql rename to data/sql/updates/db_characters/2024_11_15_00.sql index 93784a9facb2a6..d63ba925d1febf 100644 --- a/data/sql/updates/pending_db_characters/rev_1730914990538967000.sql +++ b/data/sql/updates/db_characters/2024_11_15_00.sql @@ -1,3 +1,4 @@ +-- DB update 2024_09_22_00 -> 2024_11_15_00 UPDATE `updates` SET `state` = 'ARCHIVED' WHERE `name` LIKE '2023_%'; diff --git a/data/sql/updates/pending_db_world/rev_1730914980646466000.sql b/data/sql/updates/db_world/2024_11_15_01.sql similarity index 61% rename from data/sql/updates/pending_db_world/rev_1730914980646466000.sql rename to data/sql/updates/db_world/2024_11_15_01.sql index 93784a9facb2a6..472ef3198a52a7 100644 --- a/data/sql/updates/pending_db_world/rev_1730914980646466000.sql +++ b/data/sql/updates/db_world/2024_11_15_01.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_15_00 -> 2024_11_15_01 UPDATE `updates` SET `state` = 'ARCHIVED' WHERE `name` LIKE '2023_%'; From 07793f6cc8d16ec577e82626003ceb603a8c73bd Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Fri, 15 Nov 2024 07:50:58 -0300 Subject: [PATCH 097/105] fix(Scripts/TheEye): Fix Al'ar berserk timer (#20572) --- .../Outland/TempestKeep/Eye/boss_alar.cpp | 71 ++++++------------- 1 file changed, 20 insertions(+), 51 deletions(-) diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp index db246c77e36c0f..095fbf423e3b8c 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp @@ -72,11 +72,10 @@ enum Misc EVENT_RELOCATE_MIDDLE = 1, EVENT_REBIRTH = 2, - EVENT_SPELL_BERSERK = 3, - EVENT_MOVE_TO_PHASE_2 = 4, - EVENT_FINISH_DIVE = 5, - EVENT_INVISIBLE = 6 + EVENT_MOVE_TO_PHASE_2 = 3, + EVENT_FINISH_DIVE = 4, + EVENT_INVISIBLE = 5 }; enum GroupAlar @@ -121,15 +120,14 @@ struct boss_alar : public BossAI me->SetModelVisible(true); me->SetReactState(REACT_AGGRESSIVE); ConstructWaypointsAndMove(); + me->m_Events.KillAllEvents(false); } void JustReachedHome() override { BossAI::JustReachedHome(); if (me->IsEngaged()) - { ConstructWaypointsAndMove(); - } } void JustEngagedWith(Unit* who) override @@ -158,6 +156,7 @@ struct boss_alar : public BossAI } context.Repeat(_platformMoveRepeatTimer); }); + ScheduleMainSpellAttack(0s); } @@ -172,16 +171,9 @@ struct boss_alar : public BossAI void EnterEvadeMode(EvadeReason why) override { if (why == EVADE_REASON_BOUNDARY) - { BossAI::EnterEvadeMode(why); - } - else - { - if (me->GetThreatMgr().GetThreatList().empty()) - { - BossAI::EnterEvadeMode(why); - } - } + else if (me->GetThreatMgr().GetThreatList().empty()) + BossAI::EnterEvadeMode(why); } void JustDied(Unit* killer) override @@ -189,19 +181,11 @@ struct boss_alar : public BossAI BossAI::JustDied(killer); me->SetModelVisible(true); - if (Map* map = me->GetMap()) + me->GetMap()->DoForAllPlayers([&](Player* player) { - map->DoForAllPlayers([&](Player* player) - { - if (player->GetQuestStatus(QUEST_RUSE_OF_THE_ASHTONGUE) == QUEST_STATUS_INCOMPLETE) - { - if (player->HasAura(SPELL_ASHTONGUE_RUSE)) - { - player->AreaExploredOrEventHappens(QUEST_RUSE_OF_THE_ASHTONGUE); - } - } - }); - } + if (player->GetQuestStatus(QUEST_RUSE_OF_THE_ASHTONGUE) == QUEST_STATUS_INCOMPLETE && player->HasAura(SPELL_ASHTONGUE_RUSE)) + player->AreaExploredOrEventHappens(QUEST_RUSE_OF_THE_ASHTONGUE); + }); } void MoveInLineOfSight(Unit* /*who*/) override { } @@ -235,7 +219,7 @@ struct boss_alar : public BossAI _noMelee = false; me->RemoveUnitFlag(UNIT_FLAG_NOT_SELECTABLE); _platform = POINT_MIDDLE; - me->GetMotionMaster()->MoveChase(me->GetVictim()); + me->ResumeChasingVictim(); ScheduleAbilities(); }); } @@ -270,19 +254,18 @@ struct boss_alar : public BossAI { // find spell from sniffs? if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 50.0f, true)) - { me->SummonCreature(NPC_FLAME_PATCH, *target, TEMPSUMMON_TIMED_DESPAWN, 2 * MINUTE * IN_MILLISECONDS); - } }, 30s); ScheduleTimedEvent(34s, [&] { me->GetMotionMaster()->MovePoint(POINT_DIVE, alarPoints[POINT_DIVE], false, true); scheduler.DelayAll(15s); }, 57s); - ScheduleUniqueTimedEvent(10min, [&] - { - DoCastSelf(SPELL_BERSERK); - }, EVENT_SPELL_BERSERK); + + me->m_Events.AddEventAtOffset([&] { + DoCastSelf(SPELL_BERSERK, true); + }, 10min); + ScheduleMainSpellAttack(0s); } @@ -304,16 +287,14 @@ struct boss_alar : public BossAI scheduler.Schedule(2s, [this](TaskContext) { if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 110.0f, true)) - { SpawnPhoenixes(2, target); - } }).Schedule(6s, [this](TaskContext) { me->SetModelVisible(true); DoCastSelf(SPELL_REBIRTH_DIVE); }).Schedule(10s, [this](TaskContext) { - me->GetMotionMaster()->MoveChase(me->GetVictim()); + me->ResumeChasingVictim(); _noMelee = false; }); if (Unit* target = SelectTarget(SelectTargetMethod::Random, 0, 90.0f, true)) @@ -331,9 +312,8 @@ struct boss_alar : public BossAI if (type != POINT_MOTION_TYPE) { if (type == ESCORT_MOTION_TYPE && me->movespline->Finalized() && !me->IsInCombat()) - { ConstructWaypointsAndMove(); - } + return; } @@ -366,9 +346,8 @@ struct boss_alar : public BossAI scheduler.Schedule(timer, GROUP_FLAME_BUFFET, [this](TaskContext context) { if (!me->SelectNearestTarget(me->GetCombatReach()) && !me->isMoving()) - { DoCastVictim(SPELL_FLAME_BUFFET); - } + context.Repeat(2s); }); } @@ -394,21 +373,15 @@ struct boss_alar : public BossAI _transitionScheduler.Update(diff); if (!UpdateVictim()) - { return; - } scheduler.Update(diff); if (me->HasUnitState(UNIT_STATE_CASTING)) - { return; - } if (!_noMelee) - { DoMeleeAttackIfReady(); - } } Position DeterminePhoenixPosition(Position playerPosition) @@ -498,13 +471,9 @@ class spell_alar_ember_blast : public SpellScript void HandleCast() { if (InstanceScript* instance = GetCaster()->GetInstanceScript()) - { if (Creature* alar = instance->GetCreature(DATA_ALAR)) - { if (!alar->HasAura(SPELL_MODEL_VISIBILITY)) Unit::DealDamage(GetCaster(), alar, alar->CountPctFromMaxHealth(2)); - } - } } void Register() override From e2a57dbfb24738bb6bbbfd038d552d9f3cb24302 Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Fri, 15 Nov 2024 09:01:31 -0300 Subject: [PATCH 098/105] fix(Scripts/ZulAman): Update Malacrass adds spawn positions (#20580) Co-authored-by: Benjamin Jackson <38561765+heyitsbench@users.noreply.github.com> --- .../EasternKingdoms/ZulAman/boss_hexlord.cpp | 123 ++++++++---------- 1 file changed, 55 insertions(+), 68 deletions(-) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp index ca2ad77b08777a..5aede98a5ae845 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp @@ -22,16 +22,10 @@ #include "Player.h" #include "SpellScriptLoader.h" #include "zulaman.h" -/* ScriptData -SDName: Boss_Hex_Lord_Malacrass -SD%Complete: -SDComment: -SDCategory: Zul'Aman -EndScriptData */ enum Says { - SAY_AGGRO = 0, + SAY_AGGRO, SAY_KILL_ONE, SAY_KILL_TWO, SAY_DRAIN_POWER, @@ -117,23 +111,23 @@ enum Spells // Death Knight SPELL_DK_PLAGUE_STRIKE = 57599, SPELL_DK_DEATH_AND_DECAY = 43265, - SPELL_DK_BLOOD_WORMS = 97630, + SPELL_DK_BLOOD_WORMS = 97630 }; -const Position addPosition[4] = +const Position AddPosition[4] = { - {112.8827f, 921.2795f, 33.8883f, 1.5696f}, - {107.8827f, 921.2795f, 33.8883f, 1.5696f}, - {122.8827f, 921.2795f, 33.8883f, 1.5696f}, - {127.8827f, 921.2795f, 33.8883f, 1.5696f} + { 128.48448f, 923.04285f, 33.97255f, 1.588249564170837402f }, + { 122.60526f, 923.24536f, 33.97256f, 1.570796370506286621f }, + { 111.69282f, 923.15314f, 33.972576f, 1.570796370506286621f }, + { 105.40299f, 923.3421f, 33.972588f, 1.553343057632446289f } }; -static uint32 addEntrySets[4][2] = +static uint32 AddEntrySets[4][2] = { - {NPC_THURG, NPC_ALYSON_ANTILLE }, - {NPC_LORD_RADAAN, NPC_SLITHER }, - {NPC_GAZAKROTH, NPC_FENSTALKER }, - {NPC_DARKHEART, NPC_KORAGG } + { NPC_THURG, NPC_ALYSON_ANTILLE }, + { NPC_LORD_RADAAN, NPC_SLITHER }, + { NPC_GAZAKROTH, NPC_FENSTALKER }, + { NPC_DARKHEART, NPC_KORAGG } }; enum Misc @@ -145,11 +139,11 @@ enum Misc enum AbilityTarget { - ABILITY_TARGET_SELF = 0, - ABILITY_TARGET_VICTIM = 1, - ABILITY_TARGET_ENEMY = 2, - ABILITY_TARGET_HEAL = 3, - ABILITY_TARGET_BUFF = 4, + ABILITY_TARGET_SELF = 0, + ABILITY_TARGET_VICTIM = 1, + ABILITY_TARGET_ENEMY = 2, + ABILITY_TARGET_HEAL = 3, + ABILITY_TARGET_BUFF = 4, ABILITY_TARGET_SPECIAL = 5 }; @@ -163,66 +157,66 @@ struct PlayerAbilityStruct static PlayerAbilityStruct PlayerAbility[12][3] = { // 1 warrior - { {SPELL_WR_SPELL_REFLECT, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_WR_WHIRLWIND, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_WR_MORTAL_STRIKE, ABILITY_TARGET_VICTIM, 6000ms} + { { SPELL_WR_SPELL_REFLECT, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_WR_WHIRLWIND, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_WR_MORTAL_STRIKE, ABILITY_TARGET_VICTIM, 6000ms } }, // 2 paladin - { {SPELL_PA_CONSECRATION, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_PA_HOLY_LIGHT, ABILITY_TARGET_HEAL, 10000ms}, - {SPELL_PA_AVENGING_WRATH, ABILITY_TARGET_SELF, 10000ms} + { { SPELL_PA_CONSECRATION, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_PA_HOLY_LIGHT, ABILITY_TARGET_HEAL, 10000ms }, + { SPELL_PA_AVENGING_WRATH, ABILITY_TARGET_SELF, 10000ms } }, // 3 hunter - { {SPELL_HU_EXPLOSIVE_TRAP, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_HU_FREEZING_TRAP, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_HU_SNAKE_TRAP, ABILITY_TARGET_SELF, 10000ms} + { { SPELL_HU_EXPLOSIVE_TRAP, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_HU_FREEZING_TRAP, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_HU_SNAKE_TRAP, ABILITY_TARGET_SELF, 10000ms } }, // 4 rogue - { {SPELL_RO_WOUND_POISON, ABILITY_TARGET_VICTIM, 3000ms}, - {SPELL_RO_SLICE_DICE, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_RO_BLIND, ABILITY_TARGET_ENEMY, 10000ms} + { { SPELL_RO_WOUND_POISON, ABILITY_TARGET_VICTIM, 3000ms }, + { SPELL_RO_SLICE_DICE, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_RO_BLIND, ABILITY_TARGET_ENEMY, 10000ms } }, // 5 priest - { {SPELL_PR_PAIN_SUPP, ABILITY_TARGET_HEAL, 10000ms}, - {SPELL_PR_HEAL, ABILITY_TARGET_HEAL, 10000ms}, - {SPELL_PR_PSYCHIC_SCREAM, ABILITY_TARGET_SELF, 10000ms} + { { SPELL_PR_PAIN_SUPP, ABILITY_TARGET_HEAL, 10000ms }, + { SPELL_PR_HEAL, ABILITY_TARGET_HEAL, 10000ms }, + { SPELL_PR_PSYCHIC_SCREAM, ABILITY_TARGET_SELF, 10000ms } }, // 6 death knight { - {SPELL_DK_PLAGUE_STRIKE, ABILITY_TARGET_ENEMY, 2000ms}, - {SPELL_DK_DEATH_AND_DECAY, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_DK_BLOOD_WORMS, ABILITY_TARGET_ENEMY, 5000ms} + { SPELL_DK_PLAGUE_STRIKE, ABILITY_TARGET_ENEMY, 2000ms }, + { SPELL_DK_DEATH_AND_DECAY, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_DK_BLOOD_WORMS, ABILITY_TARGET_ENEMY, 5000ms } }, // 7 shaman - { {SPELL_SH_FIRE_NOVA, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_SH_HEALING_WAVE, ABILITY_TARGET_HEAL, 10000ms}, - {SPELL_SH_CHAIN_LIGHT, ABILITY_TARGET_ENEMY, 8000ms} + { { SPELL_SH_FIRE_NOVA, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_SH_HEALING_WAVE, ABILITY_TARGET_HEAL, 10000ms }, + { SPELL_SH_CHAIN_LIGHT, ABILITY_TARGET_ENEMY, 8000ms } }, // 8 mage - { {SPELL_MG_FIREBALL, ABILITY_TARGET_ENEMY, 5000ms}, - {SPELL_MG_FROSTBOLT, ABILITY_TARGET_ENEMY, 5000ms}, - {SPELL_MG_ICE_LANCE, ABILITY_TARGET_SPECIAL, 2000ms} + { { SPELL_MG_FIREBALL, ABILITY_TARGET_ENEMY, 5000ms }, + { SPELL_MG_FROSTBOLT, ABILITY_TARGET_ENEMY, 5000ms }, + { SPELL_MG_ICE_LANCE, ABILITY_TARGET_SPECIAL, 2000ms } }, // 9 warlock - { {SPELL_WL_CURSE_OF_DOOM, ABILITY_TARGET_ENEMY, 10000ms}, - {SPELL_WL_RAIN_OF_FIRE, ABILITY_TARGET_ENEMY, 10000ms}, - {SPELL_WL_UNSTABLE_AFFL, ABILITY_TARGET_ENEMY, 10000ms} + { { SPELL_WL_CURSE_OF_DOOM, ABILITY_TARGET_ENEMY, 10000ms }, + { SPELL_WL_RAIN_OF_FIRE, ABILITY_TARGET_ENEMY, 10000ms }, + { SPELL_WL_UNSTABLE_AFFL, ABILITY_TARGET_ENEMY, 10000ms } }, // 10 UNK class (should never be set) { - {0, ABILITY_TARGET_SELF, 0ms}, - {0, ABILITY_TARGET_SELF, 0ms}, - {0, ABILITY_TARGET_SELF, 0ms} + { 0, ABILITY_TARGET_SELF, 0ms}, + { 0, ABILITY_TARGET_SELF, 0ms}, + { 0, ABILITY_TARGET_SELF, 0ms} }, // 11 druid - { {SPELL_DR_LIFEBLOOM, ABILITY_TARGET_HEAL, 10000ms}, - {SPELL_DR_THORNS, ABILITY_TARGET_SELF, 10000ms}, - {SPELL_DR_MOONFIRE, ABILITY_TARGET_ENEMY, 8000ms} + { { SPELL_DR_LIFEBLOOM, ABILITY_TARGET_HEAL, 10000ms }, + { SPELL_DR_THORNS, ABILITY_TARGET_SELF, 10000ms }, + { SPELL_DR_MOONFIRE, ABILITY_TARGET_ENEMY, 8000ms } }, // MISC shadow priest - { {SPELL_PR_MIND_CONTROL, ABILITY_TARGET_ENEMY, 15000ms}, - {SPELL_PR_MIND_BLAST, ABILITY_TARGET_ENEMY, 5000ms}, - {SPELL_PR_SW_DEATH, ABILITY_TARGET_ENEMY, 10000ms} + { { SPELL_PR_MIND_CONTROL, ABILITY_TARGET_ENEMY, 15000ms }, + { SPELL_PR_MIND_BLAST, ABILITY_TARGET_ENEMY, 5000ms }, + { SPELL_PR_SW_DEATH, ABILITY_TARGET_ENEMY, 10000ms } } }; @@ -243,7 +237,7 @@ struct boss_hexlord_malacrass : public BossAI for (uint8 i = 0; i < MAX_ADD_COUNT; ++i) { uint8 flip = urand(0, 1); - me->SummonCreature(addEntrySets[i][flip], addPosition[i], TEMPSUMMON_DEAD_DESPAWN, 0); + me->SummonCreature(AddEntrySets[i][flip], AddPosition[i], TEMPSUMMON_DEAD_DESPAWN, 0); } } @@ -274,21 +268,14 @@ struct boss_hexlord_malacrass : public BossAI siphonTrigger->AI()->DoCast(target, SPELL_SIPHON_SOUL, true); siphonTrigger->GetMotionMaster()->MoveChase(me); if (Player* player = target->ToPlayer()) - { - if (player->HasAura(AURA_SHADOW_FORM)) - _currentClass = ADDITIONAL_CLASS_SPRIEST; - else - _currentClass = player->getClass() - 1; - } + _currentClass = player->HasAura(AURA_SHADOW_FORM) ? ADDITIONAL_CLASS_SPRIEST : player->getClass() - 1; } } }); }, 40s); ScheduleTimedEvent(_classAbilityTimer, [&]{ if (_currentClass) - { UseAbility(); - } }, _classAbilityTimer); } From b8a9dc9cf867433052544764981b481c3e3ed784 Mon Sep 17 00:00:00 2001 From: DuckBone <129666049+Kacsacsont@users.noreply.github.com> Date: Fri, 15 Nov 2024 14:24:49 +0100 Subject: [PATCH 099/105] Fix(DB/creature_template): Fix quest 12028 - Spiritual Insight (#20376) --- data/sql/updates/pending_db_world/rev_1730390397729810000.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1730390397729810000.sql diff --git a/data/sql/updates/pending_db_world/rev_1730390397729810000.sql b/data/sql/updates/pending_db_world/rev_1730390397729810000.sql new file mode 100644 index 00000000000000..0529c0e52e22f6 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1730390397729810000.sql @@ -0,0 +1,2 @@ +-- remove trigger flag from 26594 Spiritual Insight Transform +UPDATE `creature_template` SET `flags_extra` = (`flags_extra` & ~128) WHERE (`entry` = 26594); From c9665aa69b67d70027e0f61bb9125679bbc16c91 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 15 Nov 2024 13:25:43 +0000 Subject: [PATCH 100/105] chore(DB): import pending files Referenced commit(s): b8a9dc9cf867433052544764981b481c3e3ed784 --- .../rev_1730390397729810000.sql => db_world/2024_11_15_02.sql} | 1 + 1 file changed, 1 insertion(+) rename data/sql/updates/{pending_db_world/rev_1730390397729810000.sql => db_world/2024_11_15_02.sql} (78%) diff --git a/data/sql/updates/pending_db_world/rev_1730390397729810000.sql b/data/sql/updates/db_world/2024_11_15_02.sql similarity index 78% rename from data/sql/updates/pending_db_world/rev_1730390397729810000.sql rename to data/sql/updates/db_world/2024_11_15_02.sql index 0529c0e52e22f6..35292230fe3500 100644 --- a/data/sql/updates/pending_db_world/rev_1730390397729810000.sql +++ b/data/sql/updates/db_world/2024_11_15_02.sql @@ -1,2 +1,3 @@ +-- DB update 2024_11_15_01 -> 2024_11_15_02 -- remove trigger flag from 26594 Spiritual Insight Transform UPDATE `creature_template` SET `flags_extra` = (`flags_extra` & ~128) WHERE (`entry` = 26594); From e1d0cf9a15b6c2e54c90f1f8716f588d7005147b Mon Sep 17 00:00:00 2001 From: Andrew <47818697+Nyeriah@users.noreply.github.com> Date: Fri, 15 Nov 2024 10:49:02 -0300 Subject: [PATCH 101/105] feat(Core/Instances): Implement SummonData (#20582) --- src/server/game/Instances/InstanceScript.cpp | 22 +++++++++++++++++ src/server/game/Instances/InstanceScript.h | 6 +++++ .../BlackTemple/instance_black_temple.cpp | 24 +++++++------------ 3 files changed, 36 insertions(+), 16 deletions(-) diff --git a/src/server/game/Instances/InstanceScript.cpp b/src/server/game/Instances/InstanceScript.cpp index bbc160c01035c4..0509054165af2a 100644 --- a/src/server/game/Instances/InstanceScript.cpp +++ b/src/server/game/Instances/InstanceScript.cpp @@ -59,6 +59,9 @@ void InstanceScript::OnCreatureCreate(Creature* creature) { AddObject(creature); AddMinion(creature); + + if (creature->IsSummon()) + SetSummoner(creature); } void InstanceScript::OnCreatureRemove(Creature* creature) @@ -194,6 +197,15 @@ void InstanceScript::LoadObjectData(ObjectData const* data, ObjectInfoMap& objec } } +void InstanceScript::LoadSummonData(ObjectData const* data) +{ + while (data->entry) + { + _summonInfo[data->entry] = data->type; + ++data; + } +} + void InstanceScript::UpdateMinionState(Creature* minion, EncounterState state) { switch (state) @@ -348,6 +360,16 @@ void InstanceScript::RemoveMinion(Creature* minion) AddMinion(minion, false); } +void InstanceScript::SetSummoner(Creature* creature) +{ + auto const& summonData = _summonInfo.find(creature->GetEntry()); + + if (summonData != _summonInfo.end()) + if (Creature* summoner = GetCreature(summonData->second)) + if (summoner->IsAIEnabled) + summoner->AI()->JustSummoned(creature); +} + bool InstanceScript::SetBossState(uint32 id, EncounterState state) { if (id < bosses.size()) diff --git a/src/server/game/Instances/InstanceScript.h b/src/server/game/Instances/InstanceScript.h index c5add7eb201b86..8e6f83c1ff1ba3 100644 --- a/src/server/game/Instances/InstanceScript.h +++ b/src/server/game/Instances/InstanceScript.h @@ -288,6 +288,11 @@ class InstanceScript : public ZoneScript void LoadDoorData(DoorData const* data); void LoadMinionData(MinionData const* data); void LoadObjectData(ObjectData const* creatureData, ObjectData const* gameObjectData); + // Allows setting another creature as summoner for a creature. + // This is used to handle summons that are not directly controlled by the summoner. + // Summoner creature must be loaded in the instance data (LoadObjectData). + void LoadSummonData(ObjectData const* data); + void SetSummoner(Creature* creature); void AddObject(Creature* obj, bool add = true); void RemoveObject(Creature* obj); @@ -324,6 +329,7 @@ class InstanceScript : public ZoneScript MinionInfoMap minions; ObjectInfoMap _creatureInfo; ObjectInfoMap _gameObjectInfo; + ObjectInfoMap _summonInfo; ObjectGuidMap _objectGuids; ObjectStateMap _objectStateMap; uint32 completedEncounters; // completed encounter mask, bit indexes are DungeonEncounter.dbc boss numbers, used for packets diff --git a/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp b/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp index ed520d5c3ab54a..93a482721bbbc1 100644 --- a/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp +++ b/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp @@ -66,8 +66,13 @@ ObjectData const creatureData[] = { 0, 0 } }; -ObjectData const objectData[] = +ObjectData const summonData[] = { + { NPC_BLADE_OF_AZZINOTH, DATA_ILLIDAN_STORMRAGE }, + { NPC_FLAME_OF_AZZINOTH, DATA_ILLIDAN_STORMRAGE }, + { NPC_PARASITIC_SHADOWFIEND, DATA_ILLIDAN_STORMRAGE }, + { NPC_SHADOWY_CONSTRUCT, DATA_TERON_GOREFIEND }, + { NPC_ENSLAVED_SOUL, DATA_RELIQUARY_OF_SOULS }, { 0, 0 } }; @@ -99,7 +104,8 @@ class instance_black_temple : public InstanceMapScript SetBossNumber(MAX_ENCOUNTERS); LoadDoorData(doorData); LoadBossBoundaries(boundaries); - LoadObjectData(creatureData, objectData); + LoadObjectData(creatureData, nullptr); + LoadSummonData(summonData); ashtongueGUIDs.clear(); } @@ -108,20 +114,6 @@ class instance_black_temple : public InstanceMapScript { switch (creature->GetEntry()) { - case NPC_SHADOWY_CONSTRUCT: - if (Creature* teron = GetCreature(DATA_TERON_GOREFIEND)) - teron->AI()->JustSummoned(creature); - break; - case NPC_ENSLAVED_SOUL: - if (Creature* reliquary = GetCreature(DATA_RELIQUARY_OF_SOULS)) - reliquary->AI()->JustSummoned(creature); - break; - case NPC_PARASITIC_SHADOWFIEND: - case NPC_BLADE_OF_AZZINOTH: - case NPC_FLAME_OF_AZZINOTH: - if (Creature* illidan = GetCreature(DATA_ILLIDAN_STORMRAGE)) - illidan->AI()->JustSummoned(creature); - break; case NPC_ANGERED_SOUL_FRAGMENT: case NPC_HUNGERING_SOUL_FRAGMENT: case NPC_SUFFERING_SOUL_FRAGMENT: From 1c449b303ab1b7f326a011cd2771f0bb6a45b237 Mon Sep 17 00:00:00 2001 From: sudlud Date: Fri, 15 Nov 2024 15:32:20 +0100 Subject: [PATCH 102/105] fix(DB/Creature): Sniffed Values for 'Lunar - Elders' spawns (#20581) --- .../rev_1731673168265331400.sql | 85 +++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731673168265331400.sql diff --git a/data/sql/updates/pending_db_world/rev_1731673168265331400.sql b/data/sql/updates/pending_db_world/rev_1731673168265331400.sql new file mode 100644 index 00000000000000..2b43d130da6373 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731673168265331400.sql @@ -0,0 +1,85 @@ +-- Update creature 'Lunar - Elders' with sniffed values +-- updated spawns +DELETE FROM `creature` WHERE (`id1` IN (30364, 30348, 30371, 30360, 30358, 30373, 30363, 30367, 30357, 30369, 30374, 30370, 30359, 30375, 30372, 30362, 30365, 30368, 30537, 30534, 30533, 30535, 30531, 30538, 30536, 15607, 15567, 15561, 15605, 15557, 15558, 15574, 15565, 15595, 15583, 15582, 15600, 15588, 15597, 15601, 15598, 15572, 15581, 15587, 15575, 15603, 15599, 15570, 15586, 15573, 15584, 15604, 15606, 15563, 15585, 15569, 15596, 15568, 15577, 15549, 15556, 15578, 15560, 15593, 15576, 15564, 15580, 15579, 15562, 15871, 15559, 15566, 15592, 15602, 15594)) +AND (`guid` IN (200823, 200824, 200825, 200826, 200827, 200828, 200829, 200830, 200831, 200832, 200833, 200834, 200835, 200836, 200837, 200838, 200839, 200840, 200841, 200842, 200843, 200844, 200845, 200846, 200847, 200848, 34035, 34036, 70553, 70554, 70555, 70556, 70557, 70560, 70561, 70562, 70563, 70564, 70565, 70566, 70567, 70568, 70570, 70571, 70572, 70573, 70574, 70575, 70576, 70578, 72236, 72237, 72238, 72239, 75117, 78371, 78372, 78373, 78374, 78375, 78381, 78382, 78383, 78384, 91562, 91598, 91603, 91610, 91630, 91631, 91708, 91710, 91711, 91712, 91713)); +INSERT INTO `creature` (`guid`, `id1`, `map`, `spawnMask`, `phaseMask`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `wander_distance`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `ScriptName`, `VerifiedBuild`, `CreateObject`, `Comment`) VALUES +(200823, 30364, 571, 1, 1, 0, 3217.413330078125, 5261.70068359375, 48.01685333251953125, 1.902408838272094726, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200824, 30348, 571, 1, 1, 0, 2375.052978515625, 5164.5322265625, 3.884083271026611328, 1.117010712623596191, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200825, 30371, 571, 1, 1, 0, 2992.486328125, 6095.724609375, 141.788604736328125, 5.462880611419677734, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200826, 30360, 571, 1, 1, 0, 3577.133544921875, 6622.453125, 195.5571746826171875, 1.343903541564941406, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200827, 30358, 571, 1, 1, 0, 3484.459228515625, 1958.783447265625, 64.9326629638671875, 3.926990747451782226, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200828, 30373, 571, 1, 1, 0, 3766.9931640625, 1658.775390625, 119.1679153442382812, 5.602506637573242187, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200829, 30363, 571, 1, 1, 0, 2651.549560546875, 891.99688720703125, 4.458107471466064453, 0.226892799139022827, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200830, 30367, 571, 1, 1, 0, 4217.8193359375, -5338.099609375, 11.68194198608398437, 1.570796370506286621, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200831, 30357, 571, 1, 1, 0, 4547.9736328125, -4290.28466796875, 174.117645263671875, 1.902408838272094726, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200832, 30369, 571, 1, 1, 0, 5805.48583984375, -3541.645751953125, 391.73553466796875, 3.612831592559814453, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200833, 30374, 571, 1, 1, 0, 7763.619140625, -2752.565673828125, 1164.5931396484375, 6.0737457275390625, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200834, 30370, 571, 1, 1, 0, 6180.66259765625, -1085.6510009765625, 415.440399169921875, 2.879793167114257812, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200835, 30359, 571, 1, 1, 0, 6702.6025390625, -212.8416748046875, 975.86639404296875, 3.717551231384277343, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200836, 30375, 571, 1, 1, 0, 8414.4345703125, -381.993988037109375, 903.20172119140625, 3.31612563133239746, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200837, 30372, 571, 1, 1, 0, 3872.1328125, -4479.91796875, 222.8077239990234375, 4.258603572845458984, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200838, 30362, 571, 1, 1, 0, 5439.8046875, 4760.640625, -198.602569580078125, 1.221730470657348632, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200839, 30365, 571, 1, 1, 0, 5863.82470703125, 4149.81201171875, -93.8164291381835937, 4.904375076293945312, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200840, 30368, 571, 1, 1, 0, 5440.30615234375, 2870.63427734375, 418.75811767578125, 3.682644605636596679, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200841, 30537, 604, 3, 1, 0, 1697.5989990234375, 751.78472900390625, 142.8502349853515625, 3.804817676544189453, 7200, 0, 0, 0, 0, 0, "", 52237, 1, NULL), +(200842, 30534, 600, 3, 1, 0, -509.59613037109375, -734.34002685546875, 30.329742431640625, 1.605702877044677734, 7200, 0, 0, 0, 0, 0, "", 52237, 1, NULL), +(200843, 30533, 601, 3, 1, 0, 575.43951416015625, 558.98187255859375, 291.9625244140625, 3.59537816047668457, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200844, 30535, 599, 3, 1, 0, 995.099609375, 856.15216064453125, 185.0620574951171875, 5.16617441177368164, 7200, 0, 0, 0, 0, 0, "", 52237, 1, NULL), +(200845, 30531, 574, 3, 1, 0, 174.692169189453125, 75.909942626953125, 74.35488128662109375, 3.473205089569091796, 7200, 0, 0, 0, 0, 0, "", 52237, 1, NULL), +(200846, 30538, 575, 3, 1, 0, 468.646270751953125, -416.338226318359375, 75.00853729248046875, 0.296705961227416992, 7200, 0, 0, 0, 0, 0, "", 52237, 1, NULL), +(200847, 30536, 576, 3, 1, 0, 323.1781005859375, -214.712890625, -14.0055017471313476, 4.468042850494384765, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(200848, 15607, 329, 1, 1, 0, 3705.2158203125, -3466.813720703125, 130.794342041015625, 0, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(34035, 15567, 0, 1, 1, 0, -7276.74853515625, -797.923583984375, 296.581787109375, 5.829399585723876953, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(34036, 15561, 0, 1, 1, 0, 514.75433349609375, 1560.96923828125, 130.144683837890625, 4.398229598999023437, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70553, 15605, 1, 1, 1, 0, 2793.033935546875, -349.60498046875, 108.4710235595703125, 2.216568231582641601, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70554, 15557, 0, 1, 1, 0, -7938.57373046875, -2674.64208984375, 209.2259063720703125, 3.752457857131958007, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70555, 15558, 0, 1, 1, 0, -5343.724609375, -2912.938720703125, 345.1905517578125, 4.433136463165283203, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70556, 15574, 1, 1, 1, 0, 6746.21923828125, -4679.30810546875, 725.61126708984375, 1.570796370506286621, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70557, 15565, 0, 1, 1, 0, -9413.2705078125, 154.28570556640625, 57.15481185913085937, 2.146754980087280273, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70560, 15595, 1, 1, 1, 0, 9768.0390625, 895.37969970703125, 1297.1431884765625, 1.256637096405029296, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70561, 15583, 1, 1, 1, 0, -7845.3271484375, -1330.454833984375, -264.4051513671875, 3.159045934677124023, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70562, 15582, 1, 1, 1, 0, -869.850341796875, -3725.603271484375, 24.465545654296875, 4.625122547149658203, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70563, 15600, 1, 1, 1, 0, 2465.03955078125, -6955.1005859375, 112.3233642578125, 1.762782573699951171, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70564, 15588, 1, 1, 1, 0, -2297.673095703125, -1948.052490234375, 96.3634033203125, 3.612831592559814453, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70565, 15597, 1, 1, 1, 0, -460.23675537109375, -2586.0419921875, 99.47601318359375, 5.131268024444580078, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70566, 15601, 1, 1, 1, 0, 6292.08349609375, 530.671142578125, 16.3725433349609375, 5.619960308074951171, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70567, 15598, 1, 1, 1, 0, 10137.390625, 2583.91943359375, 1325.581298828125, 4.380776405334472656, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70568, 15572, 1, 1, 1, 0, 269.454315185546875, -4777.17724609375, 11.90393257141113281, 1.605702877044677734, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70570, 15581, 1, 1, 1, 0, -4122.60009765625, 110.453887939453125, 75.884552001953125, 5.777040004730224609, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70571, 15587, 1, 1, 1, 0, -3806.537353515625, 1093.72412109375, 132.0525054931640625, 6.2657318115234375, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70572, 15575, 1, 1, 1, 0, -2103.056396484375, -438.983795166015625, -7.22763872146606445, 1.448623299598693847, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70573, 15603, 1, 1, 1, 0, 5101.40771484375, -527.39385986328125, 334.47119140625, 4.537856101989746093, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70574, 15599, 1, 1, 1, 0, -6832.98828125, 831.57269287109375, 49.53787612915039062, 2.617993831634521484, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70575, 15570, 1, 1, 1, 0, -6233.34423828125, 1733.2886962890625, 5.12093353271484375, 3.700098037719726562, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70576, 15586, 1, 1, 1, 0, -7155.89599609375, -3769.913330078125, 9.156195640563964843, 2.373647689819335937, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(70578, 15573, 1, 1, 1, 0, -9579.6787109375, -2723.700439453125, 13.93234825134277343, 5.532693862915039062, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(72236, 15584, 1, 1, 1, 0, -5435.712890625, -2431.921875, 89.36145782470703125, 5.427973747253417968, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(72237, 15604, 1, 1, 1, 0, -6226.63037109375, -3917.873291015625, -59.7433547973632812, 1.186823844909667968, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(72238, 15606, 1, 1, 1, 0, 6466.87890625, -4265.4501953125, 663.76055908203125, 0.767944872379302978, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(72239, 15563, 0, 1, 1, 0, -11791.8388671875, -3181.7333984375, -30.0804004669189453, 1.082104086875915527, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(75117, 15585, 0, 1, 1, 0, -7500.85693359375, -2154.5859375, 145.9892730712890625, 2.722713708877563476, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78371, 15569, 0, 1, 1, 0, -5571.5849609375, -503.6083984375, 403.09307861328125, 1.919862151145935058, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78372, 15596, 0, 1, 1, 0, -11954.2197265625, -1168.8167724609375, 77.74864959716796875, 0.506145477294921875, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78373, 15568, 0, 1, 1, 0, 2215.427001953125, 237.5364532470703125, 34.19980621337890625, 1.692969322204589843, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78374, 15577, 0, 1, 1, 0, -10498.71484375, 1034.0526123046875, 95.69647979736328125, 1.431169986724853515, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78375, 15549, 230, 1, 1, 0, 596.586181640625, -188.77130126953125, -54.0720634460449218, 0.104719758033752441, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78381, 15556, 349, 1, 1, 0, -139.935012817382812, -363.99603271484375, -170.335891723632812, 6.161012172698974609, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78382, 15578, 209, 1, 1, 0, 1689.035400390625, 1147.5692138671875, 8.960114479064941406, 2.373647689819335937, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78383, 15560, 229, 1, 1, 0, 67.81333160400390625, -537.54388427734375, 32.16370391845703125, 2.635447263717651367, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(78384, 15593, 109, 1, 1, 0, -414.8360595703125, 5.387812137603759765, -90.77197265625, 2.111848354339599609, 7200, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91562, 15576, 0, 1, 1, 0, -14424.630859375, 531.7750244140625, 24.88002777099609375, 5.16617441177368164, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91598, 15564, 0, 1, 1, 0, 1633.302734375, 233.931427001953125, 62.67490386962890625, 0.401425719261169433, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91603, 15580, 1, 1, 1, 0, -1012.6199951171875, -245.095108032226562, 159.3606719970703125, 0.244346097111701965, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91610, 15579, 1, 1, 1, 0, 1957.357666015625, -4257.51025390625, 31.610931396484375, 1.239183783531188964, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91630, 15562, 0, 1, 1, 0, -8761.9892578125, 1092.7117919921875, 94.8770751953125, 5.131268024444580078, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91631, 15871, 0, 1, 1, 0, -4659.20263671875, -944.4267578125, 500.461273193359375, 4.24114990234375, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91708, 15559, 0, 1, 1, 0, 233.455596923828125, -3499.972900390625, 161.0333099365234375, 0.78539818525314331, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91710, 15566, 0, 1, 1, 0, 2237.858154296875, -5340.40673828125, 84.71131134033203125, 1.134464025497436523, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91711, 15592, 0, 1, 1, 0, 1853.9935302734375, -3721.4453125, 162.307586669921875, 1.274090290069580078, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91712, 15602, 0, 1, 1, 0, 1995.8760986328125, -2420.165771484375, 59.38233566284179687, 2.722713708877563476, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL), +(91713, 15594, 0, 1, 1, 0, 1261.157470703125, -2558.26806640625, 118.2903671264648437, 0.506145477294921875, 120, 0, 0, 0, 0, 0, "", 47720, 1, NULL); + +-- enable all spawns for eventEntry 7 +DELETE FROM `game_event_creature` WHERE (`eventEntry` = 7) +AND (`guid` IN (SELECT `guid` FROM `creature` WHERE `id1` IN (15549, 15556, 15557, 15558, 15559, 15560, 15561, 15562, 15563, 15564, 15565, 15566, 15567, 15568, 15569, 15570, 15572, 15573, 15574, 15575, 15576, 15577, 15578, 15579, 15580, 15581, 15582, 15583, 15584, 15585, 15586, 15587, 15588, 15592, 15593, 15594, 15595, 15596, 15597, 15598, 15599, 15600, 15601, 15602, 15603, 15604, 15605, 15606, 15607, 15871, 30348, 30357, 30358, 30359, 30360, 30362, 30363, 30364, 30365, 30367, 30368, 30369, 30370, 30371, 30372, 30373, 30374, 30375, 30531, 30533, 30534, 30535, 30536, 30537, 30538))); +INSERT INTO `game_event_creature` (SELECT 7, `guid` FROM `creature` WHERE `id1` IN (15549, 15556, 15557, 15558, 15559, 15560, 15561, 15562, 15563, 15564, 15565, 15566, 15567, 15568, 15569, 15570, 15572, 15573, 15574, 15575, 15576, 15577, 15578, 15579, 15580, 15581, 15582, 15583, 15584, 15585, 15586, 15587, 15588, 15592, 15593, 15594, 15595, 15596, 15597, 15598, 15599, 15600, 15601, 15602, 15603, 15604, 15605, 15606, 15607, 15871, 30348, 30357, 30358, 30359, 30360, 30362, 30363, 30364, 30365, 30367, 30368, 30369, 30370, 30371, 30372, 30373, 30374, 30375, 30531, 30533, 30534, 30535, 30536, 30537, 30538)); From 9a268d43b98f8cd5e4efbc3fb4700800f9633b2e Mon Sep 17 00:00:00 2001 From: sudlud Date: Fri, 15 Nov 2024 15:32:55 +0100 Subject: [PATCH 103/105] =?UTF-8?q?fix(DB/Gameobject):=20Sniffed=20Values?= =?UTF-8?q?=20for=20'The=20Dark=20Portal=20and=20the=20Fall=20=E2=80=A6=20?= =?UTF-8?q?(#20576)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix(DB/Gameobject): Sniffed Values for 'The Dark Portal and the Fall of Stormwind' spawns --- .../pending_db_world/rev_1731657875138095000.sql | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 data/sql/updates/pending_db_world/rev_1731657875138095000.sql diff --git a/data/sql/updates/pending_db_world/rev_1731657875138095000.sql b/data/sql/updates/pending_db_world/rev_1731657875138095000.sql new file mode 100644 index 00000000000000..1d2ede29121c75 --- /dev/null +++ b/data/sql/updates/pending_db_world/rev_1731657875138095000.sql @@ -0,0 +1,10 @@ +-- Update gameobject 'The Dark Portal and the Fall of Stormwind' with sniffed values +-- updated spawns +DELETE FROM `gameobject` WHERE (`id` IN (175745)) +AND (`guid` IN (18578, 29686, 42442, 42618, 43218)); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`, `ScriptName`, `VerifiedBuild`, `Comment`) VALUES +(18578, 175745, 0, 0, 0, 1, 1, -8416.1337890625, 280.4483642578125, 122.0174713134765625, 3.839725255966186523, 0, 0, -0.93969249725341796, 0.34202045202255249, 120, 255, 1, "", 45854, NULL), +(29686, 175745, 0, 0, 0, 1, 1, -10462.3818359375, -3316.7744140625, 22.00571823120117187, 4.59021615982055664, 0, 0, -0.74895572662353515, 0.662620067596435546, 120, 255, 1, "", 45613, NULL), +(42442, 175745, 0, 0, 0, 1, 1, -10974.99609375, -3479.037841796875, 103.9837722778320312, 4.293513298034667968, 0, 0, -0.8386697769165039, 0.544640243053436279, 120, 255, 1, "", 48632, NULL), +(42618, 175745, 0, 0, 0, 1, 1, -9238.68359375, -2152.519287109375, 72.14923858642578125, 0.069811686873435974, 0, 0, 0.034898757934570312, 0.999390840530395507, 120, 255, 1, "", 45435, NULL), +(43218, 175745, 289, 0, 0, 1, 1, 231.8676300048828125, -4.19411897659301757, 117.05206298828125, 2.024578809738159179, 0, 0, 0.848047256469726562, 0.529920578002929687, 7200, 255, 1, "", 49345, NULL); From f9354b385b2d7e6da5b46393eb8fa6061d289c81 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 15 Nov 2024 14:33:18 +0000 Subject: [PATCH 104/105] chore(DB): import pending files Referenced commit(s): 1c449b303ab1b7f326a011cd2771f0bb6a45b237 --- .../rev_1731657875138095000.sql => db_world/2024_11_15_03.sql} | 1 + .../rev_1731673168265331400.sql => db_world/2024_11_15_04.sql} | 1 + 2 files changed, 2 insertions(+) rename data/sql/updates/{pending_db_world/rev_1731657875138095000.sql => db_world/2024_11_15_03.sql} (97%) rename data/sql/updates/{pending_db_world/rev_1731673168265331400.sql => db_world/2024_11_15_04.sql} (99%) diff --git a/data/sql/updates/pending_db_world/rev_1731657875138095000.sql b/data/sql/updates/db_world/2024_11_15_03.sql similarity index 97% rename from data/sql/updates/pending_db_world/rev_1731657875138095000.sql rename to data/sql/updates/db_world/2024_11_15_03.sql index 1d2ede29121c75..71a3b3a320fc4b 100644 --- a/data/sql/updates/pending_db_world/rev_1731657875138095000.sql +++ b/data/sql/updates/db_world/2024_11_15_03.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_15_02 -> 2024_11_15_03 -- Update gameobject 'The Dark Portal and the Fall of Stormwind' with sniffed values -- updated spawns DELETE FROM `gameobject` WHERE (`id` IN (175745)) diff --git a/data/sql/updates/pending_db_world/rev_1731673168265331400.sql b/data/sql/updates/db_world/2024_11_15_04.sql similarity index 99% rename from data/sql/updates/pending_db_world/rev_1731673168265331400.sql rename to data/sql/updates/db_world/2024_11_15_04.sql index 2b43d130da6373..bde45d2726be8f 100644 --- a/data/sql/updates/pending_db_world/rev_1731673168265331400.sql +++ b/data/sql/updates/db_world/2024_11_15_04.sql @@ -1,3 +1,4 @@ +-- DB update 2024_11_15_03 -> 2024_11_15_04 -- Update creature 'Lunar - Elders' with sniffed values -- updated spawns DELETE FROM `creature` WHERE (`id1` IN (30364, 30348, 30371, 30360, 30358, 30373, 30363, 30367, 30357, 30369, 30374, 30370, 30359, 30375, 30372, 30362, 30365, 30368, 30537, 30534, 30533, 30535, 30531, 30538, 30536, 15607, 15567, 15561, 15605, 15557, 15558, 15574, 15565, 15595, 15583, 15582, 15600, 15588, 15597, 15601, 15598, 15572, 15581, 15587, 15575, 15603, 15599, 15570, 15586, 15573, 15584, 15604, 15606, 15563, 15585, 15569, 15596, 15568, 15577, 15549, 15556, 15578, 15560, 15593, 15576, 15564, 15580, 15579, 15562, 15871, 15559, 15566, 15592, 15602, 15594)) From 905cc7b537de9967aadd8ac8aae782fa1616f50c Mon Sep 17 00:00:00 2001 From: sudlud Date: Fri, 15 Nov 2024 20:53:30 +0100 Subject: [PATCH 105/105] fix(conf/worldserver): add Logger.sql.updates option (#20578) --- src/server/apps/worldserver/worldserver.conf.dist | 1 + 1 file changed, 1 insertion(+) diff --git a/src/server/apps/worldserver/worldserver.conf.dist b/src/server/apps/worldserver/worldserver.conf.dist index ca79c6b08b7569..403e9756997470 100644 --- a/src/server/apps/worldserver/worldserver.conf.dist +++ b/src/server/apps/worldserver/worldserver.conf.dist @@ -781,6 +781,7 @@ Logger.spells.scripts=2,Console Errors #Logger.spells=4,Console Server #Logger.sql.dev=4,Console Server #Logger.sql.driver=4,Console Server +#Logger.sql.updates=4,Console Server #Logger.vehicles=4,Console Server #Logger.warden=4,Console Server #Logger.weather=4,Console Server