summaryrefslogtreecommitdiff
path: root/src/server
diff options
context:
space:
mode:
authorAndrew <47818697+Nyeriah@users.noreply.github.com>2025-09-23 05:44:35 -0300
committerGitHub <noreply@github.com>2025-09-23 10:44:35 +0200
commit42d49d1b6aeb44632cf97dc522ee97569d784692 (patch)
treee4c6cbb79577a75d274c23282453edc324315807 /src/server
parenta5502ad0bf7e6841dae29773f235c82f63006d50 (diff)
fix(Core/Vehicles): Fix issue with Wyrmrest Vanquisher and other issues with On Ruby Wings (#22989)
Diffstat (limited to 'src/server')
-rw-r--r--src/server/game/Spells/SpellInfoCorrections.cpp2
-rw-r--r--src/server/scripts/Northrend/zone_dragonblight.cpp62
2 files changed, 64 insertions, 0 deletions
diff --git a/src/server/game/Spells/SpellInfoCorrections.cpp b/src/server/game/Spells/SpellInfoCorrections.cpp
index e5360809f3..9873af3253 100644
--- a/src/server/game/Spells/SpellInfoCorrections.cpp
+++ b/src/server/game/Spells/SpellInfoCorrections.cpp
@@ -5287,6 +5287,8 @@ void SpellMgr::LoadSpellInfoCorrections()
vse->m_flags &= ~VEHICLE_SEAT_FLAG_PASSENGER_NOT_SELECTABLE;
vse = const_cast<VehicleSeatEntry*>(sVehicleSeatStore.LookupEntry(4693)); // Siege Engine, Accessory
vse->m_flags &= ~VEHICLE_SEAT_FLAG_PASSENGER_NOT_SELECTABLE;
+ vse = const_cast<VehicleSeatEntry*>(sVehicleSeatStore.LookupEntry(1520)); // Wyrmrest Vanquisher
+ vse->m_flags |= VEHICLE_SEAT_FLAG_PASSENGER_NOT_SELECTABLE;
// pussywizard: fix z offset for some vehicles:
vse = const_cast<VehicleSeatEntry*>(sVehicleSeatStore.LookupEntry(6206)); // Marrowgar - Bone Spike
diff --git a/src/server/scripts/Northrend/zone_dragonblight.cpp b/src/server/scripts/Northrend/zone_dragonblight.cpp
index e1f50f3cde..52aac2193b 100644
--- a/src/server/scripts/Northrend/zone_dragonblight.cpp
+++ b/src/server/scripts/Northrend/zone_dragonblight.cpp
@@ -2271,6 +2271,66 @@ private:
}
};
+enum DevourGhoulSpells
+{
+ SPELL_DEVOUR_GHOUL_RIDE_VEHICLE = 50437,
+ SPELL_DEVOUR_PERIODIC = 50432,
+ SPELL_NOURISHMENT = 50443
+};
+
+// 50430 - Devour Ghoul
+class spell_dragonblight_devour_ghoul: public SpellScript
+{
+ PrepareSpellScript(spell_dragonblight_devour_ghoul);
+
+ bool Validate(SpellInfo const* /*spellInfo*/) override
+ {
+ return ValidateSpellInfo({ SPELL_DEVOUR_GHOUL_RIDE_VEHICLE });
+ }
+
+ void HandleScriptEffect(SpellEffIndex /*effIndex*/)
+ {
+ if (GetCaster())
+ {
+ GetHitUnit()->CastSpell(GetCaster(), SPELL_DEVOUR_GHOUL_RIDE_VEHICLE, true);
+ GetCaster()->CastSpell(GetHitUnit(), SPELL_DEVOUR_PERIODIC, true);
+ }
+ }
+
+ void Register() override
+ {
+ OnEffectHitTarget += SpellEffectFn(spell_dragonblight_devour_ghoul::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT);
+ }
+};
+
+// 50432 - Devour Ghoul
+class spell_dragonblight_devour_ghoul_periodic : public AuraScript
+{
+ PrepareAuraScript(spell_dragonblight_devour_ghoul_periodic);
+
+ bool Validate(SpellInfo const* /*spellInfo*/) override
+ {
+ return ValidateSpellInfo({ SPELL_NOURISHMENT });
+ }
+
+ void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
+ {
+ if (GetTargetApplication()->GetRemoveMode() == AURA_REMOVE_BY_EXPIRE && GetCaster())
+ GetCaster()->CastSpell(GetCaster(), SPELL_NOURISHMENT, true);
+
+ if (GetUnitOwner() && GetUnitOwner()->ToCreature())
+ {
+ GetUnitOwner()->ExitVehicle();
+ GetUnitOwner()->ToCreature()->DespawnOrUnsummon(2000);
+ }
+ }
+
+ void Register() override
+ {
+ OnEffectRemove += AuraEffectRemoveFn(spell_dragonblight_devour_ghoul_periodic::OnRemove, EFFECT_0, SPELL_AURA_PERIODIC_DAMAGE, AURA_EFFECT_HANDLE_REAL);
+ }
+};
+
void AddSC_dragonblight()
{
new npc_conversing_with_the_depths_trigger();
@@ -2299,4 +2359,6 @@ void AddSC_dragonblight()
RegisterSpellScript(spell_dragonblight_corrosive_spit);
RegisterSpellScript(spell_handover_reins);
RegisterSpellScript(spell_dragonblight_flame_fury);
+ RegisterSpellScript(spell_dragonblight_devour_ghoul);
+ RegisterSpellScript(spell_dragonblight_devour_ghoul_periodic);
}