Skip to main content
Server Client Optional module. Requires characters. Jobs are defined in config/jobs.lua, a data config. Every character has exactly one job and falls back to unemployed.
config/jobs.lua
Grades are 1-based indexes into grades.

Server

Get

table
nil without a loaded character.

Set / SetGrade

MUST run in a thread. grade defaults to 1. Unknown jobs and grades return invalid_args. Jobs:BeforeSet MAY cancel.

SetDuty / IsOnDuty

Exists / GetDefinition

Client

Read from the ug-core:Job statebag.

Events

  • ug-core:Jobs:Changed with (source, job, previous)
  • ug-core:Jobs:DutyChanged with (source, onDuty)

Example