# evenblad3/cheat-trainers architecture

> Architecture diagram of the GitHub repository evenblad3/cheat-trainers, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-26). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/evenblad3/cheat-trainers
- Repository: https://github.com/evenblad3/cheat-trainers

## Overview

This repository provides Windows cheat trainers for Assault Cube and Yamagi Quake II. In Assault Cube, the trainer launches a menu, reads game values, and writes selected changes to the game process; the sampled GUI source shows ammo and nickname controls. In Yamagi Quake II, startup runs a game-state update thread alongside the UI renderer. The UI uses Dear ImGui with Win32/DX11. The README names both game targets, but unsampled cheat and drawing implementations prevent confidently mapping their detailed features or wiring.

Main entry points: [`assaultcube/cheat/gui.cpp`](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/gui.cpp) (Menu and memory controls), [`yquake2/cheat/UI.cpp`](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/UI.cpp) (UI renderer), [`yquake2/cheat/main.cpp`](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/main.cpp) (Trainer entry), [`assaultcube/cheat/main.cpp`](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/main.cpp) (Trainer entry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ac["Assault Cube"]
  node_ac_main["Trainer entry<br/>[main.cpp]"]
  node_ac_gui["Menu and memory controls<br/>[gui.cpp]"]
  node_ac_hack["Game memory helpers<br/>[hack.cpp]"]
  node_ac_game["Assault Cube process"]
end

subgraph group_qy["Yamagi Quake II"]
  node_qy_main["Trainer entry<br/>[main.cpp]"]
  node_qy_state["Game-state updater<br/>[hack.cpp]"]
  node_qy_memory["Memory interface<br/>[hack.hpp]"]
  node_qy_cheat["Cheat operations<br/>[cheat.cpp]"]
  node_qy_data["Game state<br/>[gamestate.hpp]"]
  node_qy_ui["UI renderer<br/>[UI.cpp]"]
  node_qy_draw["Drawing layer<br/>[Drawing.cpp]"]
  node_qy_game["Yamagi Quake II process"]
end

subgraph group_ui["UI rendering"]
  node_ac_imgui["Dear ImGui<br/>[imgui.cpp]"]
  node_ac_dx["DX9 renderer backend<br/>[imgui_impl_dx9.cpp]"]
  node_ac_win["Win32 input backend"]
  node_qy_imgui["Dear ImGui<br/>[imgui.cpp]"]
  node_qy_dx["DX11 renderer backend"]
  node_qy_win["Win32 input backend"]
end

node_user(("Trainer user"))

node_user -->|"launches"| node_ac_main
node_ac_main -->|"starts render loop"| node_ac_gui
node_ac_gui -->|"builds menu with"| node_ac_imgui
node_ac_gui -->|"renders through"| node_ac_dx
node_ac_gui -->|"handles input through"| node_ac_win
node_ac_gui -->|"reads and writes process memory"| node_ac_game
node_user -->|"launches"| node_qy_main
node_qy_main -->|"starts update thread"| node_qy_state
node_qy_main -->|"runs renderer"| node_qy_ui
node_qy_ui -->|"builds UI with"| node_qy_imgui
node_qy_ui -->|"renders through"| node_qy_dx
node_qy_ui -->|"handles input through"| node_qy_win

click node_ac_main "https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/main.cpp"
click node_ac_gui "https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/gui.cpp"
click node_ac_hack "https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/hack.cpp"
click node_ac_imgui "https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/imgui/imgui.cpp"
click node_ac_dx "https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/imgui/imgui_impl_dx9.cpp"
click node_ac_win "https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/imgui/imgui_impl_win32.cpp"
click node_qy_main "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/main.cpp"
click node_qy_state "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/hack.cpp"
click node_qy_memory "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/hack.hpp"
click node_qy_cheat "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/cheat.cpp"
click node_qy_data "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/gamestate.hpp"
click node_qy_ui "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/UI.cpp"
click node_qy_draw "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/Drawing.cpp"
click node_qy_imgui "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/imgui/imgui.cpp"
click node_qy_dx "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/imgui/imgui_impl_dx11.cpp"
click node_qy_win "https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/imgui/imgui_impl_win32.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_ac_main,node_ac_gui,node_ac_hack,node_ac_game,node_user toneBlue
class node_qy_main,node_qy_state,node_qy_memory,node_qy_cheat,node_qy_data,node_qy_ui,node_qy_draw,node_qy_game toneAmber
class node_ac_imgui,node_ac_dx,node_ac_win,node_qy_imgui,node_qy_dx,node_qy_win toneMint
```

## Components

### Assault Cube

- [Trainer entry](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/main.cpp): `assaultcube/cheat/main.cpp`
- [Menu and memory controls](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/gui.cpp): `assaultcube/cheat/gui.cpp`
- [Game memory helpers](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/cheat/hack.cpp): `assaultcube/cheat/hack.cpp`
- **Assault Cube process**

### Yamagi Quake II

- [Trainer entry](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/main.cpp): `yquake2/cheat/main.cpp`
- [Game-state updater](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/hack.cpp): `yquake2/cheat/hack.cpp`
- [Memory interface](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/hack.hpp): `yquake2/cheat/hack.hpp`
- [Cheat operations](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/cheat.cpp): `yquake2/cheat/cheat.cpp`
- [Game state](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/gamestate.hpp): `yquake2/cheat/gamestate.hpp`
- [UI renderer](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/UI.cpp): `yquake2/cheat/UI.cpp`
- [Drawing layer](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/cheat/Drawing.cpp): `yquake2/cheat/Drawing.cpp`
- **Yamagi Quake II process**

### UI rendering

- [Dear ImGui](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/imgui/imgui.cpp): `assaultcube/imgui/imgui.cpp`
- [DX9 renderer backend](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/imgui/imgui_impl_dx9.cpp): `assaultcube/imgui/imgui_impl_dx9.cpp`
- [Win32 input backend](https://github.com/evenblad3/cheat-trainers/blob/main/assaultcube/imgui/imgui_impl_win32.cpp): `assaultcube/imgui/imgui_impl_win32.cpp`
- [Dear ImGui](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/imgui/imgui.cpp): `yquake2/imgui/imgui.cpp`
- [DX11 renderer backend](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/imgui/imgui_impl_dx11.cpp): `yquake2/imgui/imgui_impl_dx11.cpp`
- [Win32 input backend](https://github.com/evenblad3/cheat-trainers/blob/main/yquake2/imgui/imgui_impl_win32.cpp): `yquake2/imgui/imgui_impl_win32.cpp`

### Other components

- **Trainer user**

## Connections

- Trainer user → Trainer entry: launches
- Trainer entry → Menu and memory controls: starts render loop
- Menu and memory controls → Dear ImGui: builds menu with
- Menu and memory controls → DX9 renderer backend: renders through
- Menu and memory controls → Win32 input backend: handles input through
- Menu and memory controls → Assault Cube process: reads and writes process memory
- Trainer user → Trainer entry: launches
- Trainer entry → Game-state updater: starts update thread
- Trainer entry → UI renderer: runs renderer
- UI renderer → Dear ImGui: builds UI with
- UI renderer → DX11 renderer backend: renders through
- UI renderer → Win32 input backend: handles input through
