Interface IPlayerInputSlots
Namespace: Serenity.InputGateway.Application.Interfaces.Components
Assembly: Serenity.InputGateway.Application.dll
Syntax
public interface IPlayerInputSlots
Properties
Current
Declaration
IReadOnlyList<PlayerInputSlot> Current { get; }
Property Value
| Type | Description |
|---|---|
| IReadOnlyList<PlayerInputSlot> | Gets the current list of player input slots. |
Methods
ClearAll()
Clears all player input slots, resetting the component to its initial state.
Declaration
void ClearAll()
TryAssignNextFree(string, string)
Tries to assign the next free slot to the specified device ID and optional layout.
Declaration
bool TryAssignNextFree(string deviceId, string layout)
Parameters
| Type | Name | Description |
|---|---|---|
| string | deviceId | The ID of the device to assign. |
| string | layout | The optional layout to use for the assignment. |
Returns
| Type | Description |
|---|---|
| bool | True if the assignment was successful; otherwise, false. |
TryUnassignByDevice(string)
Tries to unassign the slot associated with the specified device ID.
Declaration
bool TryUnassignByDevice(string deviceId)
Parameters
| Type | Name | Description |
|---|---|---|
| string | deviceId | The ID of the device to unassign. |
Returns
| Type | Description |
|---|---|
| bool | True if the unassignment was successful; otherwise, false. |