# ayr1k/amber-launcher architecture

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

- Interactive diagram: https://gitdiagram.com/ayr1k/amber-launcher
- Repository: https://github.com/ayr1k/amber-launcher

## Overview

AMBER is a desktop launcher for Minecraft: Java Edition. A user works in the launcher UI, where instance and settings actions cross the desktop bridge into runtime services; the launcher manages game libraries and content, then prepares and verifies game launches. Separate branches cover accounts and eligibility, server management and multiplayer, plugins, themes, and AmberLink. The graph reflects documented capabilities plus the shown UI bridge, storage migration, instance persistence, and CurseForge validation; unsampled implementation details and their internal call paths are not inferred.

Main entry points: [`prototype/desktop/main.mjs`](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/main.mjs) (Desktop IPC), [`prototype/desktop/core.mjs`](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/core.mjs) (Instance library), [`prototype/src/App.jsx`](https://github.com/ayr1k/amber-launcher/blob/main/prototype/src/App.jsx) (Launcher UI), [`prototype/desktop/storage.mjs`](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/storage.mjs) (Data storage)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Desktop application"]
  node_ui["Launcher UI<br/>[App.jsx]"]
  node_desktop["Desktop IPC<br/>[main.mjs]"]
  node_storageui["Storage settings<br/>[StoragePanel.jsx]"]
  node_storage[("Data storage<br/>[storage.mjs]")]
end

subgraph group_game["Instances and content"]
  node_instances[("Instance library<br/>[core.mjs]")]
  node_libraries["Library management<br/>[libraries170.mjs]"]
  node_content["Content workflows"]
  node_downloads["Downloads<br/>[download.mjs]"]
  node_launch["Game launch<br/>[launcher.mjs]"]
  node_curseforge["CurseForge service<br/>[curseforge180.mjs]"]
end

subgraph group_identity["Identity and multiplayer"]
  node_accounts["Accounts and eligibility<br/>[accounts.mjs]"]
  node_servers["Server management<br/>[servers132.mjs]"]
  node_rooms["Multiplayer rooms<br/>[rooms132.mjs]"]
  node_amberlink["AmberLink host<br/>[amberlink-host.mjs]"]
end

subgraph group_extensions["Customization and extensions"]
  node_plugins["Plugin system<br/>[plugin-host.mjs]"]
  node_themes["Themes and appearance<br/>[themes.mjs]"]
  node_language["Localization<br/>[localization.mjs]"]
end

node_user(("Launcher user"))
node_curseforgeupstream(("CurseForge upstream"))
node_phone(("AmberLink phone"))

node_user -->|"uses"| node_ui
node_ui -->|"invokes bridge"| node_desktop
node_desktop -->|"migrates data"| node_storage
node_storageui -->|"requests migration"| node_desktop
node_storage -->|"validates relocation"| node_libraries
node_desktop -->|"manages instances"| node_instances
node_instances -.->|"supports libraries"| node_libraries
node_user -->|"installs and manages"| node_instances
node_user -->|"searches and imports"| node_content
node_content -->|"requests files"| node_downloads
node_user -->|"launches game"| node_launch
node_desktop -.->|"handles sign-in"| node_accounts
node_user -->|"manages servers"| node_servers
node_user -->|"joins rooms"| node_rooms
node_user -->|"uses plugins"| node_plugins
node_user -->|"customizes appearance"| node_themes
node_user -->|"selects language"| node_language
node_desktop -.->|"routes requests"| node_curseforge
node_curseforge -->|"validates metadata"| node_curseforgeupstream
node_phone -->|"pairs"| node_amberlink

click node_ui "https://github.com/ayr1k/amber-launcher/blob/main/prototype/src/App.jsx"
click node_desktop "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/main.mjs"
click node_storageui "https://github.com/ayr1k/amber-launcher/blob/main/prototype/src/StoragePanel.jsx"
click node_storage "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/storage.mjs"
click node_instances "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/core.mjs"
click node_libraries "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/libraries170.mjs"
click node_content "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/content-sources176.mjs"
click node_downloads "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/download.mjs"
click node_launch "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/launcher.mjs"
click node_accounts "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/accounts.mjs"
click node_servers "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/servers132.mjs"
click node_rooms "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/rooms132.mjs"
click node_plugins "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/plugin-host.mjs"
click node_themes "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/themes.mjs"
click node_language "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/localization.mjs"
click node_curseforge "https://github.com/ayr1k/amber-launcher/blob/main/prototype/worker/curseforge180.mjs"
click node_amberlink "https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/amberlink-host.mjs"

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_ui,node_desktop,node_storageui,node_storage,node_user toneBlue
class node_instances,node_libraries,node_content,node_downloads,node_launch,node_curseforge toneAmber
class node_accounts,node_servers,node_rooms,node_amberlink toneMint
class node_plugins,node_themes,node_language toneRose
class node_curseforgeupstream,node_phone toneIndigo
```

## Components

### Desktop application

- [Launcher UI](https://github.com/ayr1k/amber-launcher/blob/main/prototype/src/App.jsx): `prototype/src/App.jsx`
- [Desktop IPC](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/main.mjs): `prototype/desktop/main.mjs`
- [Storage settings](https://github.com/ayr1k/amber-launcher/blob/main/prototype/src/StoragePanel.jsx): `prototype/src/StoragePanel.jsx`
- [Data storage](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/storage.mjs): `prototype/desktop/storage.mjs`

### Instances and content

- [Instance library](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/core.mjs): `prototype/desktop/core.mjs`
- [Library management](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/libraries170.mjs): `prototype/desktop/libraries170.mjs`
- [Content workflows](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/content-sources176.mjs): `prototype/desktop/content-sources176.mjs`
- [Downloads](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/download.mjs): `prototype/desktop/download.mjs`
- [Game launch](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/launcher.mjs): `prototype/desktop/launcher.mjs`
- [CurseForge service](https://github.com/ayr1k/amber-launcher/blob/main/prototype/worker/curseforge180.mjs): `prototype/worker/curseforge180.mjs`

### Identity and multiplayer

- [Accounts and eligibility](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/accounts.mjs): `prototype/desktop/accounts.mjs`
- [Server management](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/servers132.mjs): `prototype/desktop/servers132.mjs`
- [Multiplayer rooms](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/rooms132.mjs): `prototype/desktop/rooms132.mjs`
- [AmberLink host](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/amberlink-host.mjs): `prototype/desktop/amberlink-host.mjs`

### Customization and extensions

- [Plugin system](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/plugin-host.mjs): `prototype/desktop/plugin-host.mjs`
- [Themes and appearance](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/themes.mjs): `prototype/desktop/themes.mjs`
- [Localization](https://github.com/ayr1k/amber-launcher/blob/main/prototype/desktop/localization.mjs): `prototype/desktop/localization.mjs`

### Other components

- **Launcher user**
- **CurseForge upstream**
- **AmberLink phone**

## Connections

- Launcher user → Launcher UI: uses (evidence: `README.md`)
- Launcher UI → Desktop IPC: invokes bridge
- Desktop IPC → Data storage: migrates data (evidence: `prototype/desktop/main.mjs`)
- Storage settings → Desktop IPC: requests migration (evidence: `prototype/src/StoragePanel.jsx`)
- Data storage → Library management: validates relocation (evidence: `prototype/desktop/storage.mjs`)
- Desktop IPC → Instance library: manages instances (evidence: `prototype/desktop/main.mjs`)
- Instance library → Library management: supports libraries (evidence: `prototype/desktop/libraries170.mjs`)
- Launcher user → Instance library: installs and manages (evidence: `README.md`)
- Launcher user → Content workflows: searches and imports (evidence: `README.md`)
- Content workflows → Downloads: requests files (evidence: `prototype/desktop/download.mjs`)
- Launcher user → Game launch: launches game (evidence: `README.md`)
- Desktop IPC → Accounts and eligibility: handles sign-in
- Launcher user → Server management: manages servers (evidence: `README.md`)
- Launcher user → Multiplayer rooms: joins rooms (evidence: `README.md`)
- Launcher user → Plugin system: uses plugins (evidence: `README.md`)
- Launcher user → Themes and appearance: customizes appearance (evidence: `README.md`)
- Launcher user → Localization: selects language (evidence: `README.md`)
- Desktop IPC → CurseForge service: routes requests
- CurseForge service → CurseForge upstream: validates metadata (evidence: `prototype/worker/curseforge180.mjs`)
- AmberLink phone → AmberLink host: pairs (evidence: `prototype/desktop/amberlink-host.mjs`)
