Skip to content

GamepadAxis

1 min read

Import: import system.window;

Read the usage guide for examples and common tasks. This reference lists the public declarations for this part of the library. See Reading API signatures for parameter and result notation.

GamepadAxis

An analog control on a standard-layout gamepad. Stick axes range from -1.0 to 1.0; positive X is right and positive Y is down. Trigger axes range from 0.0 (released) to 1.0 (fully pressed).

public enum GamepadAxis

LeftX

Horizontal position of the left stick.

LeftX = 0

LeftY

Vertical position of the left stick.

LeftY = 1

RightX

Horizontal position of the right stick.

RightX = 2

RightY

Vertical position of the right stick.

RightY = 3

LeftTrigger

How far the left trigger is pressed.

LeftTrigger = 4

RightTrigger

How far the right trigger is pressed.

RightTrigger = 5