Class InputAction
- Namespace
- MoonBark.GridPlacement.Core.Types
- Assembly
- MoonBark.GridPlacement.Core.dll
Represents an input action with associated data
public class InputAction
- Inheritance
-
InputAction
- Inherited Members
Constructors
InputAction()
Initializes a new instance of the InputAction class.
public InputAction()
InputAction(string, bool, float, InputDevice)
Initializes a new instance of the InputAction class.
public InputAction(string actionName, bool isPressed, float strength = 1, InputDevice device = InputDevice.Unknown)
Parameters
actionNamestringThe action name.
isPressedboolWhether the action is pressed.
strengthfloatThe action strength/value (0..1).
deviceInputDeviceThe input device that triggered the action.
Properties
ActionName
Name of the input action
public string ActionName { get; set; }
Property Value
Device
Input device that triggered this action
public InputDevice Device { get; set; }
Property Value
IsJustPressed
Whether the action was just pressed this frame
public bool IsJustPressed { get; set; }
Property Value
IsJustReleased
Whether the action was just released this frame
public bool IsJustReleased { get; set; }
Property Value
IsPressed
Whether the action is currently pressed
public bool IsPressed { get; set; }
Property Value
Strength
Strength/value of the action (0.0 to 1.0)
public float Strength { get; set; }
Property Value
Timestamp
Timestamp when the action was triggered
public DateTime Timestamp { get; set; }