Skip to content

Player States

Yo_Fred edited this page Aug 9, 2026 · 1 revision

Player States

Player states allow one mod to expose private state without forcing other mods to depend directly on it. A future Just Vanish integration can expose justvanish:vanished, while Just Essentials queries it through Just Core.

A PlayerStateProvider implements:

  • stateId()
  • isActive(ServerPlayer)
  • canView(ServerPlayer viewer, ServerPlayer target)

Consumers use JustCoreApi.hasState(...) and JustCoreApi.canViewState(...). Missing providers return safe defaults instead of crashing.

Clone this wiki locally