Esempio n. 1
0
        public void OnKeyUp(KeyBindings.GameInput key)
        {
            switch (key)
            {
            case KeyBindings.GameInput.Left:
            case KeyBindings.GameInput.Right: state = State.Standing; break;

            default:
                break;
            }
        }
Esempio n. 2
0
        public void OnKeyDown(KeyBindings.GameInput key)
        {
            switch (key)
            {
            case KeyBindings.GameInput.Left:
            {
                state            = State.Running;
                lookingDirection = LookingDirection.Left;
                break;
            };

            case KeyBindings.GameInput.Right:
            {
                state            = State.Running;
                lookingDirection = LookingDirection.Right;
                break;
            };

            default:
                break;
            }
        }
Esempio n. 3
0
 public bool IsKeyDown(KeyBindings.GameInput key)
 {
     return(frameRef.IsKeyDown(key));
 }