Exemplo n.º 1
0
        public uint RegisterMsg(string Animation, float Percent, CombatMsgCode MsgCode, Action <string, CombatMsgCode> Callback)
        {
            var Msg = new NpcAnimationMsg(Animation, Percent, MsgCode, Callback);

            MsgList_.Add(Msg);
            return(Msg.ID);
        }
Exemplo n.º 2
0
 public override void OnMsgCode(string Animation, CombatMsgCode MsgCode)
 {
     if (MsgCode == CombatMsgCode.Atk)
     {
         OnAtkMsg();
     }
 }
Exemplo n.º 3
0
 internal NpcAnimationMsg(string Animation, float Percent, CombatMsgCode MsgCode, Action <string, CombatMsgCode> Callback)
 {
     this.ID         = IDGenerator.Get();
     this.Animation_ = Animation;
     this.Percent_   = Mathf.Clamp01(Percent);
     this.MsgCode_   = MsgCode;
     this.Callback_  = Callback;
 }
Exemplo n.º 4
0
        public void OnMsgCode(string Animation, CombatMsgCode MsgCode)
        {
            foreach (var Handler in HandlerList_)
            {
                if (Handler.OnMsgCode(Animation, MsgCode))
                {
                    return;
                }
            }

            CurrentState_?.OnMsgCode(Animation, MsgCode);
        }
Exemplo n.º 5
0
 public virtual void OnMsgCode(string Animation, CombatMsgCode MsgCode)
 {
 }
Exemplo n.º 6
0
 public virtual bool OnMsgCode(string Animation, CombatMsgCode MsgCode)
 {
     return(false);
 }
Exemplo n.º 7
0
 public uint RegisterMsg(string Animation, float Percent, CombatMsgCode MsgCode)
 {
     return(Animation_.RegisterMsg(Animation, Percent, MsgCode, OnMsgCode));
 }
Exemplo n.º 8
0
 private void OnMsgCode(string Animation, CombatMsgCode MsgCode)
 {
     Fsm_.OnMsgCode(Animation, MsgCode);
 }