Beispiel #1
0
        public PlaybackState(Vector3 position, Quaternion rotation, float triggerActuation, InputManager.InputState.ActiveFunction buttons = InputManager.InputState.ActiveFunction.None)
        {
            this.position         = new Vector3(position.x, position.y, position.z);
            this.rotation         = new Quaternion(rotation.x, rotation.y, rotation.z, rotation.w);
            this.triggerActuation = triggerActuation;

            this.buttons = buttons;
        }
Beispiel #2
0
    private void OnTouchpadPress(object sender, ControllerInteractionEventArgs e)
    {
        Vector2 axis = e.touchpadAxis;

        InputManager.InputState.ActiveFunction activeFunction = InputManager.InputState.ActiveFunction.None;

        // Only support two playbacks for now
        if (axis.y < 0.5)
        {
            activeFunction = InputManager.InputState.ActiveFunction.SequencePlayback0;
        }
        else
        {
            activeFunction = InputManager.InputState.ActiveFunction.SequencePlayback1;
        }

        GetInputState(e).AddButton(activeFunction);
    }