# elitevortex/eddie-dragon-isles architecture

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

- Interactive diagram: https://gitdiagram.com/elitevortex/eddie-dragon-isles
- Repository: https://github.com/elitevortex/eddie-dragon-isles

## Overview

Dragon Isles is an interactive portfolio presented as a third-person dragon-flight game. The visitor flies among five story islands and lands to open a chapter; keyboard, touch, or camera gestures provide controls. The game also offers combat, changing weather and seasons, synthesized and recorded audio, and shared multiplayer. Multiplayer uses a browser WebSocket client with either a local Node relay or a Cloudflare Durable Object relay. The sampled excerpts show the game-to-hand-tracking and game-to-network/audio links; other connections are included only where the README documents them.

Main entry points: [`dragon/isles.js`](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js) (Flight World), [`dragon/net.js`](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/net.js) (WebSocket Client), [`data.js`](https://github.com/elitevortex/eddie-dragon-isles/blob/main/data.js) (Chapter Data), [`server/relay.mjs`](https://github.com/elitevortex/eddie-dragon-isles/blob/main/server/relay.mjs) (Local Relay)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_game["Flight Game"]
  node_game_world["Flight World<br/>[isles.js]"]
  node_islands["Story Islands<br/>[isles.js]"]
  node_flight["Dragon Flight<br/>[isles.js]"]
  node_combat["Fireball Combat<br/>[isles.js]"]
  node_weather["Weather and Seasons<br/>[isles.js]"]
end

subgraph group_story["Portfolio Content"]
  node_chapters["Chapter Data<br/>[data.js]"]
  node_media["Photos and Reels"]
end

subgraph group_input["Controls and Audio"]
  node_hand_tracking["Hand Tracking<br/>[hands.js]"]
  node_audio["Music and Effects<br/>[sound.js]"]
end

subgraph group_multiplayer["Multiplayer"]
  node_net_client["WebSocket Client<br/>[net.js]"]
  node_local_relay["Local Relay<br/>[relay.mjs]"]
  node_cloud_relay["Cloud Relay<br/>[index.js]"]
  node_shared_room[("Shared Room")]
end

node_visitor(("Visitor"))

node_visitor -->|"flies through"| node_game_world
node_game_world -->|"supports flight"| node_flight
node_game_world -->|"visits islands"| node_islands
node_islands -->|"builds from"| node_chapters
node_chapters -->|"references media"| node_media
node_visitor -->|"shows gestures"| node_hand_tracking
node_game_world -->|"initializes tracking"| node_hand_tracking
node_game_world -->|"supports fireballs"| node_combat
node_game_world -->|"varies conditions"| node_weather
node_game_world -->|"uses audio"| node_audio
node_game_world -->|"uses multiplayer"| node_net_client
node_net_client -->|"connects locally"| node_local_relay
node_net_client -->|"connects in production"| node_cloud_relay
node_local_relay -->|"forwards messages"| node_shared_room
node_cloud_relay -->|"forwards messages"| node_shared_room

click node_game_world "https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js"
click node_islands "https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js"
click node_flight "https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js"
click node_combat "https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js"
click node_weather "https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js"
click node_chapters "https://github.com/elitevortex/eddie-dragon-isles/blob/main/data.js"
click node_media "https://github.com/elitevortex/eddie-dragon-isles/tree/main/assets"
click node_hand_tracking "https://github.com/elitevortex/eddie-dragon-isles/blob/main/ar/hands.js"
click node_audio "https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/sound.js"
click node_net_client "https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/net.js"
click node_local_relay "https://github.com/elitevortex/eddie-dragon-isles/blob/main/server/relay.mjs"
click node_cloud_relay "https://github.com/elitevortex/eddie-dragon-isles/blob/main/worker/src/index.js"

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_game_world,node_islands,node_flight,node_combat,node_weather toneBlue
class node_chapters,node_media toneAmber
class node_hand_tracking,node_audio toneMint
class node_net_client,node_local_relay,node_cloud_relay,node_shared_room toneRose
class node_visitor toneIndigo
```

## Components

### Flight Game

- [Flight World](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js): `dragon/isles.js`
- [Story Islands](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js): `dragon/isles.js`
- [Dragon Flight](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js): `dragon/isles.js`
- [Fireball Combat](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js): `dragon/isles.js`
- [Weather and Seasons](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/isles.js): `dragon/isles.js`

### Portfolio Content

- [Chapter Data](https://github.com/elitevortex/eddie-dragon-isles/blob/main/data.js): `data.js`
- [Photos and Reels](https://github.com/elitevortex/eddie-dragon-isles/tree/main/assets): `assets`

### Controls and Audio

- [Hand Tracking](https://github.com/elitevortex/eddie-dragon-isles/blob/main/ar/hands.js): `ar/hands.js`
- [Music and Effects](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/sound.js): `dragon/sound.js`

### Multiplayer

- [WebSocket Client](https://github.com/elitevortex/eddie-dragon-isles/blob/main/dragon/net.js): `dragon/net.js`
- [Local Relay](https://github.com/elitevortex/eddie-dragon-isles/blob/main/server/relay.mjs): `server/relay.mjs`
- [Cloud Relay](https://github.com/elitevortex/eddie-dragon-isles/blob/main/worker/src/index.js): `worker/src/index.js`
- **Shared Room**

### Other components

- **Visitor**

## Connections

- Visitor → Flight World: flies through (evidence: `README.md`)
- Flight World → Dragon Flight: supports flight (evidence: `README.md`)
- Flight World → Story Islands: visits islands (evidence: `README.md`)
- Story Islands → Chapter Data: builds from (evidence: `README.md`)
- Chapter Data → Photos and Reels: references media (evidence: `data.js`)
- Visitor → Hand Tracking: shows gestures (evidence: `README.md`)
- Flight World → Hand Tracking: initializes tracking (evidence: `dragon/isles.js`)
- Flight World → Fireball Combat: supports fireballs (evidence: `README.md`)
- Flight World → Weather and Seasons: varies conditions (evidence: `README.md`)
- Flight World → Music and Effects: uses audio (evidence: `dragon/isles.js`)
- Flight World → WebSocket Client: uses multiplayer (evidence: `dragon/isles.js`)
- WebSocket Client → Local Relay: connects locally (evidence: `README.md`)
- WebSocket Client → Cloud Relay: connects in production (evidence: `README.md`)
- Local Relay → Shared Room: forwards messages (evidence: `server/relay.mjs`)
- Cloud Relay → Shared Room: forwards messages (evidence: `worker/src/index.js`)
