Skip to main content
Server Optional module. Proxied to ug-core.

Register

string
required
Lowercase. Registers /name.
UgCommandOptions
required
fun(source, args)
required
args is keyed by argument name. source is 0 for the console.

Argument types

Each argument has name, type, and optional optional, max and help. Optional arguments MUST be trailing.

Failures

ug-core shows nothing to players. A failure emits ug-core:Commands:Failed with (source, name, errorCode, argIndex), so a chat or notification resource can display it.

GetAll

Commands sorted by name, with name, help, permission and args. Use it for chat suggestions, filtered by permission per player.

Example