# nour9264/cosmic-recomp-work architecture

> Architecture diagram of the GitHub repository nour9264/cosmic-recomp-work, 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/nour9264/cosmic-recomp-work
- Repository: https://github.com/nour9264/cosmic-recomp-work

## Overview

Cosmic Recomp is a launcher and native PC-enhancement mod for Ben 10: prepare an Xbox 360 ISO through the launcher, install bundled content and patches, then launch the game with added PC controls and gameplay features. In-game, the PC menu exposes options such as language, video, upgrades, and photo mode; separate runtime systems provide music integration and cinematic playback. The README documents broader capabilities than the sampled code, so those feature links are documented rather than claims that every implementation was inspected.

Main entry points: [`native-rex/src/pc_menu_bridge.h`](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/pc_menu_bridge.h) (PC Menu), [`native-rex/src/options_video_preview.h`](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/options_video_preview.h) (Options Pages), [`launcher/InstalledGame.cs`](https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/InstalledGame.cs) (Installed Game), [`native-rex/src/ben10_app.h`](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/ben10_app.h) (Game Hooks)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_launcher["Launcher &amp; Setup"]
  node_launcher_ui["Launcher UI<br/>[Program.cs]"]
  node_launcher_app["Launcher Setup<br/>[main.cpp]"]
  node_iso["ISO Handling<br/>[IsoImage.cs]"]
  node_installed["Installed Game<br/>[InstalledGame.cs]"]
end

subgraph group_integration["Game Integration"]
  node_patches["Game Patches<br/>[AllAliensPatch.cs]"]
  node_native_entry["Native Entry<br/>[main.cpp]"]
  node_app_hooks["Game Hooks<br/>[ben10_app.h]"]
end

subgraph group_gameplay["Gameplay Features"]
  node_photo["Photo Mode<br/>[photo_mode.h]"]
  node_upgrades["Upgrades &amp; Cosmetics<br/>[upgrade_ui.h]"]
  node_alien_roster["Alien Roster"]
end

subgraph group_pc["PC Experience"]
  node_menu["PC Menu<br/>[pc_menu_bridge.h]"]
  node_options["Options Pages"]
  node_languages["Game Languages"]
  node_music["Music Integration<br/>[music_session.cpp]"]
  node_cinematics["Cinematics &amp; Subtitles"]
end

node_player(("Player"))
node_windows_media["Windows Media"]

node_player -->|"starts setup"| node_launcher_ui
node_launcher_ui -->|"launches game"| node_installed
node_launcher_app -.->|"reads ISO"| node_iso
node_launcher_app -.->|"prepares installation"| node_installed
node_installed -->|"uses image data"| node_iso
node_installed -.->|"applies patches"| node_patches
node_native_entry -->|"includes app hooks"| node_app_hooks
node_app_hooks -->|"integrates menu"| node_menu
node_menu -->|"opens"| node_photo
node_menu -->|"opens"| node_upgrades
node_menu -->|"configures paging"| node_alien_roster
node_menu -.->|"provides menu bridge"| node_options
node_options -->|"configures"| node_photo
node_options -->|"configures"| node_upgrades
node_options -.->|"selects language"| node_languages
node_options -->|"configures"| node_music
node_windows_media -.->|"provides media session"| node_music
node_app_hooks -.->|"supports playback"| node_cinematics

click node_launcher_ui "https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/Program.cs"
click node_launcher_app "https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/native/main.cpp"
click node_iso "https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/IsoImage.cs"
click node_installed "https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/InstalledGame.cs"
click node_patches "https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/AllAliensPatch.cs"
click node_native_entry "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/main.cpp"
click node_app_hooks "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/ben10_app.h"
click node_menu "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/pc_menu_bridge.h"
click node_options "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/options_video_preview.h"
click node_photo "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/photo_mode.h"
click node_upgrades "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/upgrade_ui.h"
click node_alien_roster "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/all_aliens_paging.h"
click node_languages "https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/native/launcher_languages.h"
click node_music "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/music_session.cpp"
click node_cinematics "https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/cinematic_player.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_launcher_ui,node_launcher_app,node_iso,node_installed toneBlue
class node_patches,node_native_entry,node_app_hooks toneAmber
class node_photo,node_upgrades,node_alien_roster toneMint
class node_menu,node_options,node_languages,node_music,node_cinematics toneRose
class node_player,node_windows_media toneIndigo
```

## Components

### Launcher & Setup

- [Launcher UI](https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/Program.cs): `launcher/Program.cs`
- [Launcher Setup](https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/native/main.cpp): `launcher/native/main.cpp`
- [ISO Handling](https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/IsoImage.cs): `launcher/IsoImage.cs`
- [Installed Game](https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/InstalledGame.cs): `launcher/InstalledGame.cs`

### Game Integration

- [Game Patches](https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/AllAliensPatch.cs): `launcher/AllAliensPatch.cs`
- [Native Entry](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/main.cpp): `native-rex/src/main.cpp`
- [Game Hooks](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/ben10_app.h): `native-rex/src/ben10_app.h`

### Gameplay Features

- [Photo Mode](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/photo_mode.h): `native-rex/src/photo_mode.h`
- [Upgrades & Cosmetics](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/upgrade_ui.h): `native-rex/src/upgrade_ui.h`
- [Alien Roster](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/all_aliens_paging.h): `native-rex/src/all_aliens_paging.h`

### PC Experience

- [PC Menu](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/pc_menu_bridge.h): `native-rex/src/pc_menu_bridge.h`
- [Options Pages](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/options_video_preview.h): `native-rex/src/options_video_preview.h`
- [Game Languages](https://github.com/nour9264/cosmic-recomp-work/blob/main/launcher/native/launcher_languages.h): `launcher/native/launcher_languages.h`
- [Music Integration](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/music_session.cpp): `native-rex/src/music_session.cpp`
- [Cinematics & Subtitles](https://github.com/nour9264/cosmic-recomp-work/blob/main/native-rex/src/cinematic_player.cpp): `native-rex/src/cinematic_player.cpp`

### Other components

- **Player**
- **Windows Media**

## Connections

- Player → Launcher UI: starts setup (evidence: `launcher/Program.cs`)
- Launcher UI → Installed Game: launches game (evidence: `launcher/Program.cs`)
- Launcher Setup → ISO Handling: reads ISO
- Launcher Setup → Installed Game: prepares installation
- Installed Game → ISO Handling: uses image data (evidence: `launcher/InstalledGame.cs`)
- Installed Game → Game Patches: applies patches
- Native Entry → Game Hooks: includes app hooks (evidence: `native-rex/src/main.cpp`)
- Game Hooks → PC Menu: integrates menu
- PC Menu → Photo Mode: opens (evidence: `native-rex/src/pc_menu_bridge.h`)
- PC Menu → Upgrades & Cosmetics: opens (evidence: `native-rex/src/pc_menu_bridge.h`)
- PC Menu → Alien Roster: configures paging (evidence: `native-rex/src/pc_menu_bridge.h`)
- PC Menu → Options Pages: provides menu bridge (evidence: `native-rex/src/options_video_preview.h`)
- Options Pages → Photo Mode: configures (evidence: `native-rex/src/options_video_preview.h`)
- Options Pages → Upgrades & Cosmetics: configures (evidence: `native-rex/src/options_video_preview.h`)
- Options Pages → Game Languages: selects language
- Options Pages → Music Integration: configures (evidence: `native-rex/src/options_video_preview.h`)
- Windows Media → Music Integration: provides media session
- Game Hooks → Cinematics & Subtitles: supports playback
