PROJECT WORKSHOP · INTERMEDIATE

Build a Persistent Virtual-Pet Experience

Combine persistent state, experience-owned UI, custom presentation and safe resume logic into a small game that survives world reloads.

Inspired by [DAI] Tamacrafti90–150 min5 milestones
Build the idea, not a clone. This workshop intentionally recreates a smaller learning version of the public project. It teaches the same categories of DAI systems without pretending to reproduce every private/internal project file.

What You Learn

MAIN experiencepersistent statemenuscustom UIjoin/resumeresource lifecycleproject config

Starter Project Shape

Create only the folders you need for each milestone. The exact final tree can grow as you add your own systems.

Suggested learning layout
data/pet_game/
├─ dai_experiences/main.json
├─ dai_objectives/
├─ dai_menus/
├─ dai_items/
└─ dai_worldgen/      (optional)
assets/pet_game/
└─ textures/gui/

Build It in Milestones

  1. Claim MAIN ownershipCreate one experience definition with a stable save identity and clean first-join/resume hooks.
  2. Create pet stateTrack a few readable values such as mood, hunger or age using DAI runtime state/attributes.
  3. Build the main screenUse an experience-owned menu/overlay flow that opens and closes consistently.
  4. Advance on gameplay eventsUpdate the pet through objectives and reactions instead of embedding all logic in one giant file.
  5. Repair on joinUse resume logic to restore presentation and recover state without replaying first-time setup.

Make It Yours

  • Add multiple pet species.
  • Create a day/night growth timeline.
  • Add graves/backtick UI ownership and a companion-pack auto-enable identity.

Reference While You Build