# btr-rj/redbaron_recomp architecture

> Architecture diagram of the GitHub repository btr-rj/redbaron_recomp, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/btr-rj/redbaron_recomp
- Repository: https://github.com/btr-rj/redbaron_recomp

## Overview

RedBaron_Recomp combines a Windows launcher that installs or updates a locally built game with a native Xbox 360 recompilation port. The main user workflow is: supply game files, choose an install destination and settings, build/install, then launch and play; updates use a separate verified download-and-apply path. In-game stages include input/video handling and optional Epic Online Services matchmaking, social features, achievements and leaderboards over the network transport. The map includes README-documented capabilities whose implementation was not sampled; those links are cited to the README. Unsampled source limits confidence in finer internal call relationships.

Main entry points: [`port/eos/online_service.cpp`](https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/online_service.cpp) (Online service orchestration), [`port/src/main.cpp`](https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/main.cpp) (Game entry), [`launcher/src/LauncherWindow.cs`](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/LauncherWindow.cs) (Install and settings UI), [`launcher/src/Services.cs`](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/Services.cs) (Install and play services)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_launcher["Launcher and installs"]
  node_launcherapp["Launcher startup<br/>[Program.cs]"]
  node_launcherui["Install and settings UI<br/>[LauncherWindow.cs]"]
  node_services["Install and play services<br/>[Services.cs]"]
  node_progress["Progress parsing<br/>[InstallProgress.cs]"]
  node_updates["Release check and download<br/>[Updates.cs]"]
  node_autoupdate["Verified update and recovery<br/>[AutomaticUpdate.cs]"]
  node_cleanup["Installation cleanup"]
end

subgraph group_runtime["Game runtime"]
  node_gameentry["Game entry<br/>[main.cpp]"]
  node_input["Input mapping<br/>[local_input.cpp]"]
  node_video["Video features<br/>[video.cpp]"]
  node_content["Game content inspection"]
  node_gameonline["Game online integration<br/>[online.cpp]"]
end

subgraph group_eos["Epic online services"]
  node_eosservice["Online service orchestration<br/>[online_service.cpp]"]
  node_lobby["Lobby and matchmaking"]
  node_social["Friends and invites<br/>[social.cpp]"]
  node_achievements["Achievement sync"]
  node_leaderboards["Leaderboards<br/>[leaderboards.cpp]"]
end

subgraph group_network["Network transport"]
  node_networkmain["Network process<br/>[main.cpp]"]
  node_transport["Session transport<br/>[transport.cpp]"]
  node_bridge["Game socket bridge<br/>[socket_bridge.cpp]"]
  node_publisher["Session publisher"]
end

node_player(("Player"))
node_gamefiles["Supplied game files"]
node_github["GitHub releases"]
node_epic["EOS services"]

node_player -->|"opens"| node_launcherapp
node_gamefiles -->|"selects for install"| node_launcherui
node_launcherapp -->|"opens"| node_launcherui
node_launcherui -->|"requests install and play"| node_services
node_services -.->|"reports progress"| node_progress
node_services -.->|"cleans installation"| node_cleanup
node_launcherui -->|"checks and downloads"| node_updates
node_updates -->|"fetches releases"| node_github
node_launcherui -->|"applies update"| node_autoupdate
node_autoupdate -->|"uses package metadata"| node_updates
node_launcherapp -->|"starts recovery"| node_autoupdate
node_services -->|"launches game"| node_gameentry
node_player -->|"plays"| node_gameentry
node_gameentry -.->|"uses input mapping"| node_input
node_gameentry -->|"provides video features"| node_video
node_gameentry -.->|"inspects content"| node_content
node_gameentry -->|"supports online play"| node_gameonline
node_gameonline -->|"uses online service"| node_eosservice
node_eosservice -->|"refreshes directory"| node_lobby
node_eosservice -->|"dispatches social features"| node_social
node_eosservice -->|"dispatches achievement sync"| node_achievements
node_eosservice -->|"configures leaderboards"| node_leaderboards
node_eosservice -->|"uses EOS"| node_epic
node_networkmain -->|"constructs"| node_transport
node_networkmain -->|"constructs"| node_bridge
node_networkmain -->|"publishes sessions"| node_publisher
node_transport -->|"delivers packets"| node_bridge
node_eosservice -->|"uses socket bridge"| node_bridge
node_player -.->|"signs in optionally"| node_epic

click node_launcherapp "https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/Program.cs"
click node_launcherui "https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/LauncherWindow.cs"
click node_services "https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/Services.cs"
click node_progress "https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/InstallProgress.cs"
click node_updates "https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/Updates.cs"
click node_autoupdate "https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/AutomaticUpdate.cs"
click node_cleanup "https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/InstallationCleanup.cs"
click node_gameentry "https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/main.cpp"
click node_input "https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/local_input.cpp"
click node_video "https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/video.cpp"
click node_content "https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/content_inspect.cpp"
click node_gameonline "https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/online.cpp"
click node_eosservice "https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/online_service.cpp"
click node_lobby "https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/lobby_directory.cpp"
click node_social "https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/social.cpp"
click node_achievements "https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/achievement_sync.cpp"
click node_leaderboards "https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/leaderboards.cpp"
click node_networkmain "https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/main.cpp"
click node_transport "https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/transport.cpp"
click node_bridge "https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/socket_bridge.cpp"
click node_publisher "https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/session_publisher.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_launcherapp,node_launcherui,node_services,node_progress,node_updates,node_autoupdate,node_cleanup toneBlue
class node_gameentry,node_input,node_video,node_content,node_gameonline toneAmber
class node_eosservice,node_lobby,node_social,node_achievements,node_leaderboards toneMint
class node_networkmain,node_transport,node_bridge,node_publisher toneRose
class node_player,node_gamefiles,node_github,node_epic toneIndigo
```

## Components

### Launcher and installs

- [Launcher startup](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/Program.cs): `launcher/src/Program.cs`
- [Install and settings UI](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/LauncherWindow.cs): `launcher/src/LauncherWindow.cs`
- [Install and play services](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/Services.cs): `launcher/src/Services.cs`
- [Progress parsing](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/InstallProgress.cs): `launcher/src/InstallProgress.cs`
- [Release check and download](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/Updates.cs): `launcher/src/Updates.cs`
- [Verified update and recovery](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/AutomaticUpdate.cs): `launcher/src/AutomaticUpdate.cs`
- [Installation cleanup](https://github.com/btr-rj/redbaron_recomp/blob/main/launcher/src/InstallationCleanup.cs): `launcher/src/InstallationCleanup.cs`

### Game runtime

- [Game entry](https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/main.cpp): `port/src/main.cpp`
- [Input mapping](https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/local_input.cpp): `port/src/local_input.cpp`
- [Video features](https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/video.cpp): `port/src/video.cpp`
- [Game content inspection](https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/content_inspect.cpp): `port/src/content_inspect.cpp`
- [Game online integration](https://github.com/btr-rj/redbaron_recomp/blob/main/port/src/online.cpp): `port/src/online.cpp`

### Epic online services

- [Online service orchestration](https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/online_service.cpp): `port/eos/online_service.cpp`
- [Lobby and matchmaking](https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/lobby_directory.cpp): `port/eos/lobby_directory.cpp`
- [Friends and invites](https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/social.cpp): `port/eos/social.cpp`
- [Achievement sync](https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/achievement_sync.cpp): `port/eos/achievement_sync.cpp`
- [Leaderboards](https://github.com/btr-rj/redbaron_recomp/blob/main/port/eos/leaderboards.cpp): `port/eos/leaderboards.cpp`

### Network transport

- [Network process](https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/main.cpp): `port/network/main.cpp`
- [Session transport](https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/transport.cpp): `port/network/transport.cpp`
- [Game socket bridge](https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/socket_bridge.cpp): `port/network/socket_bridge.cpp`
- [Session publisher](https://github.com/btr-rj/redbaron_recomp/blob/main/port/network/session_publisher.cpp): `port/network/session_publisher.cpp`

### Other components

- **Player**
- **Supplied game files**
- **GitHub releases**
- **EOS services**

## Connections

- Player → Launcher startup: opens (evidence: `README.md`)
- Supplied game files → Install and settings UI: selects for install (evidence: `README.md`)
- Launcher startup → Install and settings UI: opens (evidence: `launcher/src/Program.cs`)
- Install and settings UI → Install and play services: requests install and play (evidence: `launcher/src/LauncherWindow.cs`)
- Install and play services → Progress parsing: reports progress (evidence: `launcher/src/Services.cs`)
- Install and play services → Installation cleanup: cleans installation (evidence: `launcher/src/Services.cs`)
- Install and settings UI → Release check and download: checks and downloads (evidence: `launcher/src/LauncherWindow.cs`)
- Release check and download → GitHub releases: fetches releases (evidence: `launcher/src/Updates.cs`)
- Install and settings UI → Verified update and recovery: applies update (evidence: `launcher/src/LauncherWindow.cs`)
- Verified update and recovery → Release check and download: uses package metadata (evidence: `launcher/src/AutomaticUpdate.cs`)
- Launcher startup → Verified update and recovery: starts recovery (evidence: `launcher/src/Program.cs`)
- Install and play services → Game entry: launches game (evidence: `launcher/src/Services.cs`)
- Player → Game entry: plays (evidence: `README.md`)
- Game entry → Input mapping: uses input mapping
- Game entry → Video features: provides video features (evidence: `README.md`)
- Game entry → Game content inspection: inspects content
- Game entry → Game online integration: supports online play (evidence: `README.md`)
- Game online integration → Online service orchestration: uses online service (evidence: `port/src/online.cpp`)
- Online service orchestration → Lobby and matchmaking: refreshes directory (evidence: `port/eos/online_service.cpp`)
- Online service orchestration → Friends and invites: dispatches social features (evidence: `port/eos/online_service.cpp`)
- Online service orchestration → Achievement sync: dispatches achievement sync (evidence: `port/eos/online_service.cpp`)
- Online service orchestration → Leaderboards: configures leaderboards (evidence: `port/eos/online_service.cpp`)
- Online service orchestration → EOS services: uses EOS (evidence: `README.md`)
- Network process → Session transport: constructs (evidence: `port/network/main.cpp`)
- Network process → Game socket bridge: constructs (evidence: `port/network/main.cpp`)
- Network process → Session publisher: publishes sessions (evidence: `port/network/main.cpp`)
- Session transport → Game socket bridge: delivers packets
- Online service orchestration → Game socket bridge: uses socket bridge (evidence: `port/eos/online_service.cpp`)
- Player → EOS services: signs in optionally (evidence: `README.md`)
