/// <inheritdoc/> public sealed override void Dispose() { OnDispose(); if (Effect != null) { DestroyEffect(Effect); } BuffSystem.Remove(this); }
/// <inheritdoc/> public sealed override void Dispose() { OnDispose(); if (Effect != null) { DestroyEffect(Effect); } BuffSystem.Remove(this); if (this.auraId > 0) { if (BuffSystem.GetBuffsOnUnit(Target).OfType <BoundBuff>().All(x => x.auraId != this.auraId)) { UnitRemoveAbility(Target, this.auraId); UnitRemoveAbility(Target, this.buffId); } } else if (BuffSystem.GetBuffsOnUnit(Target).OfType <BoundBuff>().All(x => x.buffId != this.buffId)) { UnitRemoveAbility(Target, this.buffId); } }