Enum amethyst_input::Axis[][src]

pub enum Axis {
    Emulated {
        pos: Button,
        neg: Button,
    },
    Controller {
        controller_id: u32,
        axis: ControllerAxis,
        invert: bool,
        dead_zone: f64,
    },
}

Represents any input represented by a float value from -1 to 1. Retrieve the value of this with axis_value.

Variants

Represents an emulated analogue axis made up of pair of digital inputs, like W and S keyboard buttons or DPadUp and DPadDown controller buttons.

Fields of Emulated

Positive button, when pressed down axis value will return 1 if neg is not pressed down.

Negative button, when pressed down axis value will return -1 if pos is not pressed down.

Represents an analogue axis of a controller.

Fields of Controller

A number representing specific controller, assigned and reused in order of connection.

Treat input values from -dead_zone to dead_zone as 0, linearly interpolate remaining ranges.

Trait Implementations

impl Clone for Axis
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl Send for Axis

impl Sync for Axis