Class ButtonCaptureTracker<T>
Presents the down, pressed and released sets of a device as scripts and systems see them while the device's capture state changes.
public sealed class ButtonCaptureTracker<T>
Type Parameters
TThe key or button type.
- Inheritance
-
objectButtonCaptureTracker<T>
- Extension Methods
Remarks
While the device is masked, nothing is down or pressed. When masking begins, everything that was already down is reported as released until the next device update, so scripts and systems never see input stuck down.
When masking ends, input that is still held stays hidden, and its eventual release is hidden too, until it is pressed again. Scripts and systems never see input they did not see pressed.
Properties
Down
Gets the input that is down, as scripts and systems see it.
public IReadOnlySet<T> Down { get; }
Property Value
- IReadOnlySet<T>
Pressed
Gets the input pressed this frame, as scripts and systems see it.
public IReadOnlySet<T> Pressed { get; }
Property Value
- IReadOnlySet<T>
Released
Gets the input released this frame, as scripts and systems see it.
public IReadOnlySet<T> Released { get; }
Property Value
- IReadOnlySet<T>