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

    Interface IInputActionManager

    Defines the contract for the Scylla input action management subsystem.

    Namespace: Scylla.Input
    Assembly: ScyllaInput.dll
    Syntax
    public interface IInputActionManager
    Remarks

    The action manager is the central hub for registering, querying, enabling, and reading input actions across the entire input system. It bridges Unity's InputAction and InputActionAsset types with Scylla's wrapper types (ScyllaInputAction, ScyllaInputActionMap), adding modifier-key disambiguation, per-frame state queries, and Scylla Event eXchange (SEX) broadcasting on top of the raw Unity callbacks.

    Actions can be registered either by supplying a Unity InputActionAsset (which wraps every contained map and action automatically) or by registering a hand-crafted ScyllaInputActionMap directly. Both paths support the same query and control surface.

    An action is identified by the map that declares it and its name within that map, and every lookup takes both. An action name is only unique inside its map, while a map name is unique across everything registered, so the pair is the identity. Two maps each declaring a Look is ordinary and fully supported: those are two actions, separately bound and separately rebindable. Always prefer TryGetAction(string, string, out ScyllaInputAction) over GetAction(string, string) when action existence is uncertain.

    The concrete implementation is InputActionManager. Access the instance via ScyllaInput.Instance.Actions.

    Properties

    ActionCount

    Gets the total number of actions registered across all maps.

    Declaration
    int ActionCount { get; }
    Property Value
    Type Description
    int

    A non-negative integer representing the sum of all actions in every registered action map. Two maps declaring the same action name contribute two, because those are two actions.

    ActionMapCount

    Gets the total number of action maps currently registered with the manager.

    Declaration
    int ActionMapCount { get; }
    Property Value
    Type Description
    int

    A non-negative integer. Returns 0 if no maps have been registered or if the manager has not yet been initialized.

    ActiveControlSchemeName

    Gets the control scheme currently applied as a binding mask, or an empty string.

    Declaration
    string ActiveControlSchemeName { get; }
    Property Value
    Type Description
    string

    The name last passed to SetActiveControlScheme(string), or an empty string when no scheme is applied and every binding is live.

    IsInitialized

    Gets a value indicating whether the action manager has been initialized.

    Declaration
    bool IsInitialized { get; }
    Property Value
    Type Description
    bool

    true after Initialize() completes successfully; false before initialization or after Shutdown().

    RegisteredAssets

    Gets every InputActionAsset currently registered, in registration order.

    Declaration
    IReadOnlyList<InputActionAsset> RegisteredAssets { get; }
    Property Value
    Type Description
    IReadOnlyList<InputActionAsset>

    The registered assets, in order.

    Remarks

    Order is the order the assets were registered, which is also precedence: a map name two of them declare resolves to whichever registered last.

    Methods

    ClearActiveControlScheme()

    Clears the control scheme mask, making every binding live again.

    Declaration
    void ClearActiveControlScheme()
    Remarks

    Safe to call when no scheme was ever set.

    DisableActionMap(string)

    Disables the action map with the given ID, preventing its actions from receiving input events.

    Declaration
    void DisableActionMap(string mapID)
    Parameters
    Type Name Description
    string mapID

    The unique identifier of the action map to disable. An unrecognized ID is silently ignored.

    Remarks

    Disabling a map that wraps a Unity InputActionMap calls InputActionMap.Disable(). Disabling a manually-constructed map disables each contained action individually. If the map is already disabled or the ID is not found, the call is a no-op.

    DisableAllActionMaps()

    Disables every registered action map, preventing all actions from receiving input events.

    Declaration
    void DisableAllActionMaps()
    Remarks

    Calls Disable() on each registered map in registration order. Maps that are already disabled are silently skipped. This is useful for global pause states or UI-modal scenarios where all gameplay input should be suppressed at once.

    EnableActionMap(string)

    Enables the action map with the given ID, allowing its actions to receive input events.

    Declaration
    void EnableActionMap(string mapID)
    Parameters
    Type Name Description
    string mapID

    The unique identifier of the action map to enable. An unrecognized ID is silently ignored.

    Remarks

    Enabling a map that wraps a Unity InputActionMap calls InputActionMap.Enable(). Enabling a manually-constructed map enables each contained action individually. If the map is already enabled or the ID is not found, the call is a no-op.

    EnableAllActionMaps()

    Enables every registered action map, allowing all actions to receive input events.

    Declaration
    void EnableAllActionMaps()
    Remarks

    Calls Enable() on each registered map in registration order. Maps that are already enabled are silently skipped.

    GetAction(string, string)

    Returns the ScyllaInputAction registered under the given ID, or null if no matching action exists.

    Declaration
    ScyllaInputAction GetAction(string mapID, string actionID)
    Parameters
    Type Name Description
    string mapID

    The action map declaring the action (e.g. "Gameplay"). A null or empty string always returns null.

    string actionID

    The action's name within that map (e.g. "Jump"). A null or empty string always returns null.

    Returns
    Type Description
    ScyllaInputAction

    The matching ScyllaInputAction, or null if not found.

    Remarks

    An action is identified by its map and its name together, and both are required. An action name is only unique inside its map, while a map name is unique across everything registered, so the pair is the identity and a name on its own is not one. Two maps each declaring a Look is ordinary and fully supported: those are two actions, and this returns whichever one the map names.

    When action existence is uncertain, prefer TryGetAction(string, string, out ScyllaInputAction) to avoid repeated null checks.

    GetActionMap(string)

    Returns the ScyllaInputActionMap registered under the given ID, or null if not found.

    Declaration
    ScyllaInputActionMap GetActionMap(string mapID)
    Parameters
    Type Name Description
    string mapID

    The unique identifier of the action map to retrieve. A null or empty string always returns null.

    Returns
    Type Description
    ScyllaInputActionMap

    The matching ScyllaInputActionMap, or null if no map with that ID has been registered.

    GetActionValue(string, string)

    Returns the current float value of the action identified by mapID and actionID.

    Declaration
    float GetActionValue(string mapID, string actionID)
    Parameters
    Type Name Description
    string mapID

    The map declaring the action. A null, empty, or unrecognized value resolves nothing, since an action is identified by its map and its name together.

    string actionID

    The ID of the action to query. A null, empty, or unrecognized value returns 0f.

    Returns
    Type Description
    float

    The float value of the action, or 0f if the action was not found, is disabled, or its value type is incompatible.

    Remarks

    For actions with a Vector2 control type the returned value is the magnitude of the 2D vector. For actions with a Vector3 control type the returned value is the magnitude of the 3D vector. For all other control types the raw float value is returned. See ReadFloat() for the full type-dispatch logic.

    GetActionVector2(string, string)

    Returns the current Vector2 value of the action identified by mapID and actionID.

    Declaration
    Vector2 GetActionVector2(string mapID, string actionID)
    Parameters
    Type Name Description
    string mapID

    The map declaring the action. A null, empty, or unrecognized value resolves nothing, since an action is identified by its map and its name together.

    string actionID

    The ID of the action to query. A null, empty, or unrecognized value returns Vector2.zero.

    Returns
    Type Description
    Vector2

    The Vector2 value of the action, or Vector2.zero if the action was not found, is disabled, or its value type is incompatible.

    Remarks

    Only actions whose control type is "Vector2" (or an unspecified type that can be cast to Vector2) will yield meaningful results. Actions with float/button/axis control types return Vector2.zero. See ReadVector2() for the full type-dispatch logic.

    GetActionsInMap(string)

    Returns a read-only list of all actions belonging to the specified action map.

    Declaration
    IReadOnlyList<ScyllaInputAction> GetActionsInMap(string mapID)
    Parameters
    Type Name Description
    string mapID

    The ID of the action map whose actions to retrieve. A null, empty, or unrecognized value returns an empty list.

    Returns
    Type Description
    IReadOnlyList<ScyllaInputAction>

    A IReadOnlyList<T> of ScyllaInputAction objects belonging to the specified map, or Empty<T>() if the map was not found.

    GetAllActionMaps()

    Returns a read-only list of all action maps currently registered with the manager.

    Declaration
    IReadOnlyList<ScyllaInputActionMap> GetAllActionMaps()
    Returns
    Type Description
    IReadOnlyList<ScyllaInputActionMap>

    A IReadOnlyList<T> of all registered ScyllaInputActionMap instances. Never null; may be empty.

    GetAllActions()

    Returns a read-only snapshot of all actions currently registered across all action maps.

    Declaration
    IReadOnlyList<ScyllaInputAction> GetAllActions()
    Returns
    Type Description
    IReadOnlyList<ScyllaInputAction>

    A IReadOnlyList<T> of all registered ScyllaInputAction instances. Never null; may be empty.

    Remarks

    The returned list is lazily rebuilt and cached. It is invalidated (and rebuilt on the next call) whenever an action is added or removed. Do not cache the returned reference across frames if actions may be added or removed dynamically.

    HasActionMap(string)

    Determines whether an action map with the given ID is currently registered.

    Declaration
    bool HasActionMap(string mapID)
    Parameters
    Type Name Description
    string mapID

    The action map ID to check. Case-sensitive. A null or empty string always returns false.

    Returns
    Type Description
    bool

    true if a map with the specified ID is registered; otherwise false.

    Initialize()

    Initializes the action manager, preparing it to accept registrations and process input events.

    Declaration
    void Initialize()
    Remarks

    This method is called automatically by ScyllaInput during the module's initialization phase. Calling it manually is not normally required. Subsequent calls after the first successful initialization are no-ops.

    IsActionMapEnabled(string)

    Determines whether the action map with the given ID is currently enabled.

    Declaration
    bool IsActionMapEnabled(string mapID)
    Parameters
    Type Name Description
    string mapID

    The unique identifier of the action map to query. An unrecognized ID returns false.

    Returns
    Type Description
    bool

    true if the map is registered and currently enabled; false if the map is disabled or was not found.

    IsActionPressed(string, string)

    Determines whether the action identified by mapID and actionID is currently pressed or held down.

    Declaration
    bool IsActionPressed(string mapID, string actionID)
    Parameters
    Type Name Description
    string mapID

    The map declaring the action. A null, empty, or unrecognized value resolves nothing, since an action is identified by its map and its name together.

    string actionID

    The ID of the action to query. A null, empty, or unrecognized value returns false.

    Returns
    Type Description
    bool

    true if the action exists and its underlying control is currently held; otherwise false.

    RegisterActionAsset(InputActionAsset)

    Registers all action maps and actions contained in a Unity InputActionAsset, enabling them immediately.

    Declaration
    void RegisterActionAsset(InputActionAsset asset)
    Parameters
    Type Name Description
    InputActionAsset asset

    The Unity InputActionAsset to register. Must not be null.

    Remarks

    Calling this method calls InputActionAsset.Enable() on the asset and wraps each InputActionMap found inside it into a ScyllaInputActionMap. Each action within those maps is in turn wrapped into a ScyllaInputAction and registered.

    If the asset is null or has already been registered, a warning is logged and the call is a no-op.

    Prefer ScyllaInput.RegisterActionAsset unless there is a reason not to. This method registers the maps and nothing else, while the module method also rebuilds the rebindability provider so the new asset's sidecar is honoured, and re-applies the active input context. Registration enables every map in the asset, so without that second step a map the active context disables comes up enabled and stays that way until something pushes a context again.

    RegisterActionMap(ScyllaInputActionMap)

    Registers a hand-crafted ScyllaInputActionMap and all of its contained actions with the manager.

    Declaration
    void RegisterActionMap(ScyllaInputActionMap map)
    Parameters
    Type Name Description
    ScyllaInputActionMap map

    The ScyllaInputActionMap to register. Must not be null.

    Remarks

    Use this overload when building action maps programmatically instead of from a Unity InputActionAsset. After registration, modifier disambiguation metadata is recomputed for all currently registered actions. If map is null or a map with the same MapID is already registered, a warning is logged and the call is a no-op.

    SetActiveControlScheme(string)

    Makes one control scheme the live one, disabling every binding outside it.

    Declaration
    bool SetActiveControlScheme(string schemeName)
    Parameters
    Type Name Description
    string schemeName

    The control scheme's name as authored in the asset. Compared case-insensitively.

    Returns
    Type Description
    bool

    true when at least one registered asset declared the scheme and was masked.

    Remarks

    Applies the scheme as a binding mask (InputBinding.MaskByGroup) on every registered asset that declares it. Until something does this, a control scheme is authoring information and nothing more: enabling an action map enables all of its bindings regardless of which scheme they name, so two actions bound to one control under different schemes both fire.

    A binding naming no scheme stays live under every mask, which is Unity's rule rather than a choice made here. Use it for bindings that belong to every layout.

    An asset that declares no control scheme at all is left alone rather than masked, since masking it by a group it has never heard of would silently disable all of it. That is what lets a shared asset stay live under every scheme.

    An asset that declares other schemes but not this one has its mask cleared instead, so it does not stay masked to whichever scheme was active before. The two cases look alike and behave differently: the first is opting out of scheme masking entirely, the second is simply not participating in this switch.

    Not to be confused with IControlSchemeManager. That reports which device class the player last used, for glyphs and prompts, and never changes which bindings are live. This selects which bindings are live and says nothing about devices.

    Shutdown()

    Shuts down the action manager, unsubscribing all event listeners, disposing all registered maps and actions, and resetting internal state.

    Declaration
    void Shutdown()
    Remarks

    After this method returns, IsInitialized is false and all registered maps, actions, and cached data have been cleared. The manager must be re-initialized via Initialize() before it can be used again. This method is called automatically by ScyllaInput during module shutdown.

    TryGetAction(string, string, out ScyllaInputAction)

    Attempts to retrieve the ScyllaInputAction the given map declares under the given name.

    Declaration
    bool TryGetAction(string mapID, string actionID, out ScyllaInputAction action)
    Parameters
    Type Name Description
    string mapID

    The action map declaring the action. A null or empty string always produces false.

    string actionID

    The action's name within that map. A null or empty string always produces false and sets action to null.

    ScyllaInputAction action

    When this method returns true, contains the matching ScyllaInputAction. When it returns false, the value is null.

    Returns
    Type Description
    bool

    true if a matching action was found; otherwise false.

    Remarks

    Internally delegates to GetAction(string, string). Prefer this overload over GetAction(string, string) when explicit existence checking is required, as it avoids separate null checks at the call site.

    UnregisterActionAsset(InputActionAsset)

    Removes all action maps and actions that were previously registered from the given Unity InputActionAsset.

    Declaration
    void UnregisterActionAsset(InputActionAsset asset)
    Parameters
    Type Name Description
    InputActionAsset asset

    The Unity InputActionAsset to unregister. A null value or an asset that was never registered is silently ignored.

    Remarks

    Each action map that originated from asset is unregistered by name. If the asset is null or was never registered, the call is a no-op. The asset itself is not disabled or destroyed; only the Scylla-side registrations are removed.

    UnregisterActionMap(string)

    Unregisters an action map and all of its actions, and disposes the map.

    Declaration
    void UnregisterActionMap(string mapID)
    Parameters
    Type Name Description
    string mapID

    The unique identifier of the action map to remove. Case-sensitive. A null or empty value is silently ignored.

    Remarks

    After removal, modifier disambiguation metadata is recomputed for all remaining actions. If mapID is null, empty, or does not match a registered map, the call is a no-op.

    Update()

    Advances the action manager state by one frame.

    Declaration
    void Update()
    Remarks

    Called automatically each frame by ScyllaInput. In the current implementation, action state is driven entirely by Unity's event callbacks rather than polling, so this method is reserved for future per-frame tracking needs and performs no work in the default implementation.

    WasActionCanceledThisFrame(string, string)

    Determines whether the action identified by mapID and actionID was canceled (button released) during the current frame.

    Declaration
    bool WasActionCanceledThisFrame(string mapID, string actionID)
    Parameters
    Type Name Description
    string mapID

    The map declaring the action. A null, empty, or unrecognized value resolves nothing, since an action is identified by its map and its name together.

    string actionID

    The ID of the action to query. A null, empty, or unrecognized value returns false.

    Returns
    Type Description
    bool

    true if the action entered the Canceled state this frame; otherwise false.

    WasActionPerformedThisFrame(string, string)

    Determines whether the action identified by mapID and actionID was in the Performed phase at any point during the current frame.

    Declaration
    bool WasActionPerformedThisFrame(string mapID, string actionID)
    Parameters
    Type Name Description
    string mapID

    The map declaring the action. A null, empty, or unrecognized value resolves nothing, since an action is identified by its map and its name together.

    string actionID

    The ID of the action to query. A null, empty, or unrecognized value returns false.

    Returns
    Type Description
    bool

    true if the action reached the Performed state this frame; otherwise false.

    WasActionStartedThisFrame(string, string)

    Determines whether the action identified by mapID and actionID was in the Started phase (button pressed down) during the current frame.

    Declaration
    bool WasActionStartedThisFrame(string mapID, string actionID)
    Parameters
    Type Name Description
    string mapID

    The map declaring the action. A null, empty, or unrecognized value resolves nothing, since an action is identified by its map and its name together.

    string actionID

    The ID of the action to query. A null, empty, or unrecognized value returns false.

    Returns
    Type Description
    bool

    true if the action transitioned to the Started state this frame; otherwise false.

    In this article
    Back to top Scylla Framework - Input Module API Documentation