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

IMenuRendererSource

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

Supplies renderer overrides for menus.

Sources are consulted in descending Priority order and the first one that answers wins, so a server-wide configuration can enforce a renderer over whatever a plugin requested in code. Implement this to bind renderer choices from any store.

View source

Properties

Priority

The resolution priority. Higher values are consulted first.

int Priority { get; }
Property Value

Methods

TryGetRenderer(string, out string)

Attempts to resolve the renderer to use for a menu.

bool TryGetRenderer(string menuId, out string rendererId)
Parameters
  • menuIdstringThe menu to resolve.
  • rendererIdstringThe renderer id, when this source overrides the menu.
Returns
true when this source overrides the menu.