Class Input

Namespace
Elegy.InputSystem.API
Assembly
Elegy.InputSystem.dll

Simple access to input functions. Key presses, mouse coordinates etc.

public static class Input
Inheritance
Input
Inherited Members

Properties

Gamepads

Gets a list of active gamepads. Gamepads are simple controllers with buttons.

public static IReadOnlyList<IGamepad> Gamepads { get; }

Property Value

IReadOnlyList<IGamepad>

Joysticks

Gets a list of active joysticks. Joysticks are gamepads with analogue sticks and other features.

public static IReadOnlyList<IJoystick> Joysticks { get; }

Property Value

IReadOnlyList<IJoystick>

Keyboard

Gets the current keyboard.

public static IKeyboard Keyboard { get; }

Property Value

IKeyboard

Mouse

Gets the current mouse.

public static IMouse Mouse { get; }

Property Value

IMouse

State

Gets the current input state. It can change between windows.

public static IInputContext State { get; }

Property Value

IInputContext

Methods

Init(in LaunchConfig)

public static bool Init(in LaunchConfig config)

Parameters

config LaunchConfig

Returns

bool

OnConnectionChanged(Action<IInputDevice, bool>)

Registers an action to execute when a device connects/disconnects.

public static void OnConnectionChanged(Action<IInputDevice, bool> action)

Parameters

action Action<IInputDevice, bool>

PostInit()

public static void PostInit()

Shutdown()

public static void Shutdown()