public override void Init(Affix af, GameObject o) { base.Init(af, o); type = Affix.EffectType.HideBuff; attr = obj.GetComponent <NpcAttribute>(); attr.HideMe(); obj.GetComponent <MyAnimationEvent>().AddCallBackLocalEvent(MyEvent.EventType.UseSkill, Over); obj.GetComponent <MyAnimationEvent>().AddCallBackLocalEvent(MyEvent.EventType.BeHit, Over); }