C# Класс SFML.Window.Joystick

Give access to the real-time state of the joysticks
Показать файл Открыть проект

Открытые свойства

Свойство Тип Описание
AxisCount uint
ButtonCount uint
Count uint

Открытые методы

Метод Описание
GetAxisPosition ( uint joystick, Axis axis ) : float

Get the current position of a joystick axis

GetButtonCount ( uint joystick ) : uint

Return the number of buttons supported by a joystick

GetIdentification ( uint joystick ) : Identification

Get the joystick information

HasAxis ( uint joystick, Axis axis ) : bool

Check if a joystick supports a given axis

IsButtonPressed ( uint joystick, uint button ) : bool

Check if a joystick button is pressed

IsConnected ( uint joystick ) : bool

Check if a joystick is connected

Update ( ) : void

Update the states of all joysticks

Приватные методы

Метод Описание
sfJoystick_getAxisPosition ( uint joystick, Axis axis ) : float
sfJoystick_getButtonCount ( uint joystick ) : uint
sfJoystick_getIdentification ( uint joystick ) : IdentificationMarshalData
sfJoystick_hasAxis ( uint joystick, Axis axis ) : bool
sfJoystick_isButtonPressed ( uint joystick, uint button ) : bool
sfJoystick_isConnected ( uint joystick ) : bool
sfJoystick_update ( ) : void

Описание методов

GetAxisPosition() публичный статический Метод

Get the current position of a joystick axis
public static GetAxisPosition ( uint joystick, Axis axis ) : float
joystick uint Index of the joystick
axis Axis Axis to check
Результат float

GetButtonCount() публичный статический Метод

Return the number of buttons supported by a joystick
public static GetButtonCount ( uint joystick ) : uint
joystick uint Index of the joystick
Результат uint

GetIdentification() публичный статический Метод

Get the joystick information
public static GetIdentification ( uint joystick ) : Identification
joystick uint Index of the joystick
Результат Identification

HasAxis() публичный статический Метод

Check if a joystick supports a given axis
public static HasAxis ( uint joystick, Axis axis ) : bool
joystick uint Index of the joystick
axis Axis Axis to check
Результат bool

IsButtonPressed() публичный статический Метод

Check if a joystick button is pressed
public static IsButtonPressed ( uint joystick, uint button ) : bool
joystick uint Index of the joystick
button uint Button to check
Результат bool

IsConnected() публичный статический Метод

Check if a joystick is connected
public static IsConnected ( uint joystick ) : bool
joystick uint Index of the joystick to check
Результат bool

Update() публичный статический Метод

Update the states of all joysticks
public static Update ( ) : void
Результат void

Описание свойств

AxisCount публичное статическое свойство

Maximum number of supported axes
public static uint AxisCount
Результат uint

ButtonCount публичное статическое свойство

Maximum number of supported buttons
public static uint ButtonCount
Результат uint

Count публичное статическое свойство

Maximum number of supported joysticks
public static uint Count
Результат uint