/** * The tip rotation behind a loading screen: a deterministic shuffle of the game's tips, shown one at a * time, cycling without repeating until the list is exhausted. Deterministic for a given seed, so a * capture or a test sees the same first tip every run. Presentation-free — the loading block owns the * look and the timer. */ /** How a tip rotation is wired. */ export interface TipRotationConfig { /** The tips to rotate, in authored order. Empty means no tip is shown. */ tips: readonly string[]; /** Seed for the shuffle. Default `"tips"`, so the order is stable across runs. */ seed?: string | number; } /** Serializable rotation state. */ export interface TipRotationSnapshot { /** Shuffled indices into the authored tip list. */ order: number[]; /** Position in {@link order} of the tip being shown. */ cursor: number; } /** A deterministic, cycle-through tip list. */ export interface TipRotation { /** The tip being shown, or `null` when the game authored none. */ current(): string | null; /** Advance to the next tip (wrapping) and return it. */ next(): string | null; /** Index into {@link TipRotationConfig.tips} of the current tip, or `-1`. */ index(): number; /** Restart at the first tip of the same shuffled order. */ reset(): void; subscribe(listener: () => void): () => void; snapshot(): TipRotationSnapshot; restore(snapshot: TipRotationSnapshot): void; } /** * Create a {@link TipRotation} over the game's tips. Order is a seeded shuffle; `next()` walks it and * wraps, so every tip is seen once per cycle instead of a random repeat. * * @capability loading-tips deterministic loading-screen tip rotation with a seeded shuffle and snapshot/restore */ export declare function createTipRotation(config: TipRotationConfig): TipRotation;