mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-26 07:06:23 +00:00
fix(scripts/DB): Implement "Marked immortal guardian" (#5046)
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
INSERT INTO `version_db_world` (`sql_rev`) VALUES ('1616977871251124200');
|
||||
|
||||
-- Add IA for 'Marked immortal guardian'
|
||||
UPDATE `creature_template` SET `ScriptName`='boss_yoggsaron_immortal_guardian' WHERE `entry`=36064;
|
||||
-- Match "Immortal Guardian" values with "Marked immortal guardian"
|
||||
UPDATE `creature_template` SET `speed_walk`=1.6, `speed_run`=1.71429, `DamageModifier`=7.5, `mechanic_immune_mask`=617299839, `flags_extra`=1073741824 WHERE `entry` IN (36064, 36067);
|
||||
UPDATE `creature_template` SET `DamageModifier`=8 WHERE `entry` IN (33989, 36067); -- 25mode
|
||||
-- Add script into DB
|
||||
DELETE FROM `spell_script_names` WHERE `spell_id`=64465 AND `ScriptName`='spell_yogg_saron_shadow_beacon';
|
||||
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES (64465, 'spell_yogg_saron_shadow_beacon');
|
||||
-- Add/rework conditions for effect 'Titanic Storm'
|
||||
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`=64172;
|
||||
INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorType`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES
|
||||
(13,1,64172,0,0,31,0,3,33988,0,0,0,0,'','Titanic Storm on Immortal Guardian'),
|
||||
(13,1,64172,0,1,31,0,3,36064,0,0,0,0,'','Titanic Storm on Marked Immortal Guardian');
|
||||
|
||||
@@ -181,6 +181,7 @@ enum NPCsGOs
|
||||
NPC_LAUGHING_SKULL = 33990,
|
||||
|
||||
NPC_IMMORTAL_GUARDIAN = 33988,
|
||||
NPC_MARKED_IMMORTAL_GUARDIAN = 36064,
|
||||
|
||||
// CHAMBER ILLUSION
|
||||
NPC_CONSORT_FIRST = 33716,
|
||||
@@ -2400,6 +2401,44 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
class spell_yogg_saron_shadow_beacon : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_yogg_saron_shadow_beacon() : SpellScriptLoader("spell_yogg_saron_shadow_beacon") { }
|
||||
|
||||
class spell_yogg_saron_shadow_beacon_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_yogg_saron_shadow_beacon_AuraScript);
|
||||
|
||||
void OnApply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
|
||||
{
|
||||
if (Creature* target = GetTarget()->ToCreature())
|
||||
{
|
||||
target->SetEntry(NPC_MARKED_IMMORTAL_GUARDIAN);
|
||||
}
|
||||
}
|
||||
|
||||
void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
|
||||
{
|
||||
if (Creature* target = GetTarget()->ToCreature())
|
||||
{
|
||||
target->SetEntry(NPC_IMMORTAL_GUARDIAN);
|
||||
}
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
AfterEffectApply += AuraEffectApplyFn(spell_yogg_saron_shadow_beacon_AuraScript::OnApply, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL, AURA_EFFECT_HANDLE_REAL);
|
||||
AfterEffectRemove += AuraEffectRemoveFn(spell_yogg_saron_shadow_beacon_AuraScript::OnRemove, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL, AURA_EFFECT_HANDLE_REAL);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const override
|
||||
{
|
||||
return new spell_yogg_saron_shadow_beacon_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
class spell_yogg_saron_destabilization_matrix : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
@@ -2995,6 +3034,7 @@ void AddSC_boss_yoggsaron()
|
||||
// SPELLS
|
||||
new spell_yogg_saron_malady_of_the_mind();
|
||||
new spell_yogg_saron_brain_link();
|
||||
new spell_yogg_saron_shadow_beacon();
|
||||
new spell_yogg_saron_destabilization_matrix();
|
||||
new spell_yogg_saron_titanic_storm();
|
||||
new spell_yogg_saron_lunatic_gaze();
|
||||
|
||||
Reference in New Issue
Block a user