aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sql/updates/world/3.3.5/2017_99_99_99_world_335.sql11
-rw-r--r--src/server/game/Entities/Creature/Creature.cpp3
-rw-r--r--src/server/game/Entities/Creature/Creature.h1
-rw-r--r--src/server/scripts/Spells/spell_generic.cpp37
4 files changed, 13 insertions, 39 deletions
diff --git a/sql/updates/world/3.3.5/2017_99_99_99_world_335.sql b/sql/updates/world/3.3.5/2017_99_99_99_world_335.sql
new file mode 100644
index 00000000000..3d941c56bd0
--- /dev/null
+++ b/sql/updates/world/3.3.5/2017_99_99_99_world_335.sql
@@ -0,0 +1,11 @@
+
+-- Franclorn Forgewright
+SET @ENTRY := 8888;
+UPDATE `creature_template` SET `flags_extra`=`flags_extra`|0x400 WHERE `entry`=@ENTRY;
+
+-- Gaeriyan
+SET @ENTRY := 9299;
+UPDATE `creature_template` SET `flags_extra`=`flags_extra`|0x400 WHERE `entry`=@ENTRY;
+
+-- Shroud of Death Spell
+DELETE FROM `spell_script_names` WHERE spell_id=10848;
diff --git a/src/server/game/Entities/Creature/Creature.cpp b/src/server/game/Entities/Creature/Creature.cpp
index 51807373822..3ae04ccbe14 100644
--- a/src/server/game/Entities/Creature/Creature.cpp
+++ b/src/server/game/Entities/Creature/Creature.cpp
@@ -1015,8 +1015,7 @@ bool Creature::Create(ObjectGuid::LowType guidlow, Map* map, uint32 phaseMask, u
LastUsedScriptID = GetScriptId();
- /// @todo Replace with spell, handle from DB
- if (IsSpiritHealer() || IsSpiritGuide())
+ if (IsSpiritHealer() || IsSpiritGuide() || (GetCreatureTemplate()->flags_extra & CREATURE_FLAG_EXTRA_GHOST_VISIBILITY))
{
m_serverSideVisibility.SetValue(SERVERSIDE_VISIBILITY_GHOST, GHOST_VISIBILITY_GHOST);
m_serverSideVisibilityDetect.SetValue(SERVERSIDE_VISIBILITY_GHOST, GHOST_VISIBILITY_GHOST);
diff --git a/src/server/game/Entities/Creature/Creature.h b/src/server/game/Entities/Creature/Creature.h
index dcffc7e0051..20969df4693 100644
--- a/src/server/game/Entities/Creature/Creature.h
+++ b/src/server/game/Entities/Creature/Creature.h
@@ -50,6 +50,7 @@ enum CreatureFlagsExtra
CREATURE_FLAG_EXTRA_TRIGGER = 0x00000080, // trigger creature
CREATURE_FLAG_EXTRA_NO_TAUNT = 0x00000100, // creature is immune to taunt auras and effect attack me
CREATURE_FLAG_EXTRA_NO_MOVE_FLAGS_UPDATE = 0x00000200, // creature won't update movement flags
+ CREATURE_FLAG_EXTRA_GHOST_VISIBILITY = 0x00000400, // creature will be only visible for dead players
CREATURE_FLAG_EXTRA_WORLDEVENT = 0x00004000, // custom flag for world event creatures (left room for merging)
CREATURE_FLAG_EXTRA_GUARD = 0x00008000, // Creature is guard
CREATURE_FLAG_EXTRA_NO_CRIT = 0x00020000, // creature can't do critical strikes
diff --git a/src/server/scripts/Spells/spell_generic.cpp b/src/server/scripts/Spells/spell_generic.cpp
index b055c9f6fbe..e8528297ed0 100644
--- a/src/server/scripts/Spells/spell_generic.cpp
+++ b/src/server/scripts/Spells/spell_generic.cpp
@@ -4243,42 +4243,6 @@ class spell_gen_pony_mount_check : public SpellScriptLoader
}
};
-class spell_gen_shroud_of_death : public SpellScriptLoader
-{
- public:
- spell_gen_shroud_of_death() : SpellScriptLoader("spell_gen_shroud_of_death") { }
-
- class spell_gen_shroud_of_death_AuraScript : public AuraScript
- {
- PrepareAuraScript(spell_gen_shroud_of_death_AuraScript);
-
- void OnApply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
- {
- PreventDefaultAction();
- GetUnitOwner()->m_serverSideVisibility.SetValue(SERVERSIDE_VISIBILITY_GHOST, GHOST_VISIBILITY_GHOST);
- GetUnitOwner()->m_serverSideVisibilityDetect.SetValue(SERVERSIDE_VISIBILITY_GHOST, GHOST_VISIBILITY_GHOST);
- }
-
- void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
- {
- PreventDefaultAction();
- GetUnitOwner()->m_serverSideVisibility.SetValue(SERVERSIDE_VISIBILITY_GHOST, GHOST_VISIBILITY_ALIVE);
- GetUnitOwner()->m_serverSideVisibilityDetect.SetValue(SERVERSIDE_VISIBILITY_GHOST, GHOST_VISIBILITY_ALIVE);
- }
-
- void Register() override
- {
- OnEffectApply += AuraEffectApplyFn(spell_gen_shroud_of_death_AuraScript::OnApply, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
- OnEffectRemove += AuraEffectRemoveFn(spell_gen_shroud_of_death_AuraScript::OnRemove, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
- }
- };
-
- AuraScript* GetAuraScript() const override
- {
- return new spell_gen_shroud_of_death_AuraScript();
- }
-};
-
void AddSC_generic_spell_scripts()
{
new spell_gen_absorb0_hitlimit1();
@@ -4378,5 +4342,4 @@ void AddSC_generic_spell_scripts()
new spell_gen_landmine_knockback_achievement();
new spell_gen_clear_debuffs();
new spell_gen_pony_mount_check();
- new spell_gen_shroud_of_death();
}