InputAPI reference
Struct ActionPrompt
Namespace: MicroEngine.Input
Assembly: MicroEngine.dll
Guide: Input
How to show one action to the player on one device: “Z” on a keyboard, “A” on an Xbox pad,
“×” on a PlayStation pad, the button’s own label on a touch screen. Text is what to print;
Kind and the other members let a game draw a glyph instead (a key cap, a coloured pad button).
public readonly struct ActionPrompt : IEquatable<ActionPrompt>Implements
Constructors
ActionPrompt(string, InputDevice, PromptKind, string)
How to show one action to the player on one device: “Z” on a keyboard, “A” on an Xbox pad,
“×” on a PlayStation pad, the button’s own label on a touch screen. Text is what to print;
Kind and the other members let a game draw a glyph instead (a key cap, a coloured pad button).
public ActionPrompt(string Action, InputDevice Device, PromptKind Kind, string Text)Parameters
Action string
The action shown.
Device InputDevice
The device it is shown for.
Kind PromptKind
What Text stands for.
Text string
Short text for the control (“Z”, “Space”, “A”, “←”, “JUMP”).
Properties
Action
The action shown.
public string Action { get; init; }Property Value
Button
The button, for PadButton.
public PadButton Button { get; init; }Property Value
Control
The touch control’s id, for Touch.
public string? Control { get; init; }Property Value
Device
The device it is shown for.
public InputDevice Device { get; init; }Property Value
Key
The key, for Key.
public Key Key { get; init; }Property Value
Kind
What Text stands for.
public PromptKind Kind { get; init; }Property Value
PadStyle
The gamepad family the button is named for.
public GamepadStyle PadStyle { get; init; }Property Value
Text
Short text for the control (“Z”, “Space”, “A”, “←”, “JUMP”).
public string Text { get; init; }Property Value
Methods
Deconstruct(out string, out InputDevice, out PromptKind, out string)
public void Deconstruct(out string Action, out InputDevice Device, out PromptKind Kind, out string Text)Parameters
Action string
Device InputDevice
Kind PromptKind
Text string
Equals(object)
public override bool Equals(object obj)Parameters
obj object
Returns
Equals(ActionPrompt)
public bool Equals(ActionPrompt other)Parameters
other ActionPrompt
Returns
GetHashCode()
public override int GetHashCode()Returns
ToString()
public override string ToString()Returns
Operators
operator ==(ActionPrompt, ActionPrompt)
public static bool operator ==(ActionPrompt left, ActionPrompt right)Parameters
left ActionPrompt
right ActionPrompt
Returns
operator !=(ActionPrompt, ActionPrompt)
public static bool operator !=(ActionPrompt left, ActionPrompt right)Parameters
left ActionPrompt
right ActionPrompt