diff options
-rw-r--r-- | sql/updates/world/3.3.5/2025_02_10_00_world.sql | 10 | ||||
-rw-r--r-- | src/server/game/Spells/SpellMgr.cpp | 46 | ||||
-rw-r--r-- | src/server/scripts/Events/pilgrims_bounty.cpp | 35 |
3 files changed, 56 insertions, 35 deletions
diff --git a/sql/updates/world/3.3.5/2025_02_10_00_world.sql b/sql/updates/world/3.3.5/2025_02_10_00_world.sql new file mode 100644 index 00000000000..2fb1141b500 --- /dev/null +++ b/sql/updates/world/3.3.5/2025_02_10_00_world.sql @@ -0,0 +1,10 @@ +-- +DELETE FROM `spell_script_names` WHERE `ScriptName` IN ( + 'spell_gen_slow_roasted_turkey', + 'spell_gen_cranberry_chutney', + 'spell_gen_spice_bread_stuffing', + 'spell_gen_pumpkin_pie', + 'spell_gen_candied_sweet_potato' +); + +DELETE FROM `spell_linked_spell` WHERE `spell_effect` = 24870; diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp index a789836277e..3dfd8dc16e4 100644 --- a/src/server/game/Spells/SpellMgr.cpp +++ b/src/server/game/Spells/SpellMgr.cpp @@ -4912,6 +4912,52 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->RangeEntry = sSpellRangeStore.LookupEntry(5); // 40yd }); + // Pilgrim's Bounty - Candied Sweet Potato + ApplySpellFix({ 65418 }, [](SpellInfo* spellInfo) + { + spellInfo->_GetEffect(EFFECT_2).TriggerSpell = 65410; + }); + + // Pilgrim's Bounty - Spice Bread Stuffing + ApplySpellFix({ 65419 }, [](SpellInfo* spellInfo) + { + spellInfo->_GetEffect(EFFECT_2).TriggerSpell = 65416; + }); + + // Pilgrim's Bounty - Cranberry Chutney + ApplySpellFix({ 65420 }, [](SpellInfo* spellInfo) + { + spellInfo->_GetEffect(EFFECT_2).TriggerSpell = 65412; + }); + + // Pilgrim's Bounty - Pumpkin Pie + ApplySpellFix({ 65421 }, [](SpellInfo* spellInfo) + { + spellInfo->_GetEffect(EFFECT_2).TriggerSpell = 65415; + }); + + // Pilgrim's Bounty - Slow-Roasted Turkey + ApplySpellFix({ 65422 }, [](SpellInfo* spellInfo) + { + spellInfo->_GetEffect(EFFECT_2).TriggerSpell = 65414; + }); + + ApplySpellFix({ + 24869, // Bobbing Apple, Bread of the Dead, Winter Veil Cookie + 61874, // Noblegarden Chocolate + 71068, // Sweet Surprise + 71071, // Very Berry Cream + 71073, // Dark Desire + 71074 // Buttermilk Delight + }, [](SpellInfo* spellInfo) + { + spellInfo->_GetEffect(EFFECT_1).Effect = SPELL_EFFECT_APPLY_AURA; + spellInfo->_GetEffect(EFFECT_1).TargetA = SpellImplicitTargetInfo(TARGET_UNIT_CASTER); + spellInfo->_GetEffect(EFFECT_1).ApplyAuraName = SPELL_AURA_PERIODIC_TRIGGER_SPELL; + spellInfo->_GetEffect(EFFECT_1).Amplitude = 10 * IN_MILLISECONDS; + spellInfo->_GetEffect(EFFECT_1).TriggerSpell = 24870; + }); + for (uint32 i = 0; i < GetSpellInfoStoreSize(); ++i) { SpellInfo* spellInfo = mSpellInfoMap[i]; diff --git a/src/server/scripts/Events/pilgrims_bounty.cpp b/src/server/scripts/Events/pilgrims_bounty.cpp index b61bb81f6e0..b078fbf0d40 100644 --- a/src/server/scripts/Events/pilgrims_bounty.cpp +++ b/src/server/scripts/Events/pilgrims_bounty.cpp @@ -33,36 +33,6 @@ enum PilgrimsBountyBuffFood SPELL_WELL_FED_SPIRIT_TRIGGER = 65415 }; -class spell_pilgrims_bounty_buff_food : public AuraScript -{ - PrepareAuraScript(spell_pilgrims_bounty_buff_food); -private: - uint32 const _triggeredSpellId; - -public: - spell_pilgrims_bounty_buff_food(uint32 triggeredSpellId) : AuraScript(), _triggeredSpellId(triggeredSpellId) - { - _handled = false; - } - - void HandleTriggerSpell(AuraEffect const* /*aurEff*/) - { - PreventDefaultAction(); - if (_handled) - return; - - _handled = true; - GetTarget()->CastSpell(GetTarget(), _triggeredSpellId, true); - } - - void Register() override - { - OnEffectPeriodic += AuraEffectPeriodicFn(spell_pilgrims_bounty_buff_food::HandleTriggerSpell, EFFECT_2, SPELL_AURA_PERIODIC_TRIGGER_SPELL); - } - - bool _handled; -}; - enum FeastOnSpells { FEAST_ON_TURKEY = 61784, @@ -449,11 +419,6 @@ private: void AddSC_event_pilgrims_bounty() { - RegisterSpellScriptWithArgs(spell_pilgrims_bounty_buff_food, "spell_gen_slow_roasted_turkey", SPELL_WELL_FED_AP_TRIGGER); - RegisterSpellScriptWithArgs(spell_pilgrims_bounty_buff_food, "spell_gen_cranberry_chutney", SPELL_WELL_FED_ZM_TRIGGER); - RegisterSpellScriptWithArgs(spell_pilgrims_bounty_buff_food, "spell_gen_spice_bread_stuffing", SPELL_WELL_FED_HIT_TRIGGER); - RegisterSpellScriptWithArgs(spell_pilgrims_bounty_buff_food, "spell_gen_pumpkin_pie", SPELL_WELL_FED_SPIRIT_TRIGGER); - RegisterSpellScriptWithArgs(spell_pilgrims_bounty_buff_food, "spell_gen_candied_sweet_potato", SPELL_WELL_FED_HASTE_TRIGGER); RegisterSpellScript(spell_pilgrims_bounty_feast_on); RegisterSpellScriptWithArgs(spell_pilgrims_bounty_well_fed, "spell_pilgrims_bounty_well_fed_turkey", SPELL_WELL_FED_AP_TRIGGER); RegisterSpellScriptWithArgs(spell_pilgrims_bounty_well_fed, "spell_pilgrims_bounty_well_fed_cranberry", SPELL_WELL_FED_ZM_TRIGGER); |