Esempio n. 1
0
        public void SwitchState(NormlWalkSubState state)
        {
            if (this.curState != state)
            {
                switch (this.curState)
                {
                case NormlWalkSubState.none: OnLeave_none();
                    break;

                case NormlWalkSubState.beControl: OnLeave_beControl();
                    break;

                case NormlWalkSubState.move: OnLeave_move();
                    break;

                case NormlWalkSubState.charge: OnLeave_charge();
                    break;

                default:
                    break;
                }

                this.curState = state;

                switch (this.curState)
                {
                case NormlWalkSubState.none: OnBefore_none();
                    break;

                case NormlWalkSubState.beControl: OnBefore_beControl();
                    break;

                case NormlWalkSubState.move: OnBefore_move();
                    break;

                case NormlWalkSubState.charge: OnBefore_charge();
                    break;

                default:
                    break;
                }
            }
        }
Esempio n. 2
0
 public override void DoBeforeEntering()
 {
     this.curState = NormlWalkSubState.none;
 }
 public override void DoBeforeEntering()
 {
     this.curState = NormlWalkSubState.none;
 }
        public void SwitchState(NormlWalkSubState state)
        {
            if (this.curState != state)
            {
                switch (this.curState)
                {
                    case NormlWalkSubState.none: OnLeave_none();
                        break;
                    case NormlWalkSubState.beControl: OnLeave_beControl();
                        break;
                    case NormlWalkSubState.move: OnLeave_move();
                        break;
                    case NormlWalkSubState.charge: OnLeave_charge();
                        break;
                    default:
                        break;
                }

                this.curState = state;

                switch (this.curState)
                {
                    case NormlWalkSubState.none: OnBefore_none();
                        break;
                    case NormlWalkSubState.beControl: OnBefore_beControl();
                        break;
                    case NormlWalkSubState.move: OnBefore_move();
                        break;
                    case NormlWalkSubState.charge: OnBefore_charge();
                        break;
                    default:
                        break;
                }
            }
        }