Core/Scripts Boss Lady DeathWhisper improvements

This commit is contained in:
Gustavo authored and Aokromes committed 2016-10-24 13:26:40 +02:00
1 parent ff53b66933
commit d82abaa2ac
3 files changed
+455 -406

No files matched your search

@@ -1123,9 +1123,17 @@ class spell_gen_creature_permanent_feign_death : public SpellScriptLoader
target->ToCreature()->SetReactState(REACT_PASSIVE);
}
void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
{
Unit* target = GetTarget();
target->RemoveFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_DEAD);
target->RemoveFlag(UNIT_FIELD_FLAGS_2, UNIT_FLAG2_FEIGN_DEATH);
}
void Register() override
{
OnEffectApply += AuraEffectApplyFn(spell_gen_creature_permanent_feign_death_AuraScript::HandleEffectApply, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
OnEffectRemove += AuraEffectRemoveFn(spell_gen_creature_permanent_feign_death_AuraScript::OnRemove, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL);
}
};