Input Action
Like what your seeing?
Support us as a GitHub Sponsor and get instant access to all our assets, exclusive tools and assets, escalated support and issue tracking and our gratitude. These articles are made possible by our GitHub Sponsors ... become a sponsor today!
Introduction
Represents a Steam Input Action such as defined in your games IGA file.
These must be created as part of your Steam Settings object .
Fields and Attributes
InputActionType
type
The type of action (Analog or Digital)
string
actionName
The name of the action as it appears in the IGA file
InputAnalogActionHandle_t
AnalogHandle
The native Steam API handle if this is a analog handle and has been resolved.
InputDigitalActionHandle_t
DigitalHandle
The native Steam API handle if this is a digital handle and has been resolved.
Methods
Get Data
This returns the current cashed state for this action and for this controller, this does not update the state with the latest data from Steam it simply returns the last updated state. Typically you would have a behaviour poll all relivent actions at the start of an update and let various behaviours simply read the last known state for the actions they are interested in.
Example:
Once you have a script updating the status of your actions other behaviours can simply read that most recent state;
Update Status
Call this to update the state of the action for the indicated controller.
Example:
You can optionally call this for all actions at once via the Steam Settings object
Get Input Glyphs
This returns the set of textures related to the action for the given controller and action set. For example if this action exists on the indicated set and is mapped to the B button and Right Trigger then the B button texture and RT texture will be returned.
The images for these can be configured in your app.
Examples:
Get Input Names
This returns the set of names related to the action for the given controller and action set. For example if this action exists on the indicated set and is mapped to B and Right Trigger then the string "B Button" and "Right Trigger" will be returned.
Examples:
How To
Create
Input Actions are created as part of your Steam Settings object
Set Analog or Digital
Click the AI or DI buttton to change the type
AI represents "Analog Input"
DI represents "Digital Input"
Last updated