Skip to content

Codebase Documentation Index

Please start here to understand the codebase patterns before making changes.

Introduction

Systems Documentation

SystemDescription
GameConfigsLevel definitions, difficulty settings, balance
GameRunsRun lifecycle, state management, WorkDayProgress
HelperCatsHelper cat abilities, deck system, combos
LevelsLevel structure, cat spawning, progression
OrderingCatsCustomer cats, orders, delivery mechanics
OverworldHub world exploration, character controller
SaveLoadSave/load system, profiles, persistence
ScoringScore calculation, perfection system, prestige
ShopShop UI, results review, shift preparation
TutorialTutorial run system, in-level sequences, dialogue bubbles
DependencyInjectionInit(args) DI framework, service registration, singleton migration
SceneManagementMulti-scene architecture, scene transitions, initialization
WavesWave-based spawning (tutorial and density modes)
BossesBoss encounter system, phase/health mechanics, modular UI (designs)
CutscenesCutscene playback, Dialogue System integration, CutsceneDatabase registry, dev tool

Unity Scene Setup

Detailed breakdown of what GameObjects/components go in each scene:

SceneDescription
BootstrapScenePersistent services (ProfileManager, SaveLoadManager, etc.), loading overlay
GamePlaythroughBaseScenePlaythrough-scoped services (PersistentHelperCatManager, PersistentPlayerProgressionManager)
MainMenuSceneProfile selection, character customization, difficulty selection, game start
GameRunSceneShop, gameplay, victory/loss, tutorial, cutscenes — all run systems

Folder Structure

Assets/_Game/Scripts/
├── Managers/ # Core managers (GameRunManager, GameRunOrchestrator)
├── Systems/ # Feature systems (preferred location for new code)
│ ├── ActiveHelperCats/ # Active ability system
│ ├── CharacterCustomization/
│ ├── GameConfig/ # Remote config
│ ├── GameFlags/ # Runtime flags
│ ├── Overworld/ # Hub world
│ ├── Perfection/ # Perfection multiplier
│ ├── PrepareForShift/ # Shop substates
│ ├── Progression/ # Campaign structure
│ ├── Bosses/ # Boss encounter system (phases, damage, UI)
│ ├── Spawning/ # Adaptive + wave spawn controllers
│ ├── Tutorial/ # Tutorial run manager, sequences, UI
│ ├── UniqueOrderingCats/
│ └── Upgrades/ # Cake upgrades
├── Cutscene/ # Cutscene system (GameCutscene, CutsceneCat, adapters)
├── Data/ # ScriptableObjects and data classes
│ ├── Config/ # JSON-loadable configs
│ └── Runtime/ # Runtime data
├── Controllers/ # Input handling
├── Views/ # UI view components
├── UI/ # UI managers
└── SceneManagement/ # Scene loading, initialization

Testing

Tests are located in Assets/Tests/:

  • CakeUpgradeSystemTest.cs
  • ComboSystemTests.cs, CustomComboTests.cs, PatternComboTests.cs
  • DatabaseIntegrationTests.cs
  • HelperCatsManagerTests.cs

Run via Unity Test Runner (Window → General → Test Runner).

Updating Documentation

When making significant changes to a system, please update the corresponding documentation file. This helps future Claude sessions understand the codebase and maintain consistency.