Core/Spell: Properly remove REACT_PASSIVE on permanent feign death unapply.
Port From (https://github.com/TrinityCore/TrinityCore/commit/ffce2c1f9a416eddad2e45ab2e03df964d5e39cd)
This commit is contained in:
@@ -1203,8 +1203,9 @@ namespace Scripts.Spells.Generic
|
||||
target.AddDynamicFlag(UnitDynFlags.Dead);
|
||||
target.AddUnitFlag2(UnitFlags2.FeignDeath);
|
||||
|
||||
if (target.IsTypeId(TypeId.Unit))
|
||||
target.ToCreature().SetReactState(ReactStates.Passive);
|
||||
Creature creature = target.ToCreature();
|
||||
if (creature != null)
|
||||
creature.SetReactState(ReactStates.Passive);
|
||||
}
|
||||
|
||||
void OnRemove(AuraEffect aurEff, AuraEffectHandleModes mode)
|
||||
@@ -1212,6 +1213,10 @@ namespace Scripts.Spells.Generic
|
||||
Unit target = GetTarget();
|
||||
target.RemoveDynamicFlag(UnitDynFlags.Dead);
|
||||
target.RemoveUnitFlag2(UnitFlags2.FeignDeath);
|
||||
|
||||
Creature creature = target.ToCreature();
|
||||
if (creature != null)
|
||||
creature.InitializeReactState();
|
||||
}
|
||||
|
||||
public override void Register()
|
||||
|
||||
Reference in New Issue
Block a user