Chris' Tutorials
Docs/Calendar Time

Class

AgeStateRegistry

Generated GDScript class reference for CalendarTime.AgeStateRegistry.

StatusCurrent
Versionv2.0
UpdatedGenerated from GDScript addon source
Source note:This page rendered plugin-owned docs or generated metadata inside unified Astro docs shell.

Used to register the IDs and Resource references for AgeStates in a per-clock scope, with support for serialization and potential multiplayer. There is no process-wide singleton. Each GameClock constructs and owns its own AgeStateRegistry (see GameClock.age_registry); every AgeService and AgeComponent bound to that clock reads/writes here. Two clocks running side-by-side never see each other's age states. Per-clock ownership means:

  • Clock lifetime owns registry lifetime (no orphan registries).
  • Tests get hermetic isolation between clocks (no shared state, no need to registry.clear() between unrelated tests).
  • Two game instances in one process each carry their own registry.
  • AgeService resolution: clock.age_registry.get_state_or_new(service_id, ...).
  • AgeComponent resolution: clock.age_registry via the component's @export var clock.

Source: addons/calendar_time/ageing/state/age_state_registry.gd

Syntax

class AgeStateRegistry

Members

NameKindSummary
debugPropertyGet console prints for registry operation results
signal_busProperty
coordinatorProperty
main_age_idPropertyUnique main ID. Should be set before other age states to serve as the default parent Objects occupy the world therefore AgeStates are children of the world's AgeState
registerMethod
use_idProperty
get_state_or_newMethod
parent_idProperty
new_idProperty
new_stateProperty
get_stateMethod
get_sizeMethod
get_allMethod
has_stateMethod
removeMethod
stateProperty
removedProperty
clearMethod
generate_uuidMethod
new_idProperty
to_dictMethod
save_states_dictProperty
from_dictMethod
state_states_dictProperty
new_stateProperty
sizeProperty

Source

addons/calendar_time/ageing/state/age_state_registry.gd

Plugin docs root:gdscript/plugins/calendar_time_dev/docs