# openomsi-org/openomsi architecture

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

- Interactive diagram: https://gitdiagram.com/openomsi-org/openomsi
- Repository: https://github.com/openomsi-org/openomsi

## Overview

openOMSI is a Rust recreation of OMSI 2 that runs on an existing OMSI 2 installation and its maps, vehicles, and mods. The main workflow is to locate that installation, select a map, bus, and duty in the launcher, then start and drive a simulation. The runtime also covers rendering, audio, controls, multiplayer, plugins, and dedicated-server operation. Connections below rely on README statements and the shown app excerpts; unsampled subsystem internals are represented by their existing source paths rather than inferred call chains.

Main entry points: [`crates/omsi-app/src/app.rs`](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/app.rs) (Game app), [`crates/omsi-app/src/launcher/pages.rs`](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/launcher/pages.rs) (Launcher), [`crates/omsi-map/src/tile.rs`](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-map/src/tile.rs) (Map and world), [`crates/omsi-app/src/lan.rs`](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/lan.rs) (LAN play)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_launch["Setup and launch"]
  node_launcher["Launcher<br/>[pages.rs]"]
  node_install["Install discovery<br/>[install_search.rs]"]
  node_settings["Settings<br/>[settings.rs]"]
  node_mods["Mods<br/>[mods.rs]"]
end

subgraph group_world["Simulation world"]
  node_map["Map and world<br/>[tile.rs]"]
  node_scenery["Scenery assets<br/>[sco.rs]"]
  node_vehicle["Vehicles<br/>[vehicle.rs]"]
  node_content["Content formats<br/>[lib.rs]"]
  node_duty["Timetable and duty<br/>[lib.rs]"]
end

subgraph group_runtime["Driving runtime"]
  node_game["Game app<br/>[app.rs]"]
  node_simulation["Simulation engine<br/>[lib.rs]"]
  node_render["Renderer<br/>[lib.rs]"]
  node_audio["Audio<br/>[mixer.rs]"]
  node_controllers["Input devices<br/>[controllers.rs]"]
end

subgraph group_extensions["Connectivity and extensions"]
  node_lan["LAN play<br/>[lan.rs]"]
  node_network["Network transport<br/>[lib.rs]"]
  node_server["Dedicated server<br/>[server.rs]"]
  node_plugins["Plugin runtime<br/>[lib.rs]"]
  node_updater["Self updater<br/>[updater.rs]"]
end

node_player(("Player"))

node_player -->|"starts"| node_launcher
node_launcher -->|"locates install"| node_install
node_player -->|"selects map, bus, duty"| node_launcher
node_launcher -->|"installs mods"| node_mods
node_launcher -->|"configures"| node_settings
node_launcher -->|"starts duty"| node_game
node_game -->|"loads world"| node_map
node_game -.->|"runs game"| node_simulation
node_game -.->|"renders frames"| node_render
node_game -.->|"plays sound"| node_audio
node_game -.->|"reads controls"| node_controllers
node_game -->|"hosts or joins"| node_lan
node_lan -->|"uses transport"| node_network
node_player -->|"runs headless"| node_server
node_game -.->|"loads plugins"| node_plugins
node_launcher -->|"checks releases"| node_updater
node_map -.->|"uses assets"| node_scenery
node_game -->|"drives selected bus"| node_vehicle
node_game -->|"starts selected duty"| node_duty
node_content -.->|"loads formats"| node_map

click node_launcher "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/launcher/pages.rs"
click node_install "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-cfg/src/install_search.rs"
click node_settings "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/settings.rs"
click node_mods "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-launcher-core/src/mods.rs"
click node_game "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/app.rs"
click node_map "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-map/src/tile.rs"
click node_scenery "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-scenery/src/sco.rs"
click node_vehicle "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-vehicle/src/vehicle.rs"
click node_content "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-content/src/lib.rs"
click node_duty "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-timetable/src/lib.rs"
click node_simulation "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-sim/src/lib.rs"
click node_render "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-render/src/lib.rs"
click node_audio "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-audio/src/mixer.rs"
click node_controllers "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/controllers.rs"
click node_lan "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/lan.rs"
click node_network "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-net/src/lib.rs"
click node_server "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/server.rs"
click node_plugins "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-plugin/src/lib.rs"
click node_updater "https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/updater.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,node_install,node_settings,node_mods toneBlue
class node_map,node_scenery,node_vehicle,node_content,node_duty toneAmber
class node_game,node_simulation,node_render,node_audio,node_controllers toneMint
class node_lan,node_network,node_server,node_plugins,node_updater toneRose
class node_player toneIndigo
```

## Components

### Setup and launch

- [Launcher](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/launcher/pages.rs): `crates/omsi-app/src/launcher/pages.rs`
- [Install discovery](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-cfg/src/install_search.rs): `crates/omsi-cfg/src/install_search.rs`
- [Settings](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/settings.rs): `crates/omsi-app/src/settings.rs`
- [Mods](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-launcher-core/src/mods.rs): `crates/omsi-launcher-core/src/mods.rs`

### Simulation world

- [Map and world](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-map/src/tile.rs): `crates/omsi-map/src/tile.rs`
- [Scenery assets](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-scenery/src/sco.rs): `crates/omsi-scenery/src/sco.rs`
- [Vehicles](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-vehicle/src/vehicle.rs): `crates/omsi-vehicle/src/vehicle.rs`
- [Content formats](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-content/src/lib.rs): `crates/omsi-content/src/lib.rs`
- [Timetable and duty](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-timetable/src/lib.rs): `crates/omsi-timetable/src/lib.rs`

### Driving runtime

- [Game app](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/app.rs): `crates/omsi-app/src/app.rs`
- [Simulation engine](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-sim/src/lib.rs): `crates/omsi-sim/src/lib.rs`
- [Renderer](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-render/src/lib.rs): `crates/omsi-render/src/lib.rs`
- [Audio](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-audio/src/mixer.rs): `crates/omsi-audio/src/mixer.rs`
- [Input devices](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/controllers.rs): `crates/omsi-app/src/controllers.rs`

### Connectivity and extensions

- [LAN play](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/lan.rs): `crates/omsi-app/src/lan.rs`
- [Network transport](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-net/src/lib.rs): `crates/omsi-net/src/lib.rs`
- [Dedicated server](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/server.rs): `crates/omsi-app/src/server.rs`
- [Plugin runtime](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-plugin/src/lib.rs): `crates/omsi-plugin/src/lib.rs`
- [Self updater](https://github.com/openomsi-org/openomsi/blob/main/crates/omsi-app/src/updater.rs): `crates/omsi-app/src/updater.rs`

### Other components

- **Player**

## Connections

- Player → Launcher: starts (evidence: `README.md`)
- Launcher → Install discovery: locates install (evidence: `README.md`)
- Player → Launcher: selects map, bus, duty (evidence: `README.md`)
- Launcher → Mods: installs mods (evidence: `README.md`)
- Launcher → Settings: configures (evidence: `README.md`)
- Launcher → Game app: starts duty (evidence: `README.md`)
- Game app → Map and world: loads world (evidence: `crates/omsi-app/src/app.rs`)
- Game app → Simulation engine: runs game
- Game app → Renderer: renders frames
- Game app → Audio: plays sound
- Game app → Input devices: reads controls
- Game app → LAN play: hosts or joins (evidence: `README.md`)
- LAN play → Network transport: uses transport (evidence: `crates/omsi-app/src/lan.rs`)
- Player → Dedicated server: runs headless (evidence: `README.md`)
- Game app → Plugin runtime: loads plugins
- Launcher → Self updater: checks releases (evidence: `README.md`)
- Map and world → Scenery assets: uses assets
- Game app → Vehicles: drives selected bus (evidence: `README.md`)
- Game app → Timetable and duty: starts selected duty (evidence: `README.md`)
- Content formats → Map and world: loads formats
