# wantwon/copygame_directx9_don-t_starve architecture

> Architecture diagram of the GitHub repository wantwon/copygame_directx9_don-t_starve, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-12-02). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/wantwon/copygame_directx9_don-t_starve
- Repository: https://github.com/wantwon/copygame_directx9_don-t_starve

## Overview

This repository contains a DirectX 9 survival-game project and an MFC map tool. The principal player workflow is entering a level, navigating its environment, surviving encounters and dungeon challenges, and using items and UI systems to progress. The README documents the major gameplay and engine capabilities; sampled source confirms camera selection through the engine object manager and the map tool’s use of engine and terrain modules. Many client subsystems were not sampled, so their documented relationships are cited to the README rather than inferred from filenames.

Main entry points: [`SR_Project/Client/Private/Player.cpp`](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Player.cpp) (Player), [`SR_Project/Engine/Private/GameInstance.cpp`](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/GameInstance.cpp) (Engine Instance), [`SR_Project/Engine/Private/Renderer.cpp`](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/Renderer.cpp) (Rendering and Shaders), [`SR_MapTool/Tool/MainApp.cpp`](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_MapTool/Tool/MainApp.cpp) (MFC Map Tool)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_engine["Engine Runtime"]
  node_engine["Engine Instance<br/>[GameInstance.cpp]"]
  node_objects["Object and Level Managers<br/>[Object_Manager.cpp]"]
  node_collision["Collision Manager"]
  node_rendering["Rendering and Shaders<br/>[Renderer.cpp]"]
end

subgraph group_gameplay["Game World"]
  node_player["Player<br/>[Player.cpp]"]
  node_levels["Levels<br/>[Level_GamePlay.cpp]"]
  node_enemies["Monsters and NPCs<br/>[Monster.cpp]"]
  node_dungeons["Dungeon Challenges<br/>[Level_Maze.cpp]"]
  node_world["Environment and Effects<br/>[Terrain.cpp]"]
end

subgraph group_systems["Player Systems"]
  node_inventory["Inventory and Crafting<br/>[Inventory.cpp]"]
  node_quests["Quests and Party<br/>[Quest.cpp]"]
  node_daycycle["Day Cycle<br/>[DayCycle.cpp]"]
end

subgraph group_presentation["Presentation"]
  node_ui["Game UI<br/>[MainInventory.cpp]"]
  node_camera["Camera Manager<br/>[CameraManager.cpp]"]
end

subgraph group_authoring["Map Authoring"]
  node_maptool["MFC Map Tool<br/>[MainApp.cpp]"]
  node_engine_tool["Map Tool Engine<br/>[GameInstance.cpp]"]
end

node_user(("Player"))

node_user -->|"controls"| node_player
node_player -->|"plays through"| node_levels
node_levels -->|"includes"| node_dungeons
node_player -->|"fights"| node_enemies
node_player -->|"uses items"| node_inventory
node_player -->|"pursues"| node_quests
node_daycycle -->|"changes shaders"| node_rendering
node_world -->|"renders with"| node_rendering
node_camera -->|"gets objects"| node_engine
node_engine -->|"manages"| node_objects
node_engine -->|"updates"| node_collision
node_engine -->|"ticks and renders"| node_rendering
node_maptool -->|"uses"| node_engine_tool
node_maptool -->|"exports map data"| node_world

click node_player "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Player.cpp"
click node_levels "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Level_GamePlay.cpp"
click node_enemies "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Monster.cpp"
click node_dungeons "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Level_Maze.cpp"
click node_world "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Terrain.cpp"
click node_inventory "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Inventory.cpp"
click node_quests "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Quest.cpp"
click node_daycycle "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/DayCycle.cpp"
click node_ui "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/MainInventory.cpp"
click node_camera "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/CameraManager.cpp"
click node_engine "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/GameInstance.cpp"
click node_objects "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/Object_Manager.cpp"
click node_collision "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/Collider_Manager.cpp"
click node_rendering "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/Renderer.cpp"
click node_maptool "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_MapTool/Tool/MainApp.cpp"
click node_engine_tool "https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_MapTool/Engine/Private/GameInstance.cpp"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_engine,node_objects,node_collision,node_rendering toneBlue
class node_player,node_levels,node_enemies,node_dungeons,node_world toneAmber
class node_inventory,node_quests,node_daycycle toneMint
class node_ui,node_camera toneRose
class node_maptool,node_engine_tool,node_user toneIndigo
```

## Components

### Engine Runtime

- [Engine Instance](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/GameInstance.cpp): `SR_Project/Engine/Private/GameInstance.cpp`
- [Object and Level Managers](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/Object_Manager.cpp): `SR_Project/Engine/Private/Object_Manager.cpp`
- [Collision Manager](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/Collider_Manager.cpp): `SR_Project/Engine/Private/Collider_Manager.cpp`
- [Rendering and Shaders](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Engine/Private/Renderer.cpp): `SR_Project/Engine/Private/Renderer.cpp`

### Game World

- [Player](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Player.cpp): `SR_Project/Client/Private/Player.cpp`
- [Levels](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Level_GamePlay.cpp): `SR_Project/Client/Private/Level_GamePlay.cpp`
- [Monsters and NPCs](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Monster.cpp): `SR_Project/Client/Private/Monster.cpp`
- [Dungeon Challenges](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Level_Maze.cpp): `SR_Project/Client/Private/Level_Maze.cpp`
- [Environment and Effects](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Terrain.cpp): `SR_Project/Client/Private/Terrain.cpp`

### Player Systems

- [Inventory and Crafting](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Inventory.cpp): `SR_Project/Client/Private/Inventory.cpp`
- [Quests and Party](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/Quest.cpp): `SR_Project/Client/Private/Quest.cpp`
- [Day Cycle](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/DayCycle.cpp): `SR_Project/Client/Private/DayCycle.cpp`

### Presentation

- [Game UI](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/MainInventory.cpp): `SR_Project/Client/Private/MainInventory.cpp`
- [Camera Manager](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_Project/Client/Private/CameraManager.cpp): `SR_Project/Client/Private/CameraManager.cpp`

### Map Authoring

- [MFC Map Tool](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_MapTool/Tool/MainApp.cpp): `SR_MapTool/Tool/MainApp.cpp`
- [Map Tool Engine](https://github.com/wantwon/copygame_directx9_don-t_starve/blob/main/SR_MapTool/Engine/Private/GameInstance.cpp): `SR_MapTool/Engine/Private/GameInstance.cpp`

### Other components

- **Player**

## Connections

- Player → Player: controls (evidence: `README.md`)
- Player → Levels: plays through (evidence: `README.md`)
- Levels → Dungeon Challenges: includes (evidence: `README.md`)
- Player → Monsters and NPCs: fights (evidence: `README.md`)
- Player → Inventory and Crafting: uses items (evidence: `README.md`)
- Player → Quests and Party: pursues (evidence: `README.md`)
- Day Cycle → Rendering and Shaders: changes shaders (evidence: `README.md`)
- Environment and Effects → Rendering and Shaders: renders with (evidence: `README.md`)
- Camera Manager → Engine Instance: gets objects (evidence: `SR_Project/Client/Private/CameraManager.cpp`)
- Engine Instance → Object and Level Managers: manages (evidence: `README.md`)
- Engine Instance → Collision Manager: updates (evidence: `README.md`)
- Engine Instance → Rendering and Shaders: ticks and renders (evidence: `README.md`)
- MFC Map Tool → Map Tool Engine: uses (evidence: `SR_MapTool/Tool/MainApp.cpp`)
- MFC Map Tool → Environment and Effects: exports map data (evidence: `README.md`)
