swiftlys2/docs/api/ai/
API Reference › Menu

IMenuKeybindSource

Interface
Namespace: SwiftlyS2.Shared.Menu · Assembly: SwiftlyS2.CS2.dll
public interface IMenuKeybindSource

Supplies key overrides for menu actions.

Sources are consulted in descending Priority order and the first one that answers wins, so layering configuration is a matter of registering another source rather than merging values. Implement this to bind actions from any store.

View source

Properties

Priority

The resolution priority. Higher values are consulted first.

int Priority { get; }
Property Value

Methods

TryGetKey(MenuActionId, out MenuKey)

Attempts to resolve the key bound to an action.

bool TryGetKey(MenuActionId id, out MenuKey key)
Parameters
  • idMenuActionIdThe action to resolve.
  • keyMenuKeyThe bound key, when this source binds the action.
Returns
true when this source binds the action.