Scylla Framework
  • API Reference
Search Results for

    Show / Hide Table of Contents
    • Scylla.Input
      • AutoResolveChange
      • AutoResolveResult
      • BindingConflict
      • BindingStorageSettings
      • BindingStorageType
      • BridgeSettings
      • BufferedInput
      • ConfigActionEntry
      • ConfigActionGroup
      • ConfigBindingEntry
      • ConfigConflict
      • ConfigGroupExclusion
      • ConfigLayout
      • ConfigLayout.Builder
      • ConfigLayoutColumnDefinition
      • ConfigLayoutConflictScope
      • ConfigLayoutDefinition
      • ConfigLayoutExclusionDefinition
      • ConfigLayoutGroupDefinition
      • ConfigLayoutGroupMode
      • ConfigLayoutMemberReference
      • ConfigLayoutValidationMessage
      • ConfigLayoutValidationSeverity
      • ConfigSchemeGroup
      • ContextConflictScope
      • ContextValidationMessage
      • ContextValidationSeverity
      • ControlScheme
      • ControlSchemeChangedEvent
      • ControlSchemeManager
      • ControlSchemeType
      • GamepadButton
      • GamepadType
      • IBindingStorage
      • IControlSchemeManager
      • IInputActionManager
      • IInputBindingManager
      • IInputBridgeManager
      • IInputBufferManager
      • IInputConflictScope
      • IInputContextManager
      • IInputControlAliasResolver
      • IInputHintsManager
      • IInputListener
      • IInputRebindabilityProvider
      • IScyllaInputBridge
      • IdentityControlAliasResolver
      • InputActionCanceledEvent
      • InputActionManager
      • InputActionMapNode
      • InputActionMetadata
      • InputActionNode
      • InputActionPerformedEvent
      • InputActionStartedEvent
      • InputActionsDocument
      • InputActionsDocumentIO
      • InputActionsJSONKeys
      • InputAnnotation
      • InputAssetInfo
      • InputBindingGroups
      • InputBindingManager
      • InputBindingMetadata
      • InputBindingNode
      • InputBindingsLoadedEvent
      • InputBindingsSavedEvent
      • InputBridgeManager
      • InputBridgeQueryMode
      • InputBufferConsumedEvent
      • InputBufferManager
      • InputBufferedEvent
      • InputCodegenSettings
      • InputCompositeUtil
      • InputConflictEngine
      • InputConflictPair
      • InputConflictPolicy
      • InputConflictReason
      • InputConflictRecord
      • InputConflictRecordBuilder
      • InputConflictResolution
      • InputConflictSet
      • InputContext
      • InputContextChangedEvent
      • InputContextDefinition
      • InputContextExclusivity
      • InputContextManager
      • InputContextPoppedEvent
      • InputContextPushedEvent
      • InputControlAliasEntry
      • InputControlAliasResolver
      • InputControlAliasScope
      • InputControlPathUtil
      • InputControlSchemeNode
      • InputDeviceChangedEvent
      • InputDeviceConnectedEvent
      • InputDeviceDisconnectedEvent
      • InputDeviceType
      • InputDeviceUtil
      • InputDisabledEvent
      • InputEnabledEvent
      • InputEventType
      • InputHint
      • InputHintChangedEvent
      • InputHintsManager
      • InputIconSet
      • InputIconSet.IconMapping
      • InputIconSetChangedEvent
      • InputInteractionKind
      • InputInteractionResolver
      • InputInteractionSignature
      • InputJSONMember
      • InputJSONNode
      • InputJSONNodeReader
      • InputJSONNodeType
      • InputJSONNodeWriter
      • InputLoggingSettings
      • InputMapMetadata
      • InputMetadataRebindabilityProvider
      • InputMetadataReconciler
      • InputMetadataRecordKind
      • InputModifierMetadataUtil
      • InputOrphanRecord
      • InputRebindCancelledEvent
      • InputRebindCompletedEvent
      • InputRebindManager
      • InputRebindOperation
      • InputRebindStartedEvent
      • InputRebindUtils
      • InputRebindability
      • InputReconcileAction
      • InputReconcileOptions
      • InputReconcileReport
      • InputReconcileReport.Entry
      • InputSchemeDeviceNode
      • InputSchemeMetadata
      • JSONFileBindingStorage
      • ManagedRebindCancelledEvent
      • ManagedRebindCompletedEvent
      • ManagedRebindDataRefreshedEvent
      • ManagedRebindStartedEvent
      • PlayerPrefsBindingStorage
      • RebindMode
      • RebindSettings
      • ScyllaInput
      • ScyllaInput.Meta
      • ScyllaInputAction
      • ScyllaInputActionMap
      • ScyllaInputActionsMetadata
      • ScyllaInputActionsMetadataMigrator
      • ScyllaInputBinding
      • ScyllaInputConfiguration
      • ScyllaInputContextConfiguration
      • ScyllaKey
      • ScyllaKeyConverter
      • ScyllaModifier
      • UnityInputSystemBridge
    • Scylla.Input.Editor
      • DeviceStatusWidget
      • IconMappingDrawer
      • InputIconSetEditor
      • ScyllaInputActionsMetadataEditor
      • ScyllaInputConfigurationEditor
      • ScyllaInputContextConfigurationEditor
      • ScyllaInputDependencyProvider
      • ScyllaInputEditor
      • ScyllaInputGameProfile
      • ScyllaInputGameProfiles
      • ScyllaInputMenuItems
      • ScyllaInputWizard

    Class ControlScheme

    Represents a named grouping of compatible input devices together with display metadata used for button-prompt rendering and input interpretation context.

    Inheritance
    object
    ControlScheme
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: Scylla.Input
    Assembly: ScyllaInput.dll
    Syntax
    public class ControlScheme
    Remarks

    A ControlScheme binds a unique string ID and a high-level ControlSchemeType category to one or more InputDeviceType values, an optional icon set ID, and an optional detected GamepadType. Together, these properties tell the game which button-prompt assets to display and how to interpret raw input events.

    Instances are created through the fluent factory API: call Create(string, ControlSchemeType) to obtain a new instance, then chain WithDisplayName(string), WithDevices(params InputDeviceType[]), WithIconSet(string), and WithGamepadType(GamepadType) as needed. The three convenience factories CreateDefaultKeyboardMouse(), CreateDefaultGamepad(), and CreateDefaultTouch() produce the standard built-in schemes that ControlSchemeManager registers automatically on initialization.

    A scheme's associated device list prevents duplicate entries - calling WithDevices(params InputDeviceType[]) with a device already in the list is a safe no-op for that entry.

    Properties

    AssociatedDevices

    Gets the list of input device types that are logically associated with this scheme.

    Declaration
    public IReadOnlyList<InputDeviceType> AssociatedDevices { get; }
    Property Value
    Type Description
    IReadOnlyList<InputDeviceType>

    A read-only view of the internal device list. Entries are added via WithDevices(params InputDeviceType[]). The list never contains duplicates. Use HasDevice(InputDeviceType) to test membership without allocating an enumerator.

    DisplayName

    Gets or sets the localization-friendly name shown to the player in settings menus and UI prompts.

    Declaration
    public string DisplayName { get; }
    Property Value
    Type Description
    string

    Defaults to the value of SchemeID when the scheme is first created. Override with WithDisplayName(string) during scheme construction. Examples: "Keyboard & Mouse", "Controller", "Touch".

    GamepadType

    Gets or sets the detected manufacturer/platform variant of the gamepad associated with this scheme.

    Declaration
    public GamepadType GamepadType { get; set; }
    Property Value
    Type Description
    GamepadType

    Meaningful only when SchemeType is Gamepad. Defaults to Generic. The ControlSchemeManager updates this property automatically whenever it detects a change in the connected gamepad's reported device name or layout. Callers may also set it explicitly via WithGamepadType(GamepadType) during scheme construction.

    See Also
    DetectedGamepadType

    IconSetID

    Gets or sets the key that identifies which icon set should be activated when this scheme is the active scheme.

    Declaration
    public string IconSetID { get; set; }
    Property Value
    Type Description
    string

    An opaque string key consumed by the input hints system to select button-prompt sprite atlases. Common values used by the built-in schemes are "Keyboard", "Xbox", and "Touch". May be null if the scheme does not require custom button prompts.

    SchemeID

    Gets the unique string identifier for this control scheme.

    Declaration
    public string SchemeID { get; }
    Property Value
    Type Description
    string

    The ID supplied to Create(string, ControlSchemeType) at construction time. This value is immutable and is used as the lookup key by IControlSchemeManager. The three built-in schemes use the IDs "KeyboardMouse", "Gamepad", and "Touch".

    SchemeType

    Gets the high-level input category that this scheme belongs to.

    Declaration
    public ControlSchemeType SchemeType { get; }
    Property Value
    Type Description
    ControlSchemeType

    The ControlSchemeType supplied to Create(string, ControlSchemeType) at construction time. This value is immutable. Use Custom for project-specific schemes that do not fit the built-in categories.

    Methods

    Create(string, ControlSchemeType)

    Creates a new ControlScheme with the specified ID and type. Chain fluent builder methods to configure the scheme before registering it with RegisterScheme(ControlScheme).

    Declaration
    public static ControlScheme Create(string schemeID, ControlSchemeType schemeType)
    Parameters
    Type Name Description
    string schemeID

    A unique, non-null string identifier for this scheme. Must not collide with the IDs of any scheme already registered with the target IControlSchemeManager.

    ControlSchemeType schemeType

    The high-level category of this scheme. Use Custom for project-specific schemes.

    Returns
    Type Description
    ControlScheme

    A new ControlScheme instance ready for further configuration.

    Remarks
    var scheme = ControlScheme
        .Create("SteamDeck", ControlSchemeType.Gamepad)
        .WithDisplayName("Steam Deck")
        .WithDevices(InputDeviceType.Gamepad)
        .WithIconSet("Steam")
        .WithGamepadType(GamepadType.Steam);
    
    controlSchemeManager.RegisterScheme(scheme);

    CreateDefaultGamepad()

    Creates the built-in "Gamepad" control scheme pre-configured with Gamepad, display name "Controller", associated devices Gamepad and Joystick, icon set ID "Xbox", and gamepad type Generic.

    Declaration
    public static ControlScheme CreateDefaultGamepad()
    Returns
    Type Description
    ControlScheme

    A fully configured ControlScheme ready to be registered with RegisterScheme(ControlScheme).

    Remarks

    ControlSchemeManager calls this method automatically during Initialize(IInputBridgeManager). The GamepadType property is updated at runtime by ControlSchemeManager as the actual connected controller is identified from its device name and layout strings, so the initial Generic value is a placeholder.

    CreateDefaultKeyboardMouse()

    Creates the built-in "KeyboardMouse" control scheme pre-configured with KeyboardMouse, display name "Keyboard & Mouse", associated devices Keyboard and Mouse, and icon set ID "Keyboard".

    Declaration
    public static ControlScheme CreateDefaultKeyboardMouse()
    Returns
    Type Description
    ControlScheme

    A fully configured ControlScheme ready to be registered with RegisterScheme(ControlScheme).

    Remarks

    ControlSchemeManager calls this method automatically during Initialize(IInputBridgeManager). Game code only needs to call it directly when re-registering the default scheme after an explicit UnregisterScheme(string) call.

    CreateDefaultTouch()

    Creates the built-in "Touch" control scheme pre-configured with Touch, display name "Touch", associated device Touchscreen, and icon set ID "Touch".

    Declaration
    public static ControlScheme CreateDefaultTouch()
    Returns
    Type Description
    ControlScheme

    A fully configured ControlScheme ready to be registered with RegisterScheme(ControlScheme).

    Remarks

    Unlike the keyboard/mouse and gamepad defaults, the touch scheme is not registered automatically by Initialize(IInputBridgeManager). Call RegisterScheme(ControlScheme) with this scheme explicitly when targeting touch platforms.

    HasDevice(InputDeviceType)

    Determines whether the specified InputDeviceType is in this scheme's list of associated devices.

    Declaration
    public bool HasDevice(InputDeviceType deviceType)
    Parameters
    Type Name Description
    InputDeviceType deviceType

    The device type to test.

    Returns
    Type Description
    bool

    true if deviceType was added via WithDevices(params InputDeviceType[]); false otherwise.

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    string
    Overrides
    object.ToString()

    WithDevices(params InputDeviceType[])

    Associates one or more InputDeviceType values with this scheme and returns the instance for continued method chaining.

    Declaration
    public ControlScheme WithDevices(params InputDeviceType[] devices)
    Parameters
    Type Name Description
    InputDeviceType[] devices

    The device types to associate. Already-associated types are silently skipped to prevent duplicates. Passing zero arguments is a no-op.

    Returns
    Type Description
    ControlScheme

    This ControlScheme instance.

    Remarks

    The associated device list is used by the auto-detection system in ControlSchemeManager to determine which scheme applies to a given physical device, and by HasDevice(InputDeviceType) to answer per-type membership queries.

    WithDisplayName(string)

    Sets the human-readable display name for this scheme and returns the instance for continued method chaining.

    Declaration
    public ControlScheme WithDisplayName(string displayName)
    Parameters
    Type Name Description
    string displayName

    The display name to show in settings menus and UI prompts. Should be localization-friendly. Must not be null (an empty string is accepted but not recommended).

    Returns
    Type Description
    ControlScheme

    This ControlScheme instance.

    WithGamepadType(GamepadType)

    Sets the gamepad platform/manufacturer type for this scheme and returns the instance for continued method chaining.

    Declaration
    public ControlScheme WithGamepadType(GamepadType gamepadType)
    Parameters
    Type Name Description
    GamepadType gamepadType

    The GamepadType to assign. Has no effect on schemes whose SchemeType is not Gamepad, but is stored regardless so that callers may pre-configure a default.

    Returns
    Type Description
    ControlScheme

    This ControlScheme instance.

    WithIconSet(string)

    Sets the icon set ID used for button-prompt rendering when this scheme is active and returns the instance for continued method chaining.

    Declaration
    public ControlScheme WithIconSet(string iconSetID)
    Parameters
    Type Name Description
    string iconSetID

    The opaque string key that identifies the icon set in the input hints system. Pass null to clear any previously set icon set ID.

    Returns
    Type Description
    ControlScheme

    This ControlScheme instance.

    See Also

    IControlSchemeManager
    ControlSchemeManager
    ControlSchemeType
    InputDeviceType
    In this article
    Back to top Scylla Framework - Input Module API Documentation