> ## Documentation Index
> Fetch the complete documentation index at: https://ugcore.urging.ch/llms.txt
> Use this file to discover all available pages before exploring further.

# Statebags

> Every statebag ug-core writes.

All statebags are set by the server only. See the [Statebags guide](/developers/statebags) to read them.

## Player

On `Player(source).state` and `LocalPlayer.state`.

| Key | Value | Module |
| - | - | - |
| `ug-core:Loaded` | `true` once a character is loaded, or at join without the characters module | players |
| `ug-core:Player` | `{ name, characterId? }` | players |
| `ug-core:Metadata` | Metadata set with `replicate = true` | players |
| `ug-core:DeathState` | `'Alive'`, `'Downed'` or `'Dead'` | players |
| `ug-core:Injuries` | `UgInjury[]` | players |
| `ug-core:Job` | `{ name, label, grade, gradeName, gradeLabel, salary, boss, onDuty }` | jobs |
| `ug-core:Gang` | `{ name, label, grade, gradeName, gradeLabel, salary, boss }` | gangs |
| `ug-core:Session` | Session id, or `nil` in the shared world | sessions |

## Global

On `GlobalState`.

| Key | Value |
| - | - |
| `ug-core:Config` | `{ [name] = { kind, values } }` with client and shared values only. Written once every config loaded. |
| `ug-core:Modules` | Enabled modules in load order, with their files and namespaces. |

<Warning>Player statebags replicate to every client. They never hold secrets.</Warning>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.