# gerdaroot/horizon-offline-launcher architecture

> Architecture diagram of the GitHub repository gerdaroot/horizon-offline-launcher, 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/gerdaroot/horizon-offline-launcher
- Repository: https://github.com/gerdaroot/horizon-offline-launcher

## Overview

Horizon Offline Launcher is a desktop launcher for the Rust Horizon game. The main user journey is to obtain a game build, prepare its resources from the player’s Minecraft 26.3 files, then start the game. The README also documents jar discovery or manual selection, automatic updates, offline play, and skin/cape settings. The launcher entry point and preparation/runtime paths are visible in the supplied tree; internal launcher modules and several runtime connections were not sampled, so those are represented only where the README supports them.

Main entry points: [`crates/horizon-client/src`](https://github.com/gerdaroot/horizon-offline-launcher/tree/main/crates/horizon-client/src) (Game runtime), [`launcher/src/main.rs`](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/main.rs) (Launcher app), [`crates/horizon-prepare/src/main.rs`](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-prepare/src/main.rs) (Resource preparation), [`launcher/src/account/session.rs`](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/account/session.rs) (Account settings)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_launcher["Launcher"]
  node_launcher_app["Launcher app<br/>[main.rs]"]
  node_jar_selection["Jar discovery<br/>[main.rs]"]
  node_account_session["Account settings<br/>[session.rs]"]
end

subgraph group_prepare["Game preparation"]
  node_prepare_tool["Resource preparation<br/>[main.rs]"]
  node_prepare_worker["Preparation worker<br/>[worker.rs]"]
  node_port_pipeline["Porting pipeline<br/>[pipeline.rs]"]
end

subgraph group_runtime["Horizon runtime"]
  node_game_runtime["Game runtime"]
  node_game_saves[("World saves<br/>[save.rs]")]
end

subgraph group_gameplay["Gameplay capabilities"]
  node_render_ui["Game UI<br/>[ui.rs]"]
  node_render_chat["Chat<br/>[chat.rs]"]
  node_render_audio["Audio<br/>[audio.rs]"]
  node_boat_gameplay["Boats<br/>[boats.rs]"]
  node_resource_packs["Resource packs<br/>[packs.rs]"]
  node_mods["Mods<br/>[index.rs]"]
  node_friends["Friends play<br/>[session.rs]"]
end

node_player(("Player"))
node_release_repo["Release repository"]
node_minecraft_files["Minecraft files"]

node_player -->|"uses"| node_launcher_app
node_launcher_app -->|"installs updates"| node_release_repo
node_launcher_app -->|"chooses jar"| node_jar_selection
node_jar_selection -->|"finds or selects"| node_minecraft_files
node_launcher_app -->|"starts preparation"| node_prepare_tool
node_prepare_tool -->|"reads game files"| node_minecraft_files
node_prepare_tool -->|"prepares resources for"| node_game_runtime
node_launcher_app -->|"launches"| node_game_runtime
node_player -->|"sets player details"| node_account_session
node_game_runtime -.->|"stores worlds"| node_game_saves
node_game_runtime -.->|"renders interface"| node_render_ui
node_game_runtime -.->|"provides chat"| node_render_chat
node_game_runtime -.->|"plays audio"| node_render_audio
node_game_runtime -.->|"runs gameplay"| node_boat_gameplay
node_game_runtime -->|"supports"| node_resource_packs
node_game_runtime -->|"supports"| node_mods
node_game_runtime -->|"supports"| node_friends

click node_launcher_app "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/main.rs"
click node_jar_selection "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/main.rs"
click node_account_session "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/account/session.rs"
click node_prepare_tool "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-prepare/src/main.rs"
click node_prepare_worker "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-prepare/src/worker.rs"
click node_port_pipeline "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-port-pack/src/pipeline.rs"
click node_game_runtime "https://github.com/gerdaroot/horizon-offline-launcher/tree/main/crates/horizon-client/src"
click node_game_saves "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client/src/save.rs"
click node_render_ui "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/ui.rs"
click node_render_chat "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/chat.rs"
click node_render_audio "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/audio.rs"
click node_boat_gameplay "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client/src/game/boats.rs"
click node_resource_packs "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/packs.rs"
click node_mods "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-mods/src/index.rs"
click node_friends "https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-friends/src/session.rs"

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_app,node_jar_selection,node_account_session toneBlue
class node_prepare_tool,node_prepare_worker,node_port_pipeline toneAmber
class node_game_runtime,node_game_saves toneMint
class node_render_ui,node_render_chat,node_render_audio,node_boat_gameplay,node_resource_packs,node_mods,node_friends toneRose
class node_player,node_release_repo,node_minecraft_files toneIndigo
```

## Components

### Launcher

- [Launcher app](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/main.rs): `launcher/src/main.rs`
- [Jar discovery](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/main.rs): `launcher/src/main.rs`
- [Account settings](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/launcher/src/account/session.rs): `launcher/src/account/session.rs`

### Game preparation

- [Resource preparation](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-prepare/src/main.rs): `crates/horizon-prepare/src/main.rs`
- [Preparation worker](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-prepare/src/worker.rs): `crates/horizon-prepare/src/worker.rs`
- [Porting pipeline](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-port-pack/src/pipeline.rs): `crates/horizon-port-pack/src/pipeline.rs`

### Horizon runtime

- [Game runtime](https://github.com/gerdaroot/horizon-offline-launcher/tree/main/crates/horizon-client/src): `crates/horizon-client/src`
- [World saves](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client/src/save.rs): `crates/horizon-client/src/save.rs`

### Gameplay capabilities

- [Game UI](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/ui.rs): `crates/horizon-client-render/src/ui.rs`
- [Chat](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/chat.rs): `crates/horizon-client-render/src/chat.rs`
- [Audio](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/audio.rs): `crates/horizon-client-render/src/audio.rs`
- [Boats](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client/src/game/boats.rs): `crates/horizon-client/src/game/boats.rs`
- [Resource packs](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-client-render/src/packs.rs): `crates/horizon-client-render/src/packs.rs`
- [Mods](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-mods/src/index.rs): `crates/horizon-mods/src/index.rs`
- [Friends play](https://github.com/gerdaroot/horizon-offline-launcher/blob/main/crates/horizon-friends/src/session.rs): `crates/horizon-friends/src/session.rs`

### Other components

- **Player**
- **Release repository**
- **Minecraft files**

## Connections

- Player → Launcher app: uses
- Launcher app → Release repository: installs updates
- Launcher app → Jar discovery: chooses jar (evidence: `launcher/src/main.rs`)
- Jar discovery → Minecraft files: finds or selects
- Launcher app → Resource preparation: starts preparation
- Resource preparation → Minecraft files: reads game files
- Resource preparation → Game runtime: prepares resources for
- Launcher app → Game runtime: launches
- Player → Account settings: sets player details
- Game runtime → World saves: stores worlds (evidence: `crates/horizon-client/src/command_storage.rs`)
- Game runtime → Game UI: renders interface
- Game runtime → Chat: provides chat
- Game runtime → Audio: plays audio
- Game runtime → Boats: runs gameplay (evidence: `crates/horizon-client/src/game/minecarts.rs`)
- Game runtime → Resource packs: supports
- Game runtime → Mods: supports
- Game runtime → Friends play: supports
