Files
spigot-tyrant/design/concepts/persistence-model.md
T
dmg afd8a03f1b
Release / release (push) Successful in 2m51s
CI / build (push) Successful in 1m10s
feat(gear): add final unbreakable Elytra reward
2026-09-09 22:28:40 -04:00

29 lines
2.4 KiB
Markdown

---
type: Design Concept
title: Persistence Model
description: Defines the durable state and timekeeping needed to restore a Tyrant game safely.
---
# Persistence Model
State is keyed by player UUID while retaining the latest known player name for display. Durable global state includes lifecycle status, current and pending role holders, selection deadlines, paused durations, the current Tyrant reign and its claimed legacy armor, tool, and weapon rewards, and the administrator-configured Vigilante arena center. Active Tyrant or Vigilante challenge bosses and challenger entities are transient and are reconstructed or reset from authoritative role and shared-arena state after restart.
Durable player state includes participation status, opt-out deadline, login history, role or class, Tyrant level, purchased unlocks, unspent choices, Follower relationship, ability cooldowns, daily intelligence use, bound-item delivery state, and captured mobs.
Elapsed-time rules use UTC instants. Paused time is excluded from timers. Saves use atomic replacement where supported, preserve unknown fields where practical, and reject corrupt records rather than granting powers, assignments, or duplicated entities.
The historical `game.claimed-armor` list stores the nine regular legacy reward enum values plus `ELYTRA` for the final collection reward. Elytra eligibility uses exactly the nine regular current-reign claims, never item possession or Elytra itself. Original armor values remain unchanged; absent state means no claims. Claim state resets with the reign, not when an item is transferred or lost. Delivered equipment has no role binding and remains in ordinary Minecraft item storage.
## Related stories
- [Complete the legacy collection with Elytra](../user-stories/us-023-complete-legacy-collection-with-elytra.md)
- [Purchase legacy tools and weapons](../user-stories/us-022-purchase-legacy-tools-and-weapons.md)
- [Inform players and manage participation](../user-stories/us-011-inform-and-manage-participation.md)
- [Configure and persist game state](../user-stories/us-012-configure-and-persist-state.md)
- [Use class ability items](../user-stories/us-014-use-class-ability-items.md)
- [Claim the Vigilante role in the arena](../user-stories/us-019-claim-vigilante-in-arena.md)
- [Claim the Tyrant role in the arena](../user-stories/us-020-claim-tyrant-in-arena.md)
- [Claim Tyrant legacy armor](../user-stories/us-021-claim-tyrant-legacy-armor.md)