Пример #1
0
    void HandleInput()
    {
        IDragonState _state = state.HandleInput(this, inputSource);

        if (_state != null)
        {
            ClearAnimations();
            state = _state;
            state.Enter(this);
        }
    }
Пример #2
0
 private void Start()
 {
     state = new IdlingState();
     if (isRobot)
     {
         inputSource = GetComponent <DragonRobot>();
     }
     else
     {
         inputSource = GetComponent <PlayerInput>();
     }
     animator = GetComponent <Animator>();
 }
Пример #3
0
 public PlayerAnimator(IDragonState state)
 {
     this.state        = state;
     current_animation = PlayerAnimations.Stand;
 }