# screamycat/openplay architecture

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

- Interactive diagram: https://gitdiagram.com/screamycat/openplay
- Repository: https://github.com/screamycat/openplay

## Overview

OpenPlay is a cross-platform desktop game launcher and library manager. A player browses or imports a unified collection, enriches it with store and community metadata, then launches games or manages achievements, emulation, backups, sync, and customization. The React interface communicates with a Rust/Tauri backend; the backend coordinates scanning, persistence, metadata, and runtime features. The README documents several capabilities whose individual implementations were not sampled, so those links are shown only where documented, without inferring internal call chains.

Main entry points: [`src-tauri/src/lib.rs`](https://github.com/screamycat/openplay/blob/main/src-tauri/src/lib.rs) (Tauri commands), [`src/App.tsx`](https://github.com/screamycat/openplay/blob/main/src/App.tsx) (Application shell), [`src-tauri/src/scanner/providers.rs`](https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/providers.rs) (Store scanners), [`src-tauri/src/db/mod.rs`](https://github.com/screamycat/openplay/blob/main/src-tauri/src/db/mod.rs) (Game database)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["Player interface"]
  node_app["Application shell<br/>[App.tsx]"]
  node_game_views["Library views<br/>[GameDetails.tsx]"]
  node_library_manager["Library manager"]
  node_achievement_hub["Achievement hub"]
end

subgraph group_library["Library and metadata"]
  node_backend["Tauri commands<br/>[lib.rs]"]
  node_scanner["Store scanners<br/>[providers.rs]"]
  node_steam_scanner["Steam scanner<br/>[steam.rs]"]
  node_epic_scanner["Epic scanner<br/>[epic.rs]"]
  node_playnite_scanner["Playnite importer<br/>[playnite.rs]"]
  node_local_scanner["Local scanner<br/>[local.rs]"]
  node_metadata["Metadata providers"]
  node_database[("Game database<br/>[mod.rs]")]
end

subgraph group_runtime["Play and emulation"]
  node_launcher["Game launcher<br/>[mod.rs]"]
  node_emulator["Emulator management<br/>[mod.rs]"]
end

subgraph group_services["Progress and portability"]
  node_achievements["Achievement data<br/>[providers.rs]"]
  node_cloud_sync["Cloud sync<br/>[mod.rs]"]
  node_backups["Backup tools"]
end

subgraph group_customization["Customization and extensions"]
  node_themes_ui["Theme manager"]
  node_theme_engine["Theme engine<br/>[themeEngine.ts]"]
  node_themes_backend["Theme services<br/>[mod.rs]"]
  node_plugins_ui["Plugin manager"]
  node_plugins_backend["Plugin runtime<br/>[mod.rs]"]
end

node_player(("Player"))

node_player -->|"uses"| node_app
node_app -->|"renders"| node_game_views
node_app -->|"opens"| node_library_manager
node_app -->|"opens"| node_achievement_hub
node_app -->|"invokes commands"| node_backend
node_library_manager -->|"invokes commands"| node_backend
node_backend -->|"coordinates scans"| node_scanner
node_scanner -->|"dispatches to"| node_steam_scanner
node_scanner -->|"dispatches to"| node_epic_scanner
node_scanner -->|"uses"| node_playnite_scanner
node_scanner -->|"dispatches to"| node_local_scanner
node_backend -->|"uses"| node_metadata
node_backend -->|"reads and writes"| node_database
node_backend -->|"dispatches launches"| node_launcher
node_backend -->|"manages emulation"| node_emulator
node_achievement_hub -.->|"loads progress"| node_backend
node_backend -->|"collects achievement data"| node_achievements
node_backend -->|"supports device sync"| node_cloud_sync
node_cloud_sync -->|"reads and writes"| node_database
node_library_manager -->|"manages backups"| node_backups
node_themes_ui -->|"invokes theme commands"| node_backend
node_themes_ui -.->|"applies customization"| node_theme_engine
node_theme_engine -.->|"loads theme assets"| node_themes_backend
node_themes_backend -->|"persists themes"| node_database
node_plugins_ui -.->|"manages plugins"| node_plugins_backend
node_plugins_backend -->|"uses persistence"| node_database

click node_app "https://github.com/screamycat/openplay/blob/main/src/App.tsx"
click node_game_views "https://github.com/screamycat/openplay/blob/main/src/components/GameDetails.tsx"
click node_library_manager "https://github.com/screamycat/openplay/blob/main/src/components/LibraryManagerModal.tsx"
click node_achievement_hub "https://github.com/screamycat/openplay/blob/main/src/components/AchievementHunterHub.tsx"
click node_backend "https://github.com/screamycat/openplay/blob/main/src-tauri/src/lib.rs"
click node_scanner "https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/providers.rs"
click node_steam_scanner "https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/steam.rs"
click node_epic_scanner "https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/epic.rs"
click node_playnite_scanner "https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/playnite.rs"
click node_local_scanner "https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/local.rs"
click node_metadata "https://github.com/screamycat/openplay/tree/main/src-tauri/src/metadata"
click node_database "https://github.com/screamycat/openplay/blob/main/src-tauri/src/db/mod.rs"
click node_launcher "https://github.com/screamycat/openplay/blob/main/src-tauri/src/launcher/mod.rs"
click node_emulator "https://github.com/screamycat/openplay/blob/main/src-tauri/src/emulator/mod.rs"
click node_achievements "https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/providers.rs"
click node_cloud_sync "https://github.com/screamycat/openplay/blob/main/src-tauri/src/cloud_sync/mod.rs"
click node_backups "https://github.com/screamycat/openplay/blob/main/src/components/library/OpenPlayBackupTab.tsx"
click node_themes_ui "https://github.com/screamycat/openplay/blob/main/src/components/ThemesManagerModal.tsx"
click node_theme_engine "https://github.com/screamycat/openplay/blob/main/src/utils/themeEngine.ts"
click node_themes_backend "https://github.com/screamycat/openplay/blob/main/src-tauri/src/themes/mod.rs"
click node_plugins_ui "https://github.com/screamycat/openplay/blob/main/src/components/PluginsManagerModal.tsx"
click node_plugins_backend "https://github.com/screamycat/openplay/blob/main/src-tauri/src/plugins/mod.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_app,node_game_views,node_library_manager,node_achievement_hub toneBlue
class node_backend,node_scanner,node_steam_scanner,node_epic_scanner,node_playnite_scanner,node_local_scanner,node_metadata,node_database toneAmber
class node_launcher,node_emulator toneMint
class node_achievements,node_cloud_sync,node_backups toneRose
class node_themes_ui,node_theme_engine,node_themes_backend,node_plugins_ui,node_plugins_backend,node_player toneIndigo
```

## Components

### Player interface

- [Application shell](https://github.com/screamycat/openplay/blob/main/src/App.tsx): `src/App.tsx`
- [Library views](https://github.com/screamycat/openplay/blob/main/src/components/GameDetails.tsx): `src/components/GameDetails.tsx`
- [Library manager](https://github.com/screamycat/openplay/blob/main/src/components/LibraryManagerModal.tsx): `src/components/LibraryManagerModal.tsx`
- [Achievement hub](https://github.com/screamycat/openplay/blob/main/src/components/AchievementHunterHub.tsx): `src/components/AchievementHunterHub.tsx`

### Library and metadata

- [Tauri commands](https://github.com/screamycat/openplay/blob/main/src-tauri/src/lib.rs): `src-tauri/src/lib.rs`
- [Store scanners](https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/providers.rs): `src-tauri/src/scanner/providers.rs`
- [Steam scanner](https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/steam.rs): `src-tauri/src/scanner/steam.rs`
- [Epic scanner](https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/epic.rs): `src-tauri/src/scanner/epic.rs`
- [Playnite importer](https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/playnite.rs): `src-tauri/src/scanner/playnite.rs`
- [Local scanner](https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/local.rs): `src-tauri/src/scanner/local.rs`
- [Metadata providers](https://github.com/screamycat/openplay/tree/main/src-tauri/src/metadata): `src-tauri/src/metadata`
- [Game database](https://github.com/screamycat/openplay/blob/main/src-tauri/src/db/mod.rs): `src-tauri/src/db/mod.rs`

### Play and emulation

- [Game launcher](https://github.com/screamycat/openplay/blob/main/src-tauri/src/launcher/mod.rs): `src-tauri/src/launcher/mod.rs`
- [Emulator management](https://github.com/screamycat/openplay/blob/main/src-tauri/src/emulator/mod.rs): `src-tauri/src/emulator/mod.rs`

### Progress and portability

- [Achievement data](https://github.com/screamycat/openplay/blob/main/src-tauri/src/scanner/providers.rs): `src-tauri/src/scanner/providers.rs`
- [Cloud sync](https://github.com/screamycat/openplay/blob/main/src-tauri/src/cloud_sync/mod.rs): `src-tauri/src/cloud_sync/mod.rs`
- [Backup tools](https://github.com/screamycat/openplay/blob/main/src/components/library/OpenPlayBackupTab.tsx): `src/components/library/OpenPlayBackupTab.tsx`

### Customization and extensions

- [Theme manager](https://github.com/screamycat/openplay/blob/main/src/components/ThemesManagerModal.tsx): `src/components/ThemesManagerModal.tsx`
- [Theme engine](https://github.com/screamycat/openplay/blob/main/src/utils/themeEngine.ts): `src/utils/themeEngine.ts`
- [Theme services](https://github.com/screamycat/openplay/blob/main/src-tauri/src/themes/mod.rs): `src-tauri/src/themes/mod.rs`
- [Plugin manager](https://github.com/screamycat/openplay/blob/main/src/components/PluginsManagerModal.tsx): `src/components/PluginsManagerModal.tsx`
- [Plugin runtime](https://github.com/screamycat/openplay/blob/main/src-tauri/src/plugins/mod.rs): `src-tauri/src/plugins/mod.rs`

### Other components

- **Player**

## Connections

- Player → Application shell: uses
- Application shell → Library views: renders (evidence: `src/App.tsx`)
- Application shell → Library manager: opens (evidence: `src/App.tsx`)
- Application shell → Achievement hub: opens (evidence: `src/App.tsx`)
- Application shell → Tauri commands: invokes commands (evidence: `src/App.tsx`)
- Library manager → Tauri commands: invokes commands (evidence: `src/components/LibraryManagerModal.tsx`)
- Tauri commands → Store scanners: coordinates scans (evidence: `src-tauri/src/lib.rs`)
- Store scanners → Steam scanner: dispatches to (evidence: `src-tauri/src/scanner/mod.rs`)
- Store scanners → Epic scanner: dispatches to (evidence: `src-tauri/src/scanner/mod.rs`)
- Store scanners → Playnite importer: uses (evidence: `src-tauri/src/scanner/providers.rs`)
- Store scanners → Local scanner: dispatches to (evidence: `src-tauri/src/scanner/mod.rs`)
- Tauri commands → Metadata providers: uses (evidence: `src-tauri/src/lib.rs`)
- Tauri commands → Game database: reads and writes (evidence: `src-tauri/src/lib.rs`)
- Tauri commands → Game launcher: dispatches launches (evidence: `src-tauri/src/lib.rs`)
- Tauri commands → Emulator management: manages emulation (evidence: `src-tauri/src/lib.rs`)
- Achievement hub → Tauri commands: loads progress
- Tauri commands → Achievement data: collects achievement data
- Tauri commands → Cloud sync: supports device sync (evidence: `src-tauri/src/lib.rs`)
- Cloud sync → Game database: reads and writes (evidence: `src-tauri/src/cloud_sync/mod.rs`)
- Library manager → Backup tools: manages backups
- Theme manager → Tauri commands: invokes theme commands (evidence: `src/components/ThemesManagerModal.tsx`)
- Theme manager → Theme engine: applies customization (evidence: `src/components/ThemesManagerModal.tsx`)
- Theme engine → Theme services: loads theme assets
- Theme services → Game database: persists themes (evidence: `src-tauri/src/themes/mod.rs`)
- Plugin manager → Plugin runtime: manages plugins
- Plugin runtime → Game database: uses persistence (evidence: `src-tauri/src/plugins/mod.rs`)
