import type { GameTime } from '@hollowdark/time/gameTime' import type { Brand } from '@hollowdark/utils/types/brand' /** * Branded IDs — string at runtime, distinct at compile time so a PersonId * can't silently flow into a slot that expects a RelationshipId. */ export type PersonId = Brand export type RelationshipId = Brand export type PlaceId = Brand export type InstitutionId = Brand export type WorldEventId = Brand export type WorldId = Brand export type EventLogEntryId = Brand export type RoutineId = Brand export type ScheduledEventId = Brand export type FlowEntryId = Brand export type MemoirId = Brand /** Every simulation entity wears one of these kind tags. */ export type EntityKind = 'person' | 'relationship' | 'institution' | 'place' | 'world_event' /** * The common shape every entity carries. Concrete entities extend this with * their specific id/kind pair — `Person extends BaseEntity`. * `deterministicSeed` powers lazy Tier 3 regeneration: given the seed, the * entity's trajectory is fully reproducible without persisted state. */ export interface BaseEntity { readonly id: Id readonly kind: K readonly createdAt: GameTime readonly destroyedAt: GameTime | null readonly deterministicSeed: number }