Class InputDeviceConnectedEvent
Published via the Scylla Event eXchange System (SEX) when a new input device is detected and connected to the system.
Inherited Members
Namespace: Scylla.Input
Assembly: ScyllaInput.dll
Syntax
public class InputDeviceConnectedEvent : ScyllaEvent
Remarks
This event is fired once per physical device connection. It provides the raw Unity
UnityEngine.InputSystem.InputDevice reference along with the Scylla-classified
InputDeviceType and the Unity-assigned device ID for scenarios where
callers need to track specific device instances across connect/disconnect cycles.
Subscribe via ScyllaEvents.Listen<InputDeviceConnectedEvent>.
Properties
Device
Gets or sets the Unity Input System device object that was connected. This reference is valid for the lifetime of the connection; it becomes stale after the corresponding InputDeviceDisconnectedEvent is published.
Declaration
public InputDevice Device { get; set; }
Property Value
| Type | Description |
|---|---|
| InputDevice |
DeviceID
Gets or sets the unique integer ID assigned to this device by Unity's Input System
(InputDevice.deviceId). This ID is stable for the duration of the connection
and can be used to correlate this event with a future
InputDeviceDisconnectedEvent for the same physical device.
Declaration
public int DeviceID { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
DeviceType
Gets or sets the Scylla-classified type category of the connected device, such as Keyboard, Gamepad, or Mouse. Use this instead of inspecting Device directly when only the device category is needed.
Declaration
public InputDeviceType DeviceType { get; set; }
Property Value
| Type | Description |
|---|---|
| InputDeviceType |