# developeracademy-postech/2026-c6-m10-musa architecture

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

- Interactive diagram: https://gitdiagram.com/developeracademy-postech/2026-c6-m10-musa
- Repository: https://github.com/developeracademy-postech/2026-c6-m10-musa

## Overview

C6 Physics Lab is a Unity project for experimenting with multiplayer connections, orb physics and combination, passing, and throwing. The documented workflow is: a player starts solo or hosts/joins a room; the session synchronizes settings and player state; players generate, combine, pass, and throw orbs; confirmed hits affect the shared battle. The README also documents developer tuning, room discovery/direct-IP joining, and replaceable orb visuals. Runtime source was not excerpted, so internal links below rely on README descriptions rather than inspected call sites.

Main entry points: [`Assets/Lab/Scripts/Session/LabNetwork.cs`](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabNetwork.cs) (Session Network), [`Assets/Lab/Scripts/UI/LabSceneController.cs`](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabSceneController.cs) (Scene Controller), [`Assets/Lab/Scripts/Core/LabModel.cs`](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Core/LabModel.cs) (Game Model), [`Assets/Lab/Scripts/Throw/LabProjectile.cs`](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Throw/LabProjectile.cs) (Projectile)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_experience["Player Experience"]
  node_scene["Lab Scene<br/>[Lab.unity]"]
  node_scene_control["Scene Controller"]
  node_hud["Game HUD<br/>[LabHud.cs]"]
  node_camera["Seat Camera<br/>[LabSeatCamera.cs]"]
end

subgraph group_session["Rooms and Networking"]
  node_network["Session Network<br/>[LabNetwork.cs]"]
  node_discovery["Bonjour Discovery"]
  node_bonjour_native["Bonjour Native"]
  node_address_codec["Address Codec"]
  node_candidates["Connection Candidates"]
  node_transport["Dual Stack Transport"]
  node_endpoint["Transport Endpoint"]
  node_settings["Session Settings"]
end

subgraph group_gameplay["Game Rules and Physics"]
  node_model["Game Model<br/>[LabModel.cs]"]
  node_contracts["Game Contracts<br/>[LabContracts.cs]"]
  node_board["Orb Board<br/>[LabOrbBoard.cs]"]
  node_orb_view["Orb View<br/>[LabOrbView.cs]"]
  node_throw_math["Throw Math<br/>[LabThrowMath.cs]"]
  node_projectile["Projectile<br/>[LabProjectile.cs]"]
  node_target["Battle Target<br/>[LabTarget.cs]"]
end

subgraph group_presentation["Presentation and Tuning"]
  node_config["Lab Config<br/>[LabConfig.cs]"]
  node_config_asset["Config Asset<br/>[LabConfig.asset]"]
  node_developer["Developer Panel"]
  node_appearance["Orb Appearance"]
  node_appearance_asset["Orb Visual Assets"]
end

node_player(("Player"))
node_lan(("LAN Peers"))

node_player -->|"starts session"| node_scene_control
node_scene_control -->|"hosts or joins"| node_network
node_player -->|"finds host"| node_discovery
node_discovery -->|"discovers via"| node_bonjour_native
node_player -->|"joins by IP"| node_network
node_network -.->|"tries candidates"| node_candidates
node_network -->|"connects over"| node_transport
node_transport -.->|"uses endpoints"| node_endpoint
node_network -->|"shares settings"| node_settings
node_network -->|"communicates with"| node_lan
node_network -->|"synchronizes state"| node_model
node_scene_control -->|"starts round"| node_model
node_scene_control -->|"connects controls"| node_hud
node_scene_control -->|"sets seat view"| node_camera
node_player -->|"generates orbs"| node_hud
node_hud -->|"controls board"| node_board
node_board -->|"displays orbs"| node_orb_view
node_orb_view -->|"renders appearance"| node_appearance
node_appearance -->|"uses visual settings"| node_appearance_asset
node_player -->|"combines or passes"| node_board
node_player -->|"throws combined orb"| node_projectile
node_projectile -.->|"calculates trajectory"| node_throw_math
node_projectile -->|"checks hit"| node_target
node_target -->|"applies confirmed damage"| node_model
node_player -->|"adjusts parameters"| node_developer
node_developer -->|"edits session values"| node_config
node_config_asset -->|"provides defaults"| node_config
node_config -->|"configures gameplay"| node_model
node_scene -->|"stores scene references"| node_scene_control

click node_scene "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scenes/Lab.unity"
click node_scene_control "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabSceneController.cs"
click node_hud "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabHud.cs"
click node_camera "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabSeatCamera.cs"
click node_model "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Core/LabModel.cs"
click node_contracts "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Core/LabContracts.cs"
click node_config "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Core/LabConfig.cs"
click node_config_asset "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Resources/LabConfig.asset"
click node_developer "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabDeveloperMode.cs"
click node_network "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabNetwork.cs"
click node_discovery "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabBonjourDiscovery.cs"
click node_bonjour_native "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabBonjourNative.cs"
click node_address_codec "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabBonjourAddressCodec.cs"
click node_candidates "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabConnectionCandidates.cs"
click node_transport "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabDualStackTransport.cs"
click node_endpoint "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabTransportEndpoint.cs"
click node_settings "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabSessionSettings.cs"
click node_board "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Orb/LabOrbBoard.cs"
click node_orb_view "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Orb/LabOrbView.cs"
click node_appearance "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Orb/LabOrbAppearance.cs"
click node_appearance_asset "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Art/Orbs/LabOrbAppearance.asset"
click node_throw_math "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Throw/LabThrowMath.cs"
click node_projectile "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Throw/LabProjectile.cs"
click node_target "https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Throw/LabTarget.cs"

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_scene,node_scene_control,node_hud,node_camera toneBlue
class node_network,node_discovery,node_bonjour_native,node_address_codec,node_candidates,node_transport,node_endpoint,node_settings toneAmber
class node_model,node_contracts,node_board,node_orb_view,node_throw_math,node_projectile,node_target toneMint
class node_config,node_config_asset,node_developer,node_appearance,node_appearance_asset toneRose
class node_player,node_lan toneIndigo
```

## Components

### Player Experience

- [Lab Scene](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scenes/Lab.unity): `Assets/Lab/Scenes/Lab.unity`
- [Scene Controller](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabSceneController.cs): `Assets/Lab/Scripts/UI/LabSceneController.cs`
- [Game HUD](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabHud.cs): `Assets/Lab/Scripts/UI/LabHud.cs`
- [Seat Camera](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabSeatCamera.cs): `Assets/Lab/Scripts/UI/LabSeatCamera.cs`

### Rooms and Networking

- [Session Network](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabNetwork.cs): `Assets/Lab/Scripts/Session/LabNetwork.cs`
- [Bonjour Discovery](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabBonjourDiscovery.cs): `Assets/Lab/Scripts/Session/LabBonjourDiscovery.cs`
- [Bonjour Native](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabBonjourNative.cs): `Assets/Lab/Scripts/Session/LabBonjourNative.cs`
- [Address Codec](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabBonjourAddressCodec.cs): `Assets/Lab/Scripts/Session/LabBonjourAddressCodec.cs`
- [Connection Candidates](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabConnectionCandidates.cs): `Assets/Lab/Scripts/Session/LabConnectionCandidates.cs`
- [Dual Stack Transport](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabDualStackTransport.cs): `Assets/Lab/Scripts/Session/LabDualStackTransport.cs`
- [Transport Endpoint](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabTransportEndpoint.cs): `Assets/Lab/Scripts/Session/LabTransportEndpoint.cs`
- [Session Settings](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Session/LabSessionSettings.cs): `Assets/Lab/Scripts/Session/LabSessionSettings.cs`

### Game Rules and Physics

- [Game Model](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Core/LabModel.cs): `Assets/Lab/Scripts/Core/LabModel.cs`
- [Game Contracts](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Core/LabContracts.cs): `Assets/Lab/Scripts/Core/LabContracts.cs`
- [Orb Board](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Orb/LabOrbBoard.cs): `Assets/Lab/Scripts/Orb/LabOrbBoard.cs`
- [Orb View](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Orb/LabOrbView.cs): `Assets/Lab/Scripts/Orb/LabOrbView.cs`
- [Throw Math](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Throw/LabThrowMath.cs): `Assets/Lab/Scripts/Throw/LabThrowMath.cs`
- [Projectile](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Throw/LabProjectile.cs): `Assets/Lab/Scripts/Throw/LabProjectile.cs`
- [Battle Target](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Throw/LabTarget.cs): `Assets/Lab/Scripts/Throw/LabTarget.cs`

### Presentation and Tuning

- [Lab Config](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Core/LabConfig.cs): `Assets/Lab/Scripts/Core/LabConfig.cs`
- [Config Asset](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Resources/LabConfig.asset): `Assets/Lab/Resources/LabConfig.asset`
- [Developer Panel](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/UI/LabDeveloperMode.cs): `Assets/Lab/Scripts/UI/LabDeveloperMode.cs`
- [Orb Appearance](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Scripts/Orb/LabOrbAppearance.cs): `Assets/Lab/Scripts/Orb/LabOrbAppearance.cs`
- [Orb Visual Assets](https://github.com/developeracademy-postech/2026-c6-m10-musa/blob/main/Assets/Lab/Art/Orbs/LabOrbAppearance.asset): `Assets/Lab/Art/Orbs/LabOrbAppearance.asset`

### Other components

- **Player**
- **LAN Peers**

## Connections

- Player → Scene Controller: starts session (evidence: `README.md`)
- Scene Controller → Session Network: hosts or joins (evidence: `README.md`)
- Player → Bonjour Discovery: finds host (evidence: `README.md`)
- Bonjour Discovery → Bonjour Native: discovers via (evidence: `README.md`)
- Player → Session Network: joins by IP (evidence: `README.md`)
- Session Network → Connection Candidates: tries candidates
- Session Network → Dual Stack Transport: connects over (evidence: `README.md`)
- Dual Stack Transport → Transport Endpoint: uses endpoints
- Session Network → Session Settings: shares settings (evidence: `README.md`)
- Session Network → LAN Peers: communicates with (evidence: `README.md`)
- Session Network → Game Model: synchronizes state (evidence: `README.md`)
- Scene Controller → Game Model: starts round (evidence: `README.md`)
- Scene Controller → Game HUD: connects controls (evidence: `README.md`)
- Scene Controller → Seat Camera: sets seat view (evidence: `README.md`)
- Player → Game HUD: generates orbs (evidence: `README.md`)
- Game HUD → Orb Board: controls board (evidence: `README.md`)
- Orb Board → Orb View: displays orbs (evidence: `README.md`)
- Orb View → Orb Appearance: renders appearance (evidence: `README.md`)
- Orb Appearance → Orb Visual Assets: uses visual settings (evidence: `README.md`)
- Player → Orb Board: combines or passes (evidence: `README.md`)
- Player → Projectile: throws combined orb (evidence: `README.md`)
- Projectile → Throw Math: calculates trajectory
- Projectile → Battle Target: checks hit (evidence: `README.md`)
- Battle Target → Game Model: applies confirmed damage (evidence: `README.md`)
- Player → Developer Panel: adjusts parameters (evidence: `README.md`)
- Developer Panel → Lab Config: edits session values (evidence: `README.md`)
- Config Asset → Lab Config: provides defaults (evidence: `README.md`)
- Lab Config → Game Model: configures gameplay (evidence: `README.md`)
- Lab Scene → Scene Controller: stores scene references (evidence: `README.md`)
