# beminee/baio architecture

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

- Interactive diagram: https://gitdiagram.com/beminee/baio
- Repository: https://github.com/beminee/baio

## Overview

BAIO is an Ensage hero-script solution: players activate combo or harass behavior, and hero-specific logic issues game actions. The repository also documents BAIO.DynamicCombo as an activator for a customizable generic solution. The graph preserves that capability, but its source is only identified in the tree; its runtime wiring is not shown. Edges reflect excerpts, indexed references, or README statements, so unsampled implementation details are not inferred.

Main entry points: [`BAIO/BAIO/Heroes/Base`](https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Base) (Hero implementations), [`BAIO/BAIO/BaseHero.cs`](https://github.com/beminee/baio/blob/main/BAIO/BAIO/BaseHero.cs) (Hero runtime), [`BAIO/BAIO/Program.cs`](https://github.com/beminee/baio/blob/main/BAIO/BAIO/Program.cs) (BAIO startup), [`BAIO/BAIO/Heroes/Modes/Combo`](https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Modes/Combo) (Combo handlers)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Activation and contracts"]
  node_baio_entry["BAIO startup<br/>[Program.cs]"]
  node_hero_contract["Hero contracts<br/>[IHero.cs]"]
  node_dynamic_activator["Dynamic combo activator<br/>[Program.cs]"]
end

subgraph group_runtime["Shared runtime"]
  node_base_hero["Hero runtime<br/>[BaseHero.cs]"]
  node_config["Configuration menus<br/>[Config.cs]"]
  node_combo_mode["Combo targeting<br/>[ComboMode.cs]"]
  node_harass_mode["Harass targeting<br/>[HarassMode.cs]"]
  node_extensions["Gameplay helpers<br/>[Extensions.cs]"]
end

subgraph group_heroes["Hero behavior"]
  node_hero_classes["Hero implementations"]
  node_combo_handlers["Combo handlers"]
  node_harass_handlers["Harass handlers"]
end

subgraph group_support["Unit control"]
  node_unit_updater["Unit discovery<br/>[Updater.cs]"]
  node_unit_manager["Managed units<br/>[UnitManager.cs]"]
  node_movement["Orbwalker control"]
end

node_player(("Player"))
node_ensage(("Ensage game"))

node_player -->|"activates"| node_baio_entry
node_baio_entry -->|"uses contracts"| node_hero_contract
node_baio_entry -.->|"offers separate solution"| node_dynamic_activator
node_hero_classes -.->|"implements"| node_hero_contract
node_hero_classes -->|"inherits runtime"| node_base_hero
node_base_hero -->|"creates menus"| node_config
node_base_hero -->|"registers mode"| node_combo_mode
node_base_hero -->|"registers mode"| node_harass_mode
node_hero_classes -->|"selects handler"| node_combo_handlers
node_hero_classes -->|"selects handler"| node_harass_handlers
node_combo_handlers -->|"uses targeting"| node_combo_mode
node_harass_handlers -->|"uses targeting"| node_harass_mode
node_hero_classes -->|"uses helpers"| node_extensions
node_unit_updater -->|"tracks units"| node_unit_manager
node_unit_manager -->|"creates movement control"| node_movement
node_ensage -.->|"hosts script"| node_baio_entry
node_hero_classes -.->|"issues gameplay actions"| node_ensage

click node_baio_entry "https://github.com/beminee/baio/blob/main/BAIO/BAIO/Program.cs"
click node_hero_contract "https://github.com/beminee/baio/blob/main/BAIO/BAIO/Interfaces/IHero.cs"
click node_dynamic_activator "https://github.com/beminee/baio/blob/main/BAIO.DynamicCombo/BAIO.DynamicCombo/Program.cs"
click node_base_hero "https://github.com/beminee/baio/blob/main/BAIO/BAIO/BaseHero.cs"
click node_config "https://github.com/beminee/baio/blob/main/BAIO/BAIO/Config.cs"
click node_combo_mode "https://github.com/beminee/baio/blob/main/BAIO/BAIO/Modes/ComboMode.cs"
click node_harass_mode "https://github.com/beminee/baio/blob/main/BAIO/BAIO/Modes/HarassMode.cs"
click node_extensions "https://github.com/beminee/baio/blob/main/BAIO/BAIO/Extensions.cs"
click node_hero_classes "https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Base"
click node_combo_handlers "https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Modes/Combo"
click node_harass_handlers "https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Modes/Harass"
click node_unit_updater "https://github.com/beminee/baio/blob/main/BAIO/BAIO/UnitManager/Updater.cs"
click node_unit_manager "https://github.com/beminee/baio/blob/main/BAIO/BAIO/UnitManager/UnitManager.cs"
click node_movement "https://github.com/beminee/baio/blob/main/BAIO/BAIO/UnitManager/UnitMovementManager.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_baio_entry,node_hero_contract,node_dynamic_activator toneBlue
class node_base_hero,node_config,node_combo_mode,node_harass_mode,node_extensions toneAmber
class node_hero_classes,node_combo_handlers,node_harass_handlers toneMint
class node_unit_updater,node_unit_manager,node_movement toneRose
class node_player,node_ensage toneIndigo
```

## Components

### Activation and contracts

- [BAIO startup](https://github.com/beminee/baio/blob/main/BAIO/BAIO/Program.cs): `BAIO/BAIO/Program.cs`
- [Hero contracts](https://github.com/beminee/baio/blob/main/BAIO/BAIO/Interfaces/IHero.cs): `BAIO/BAIO/Interfaces/IHero.cs`
- [Dynamic combo activator](https://github.com/beminee/baio/blob/main/BAIO.DynamicCombo/BAIO.DynamicCombo/Program.cs): `BAIO.DynamicCombo/BAIO.DynamicCombo/Program.cs`

### Shared runtime

- [Hero runtime](https://github.com/beminee/baio/blob/main/BAIO/BAIO/BaseHero.cs): `BAIO/BAIO/BaseHero.cs`
- [Configuration menus](https://github.com/beminee/baio/blob/main/BAIO/BAIO/Config.cs): `BAIO/BAIO/Config.cs`
- [Combo targeting](https://github.com/beminee/baio/blob/main/BAIO/BAIO/Modes/ComboMode.cs): `BAIO/BAIO/Modes/ComboMode.cs`
- [Harass targeting](https://github.com/beminee/baio/blob/main/BAIO/BAIO/Modes/HarassMode.cs): `BAIO/BAIO/Modes/HarassMode.cs`
- [Gameplay helpers](https://github.com/beminee/baio/blob/main/BAIO/BAIO/Extensions.cs): `BAIO/BAIO/Extensions.cs`

### Hero behavior

- [Hero implementations](https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Base): `BAIO/BAIO/Heroes/Base`
- [Combo handlers](https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Modes/Combo): `BAIO/BAIO/Heroes/Modes/Combo`
- [Harass handlers](https://github.com/beminee/baio/tree/main/BAIO/BAIO/Heroes/Modes/Harass): `BAIO/BAIO/Heroes/Modes/Harass`

### Unit control

- [Unit discovery](https://github.com/beminee/baio/blob/main/BAIO/BAIO/UnitManager/Updater.cs): `BAIO/BAIO/UnitManager/Updater.cs`
- [Managed units](https://github.com/beminee/baio/blob/main/BAIO/BAIO/UnitManager/UnitManager.cs): `BAIO/BAIO/UnitManager/UnitManager.cs`
- [Orbwalker control](https://github.com/beminee/baio/blob/main/BAIO/BAIO/UnitManager/UnitMovementManager.cs): `BAIO/BAIO/UnitManager/UnitMovementManager.cs`

### Other components

- **Player**
- **Ensage game**

## Connections

- Player → BAIO startup: activates
- BAIO startup → Hero contracts: uses contracts (evidence: `BAIO/BAIO/Program.cs`)
- BAIO startup → Dynamic combo activator: offers separate solution
- Hero implementations → Hero contracts: implements
- Hero implementations → Hero runtime: inherits runtime (evidence: `BAIO/BAIO/Heroes/Base/Clockwerk.cs`)
- Hero runtime → Configuration menus: creates menus (evidence: `BAIO/BAIO/BaseHero.cs`)
- Hero runtime → Combo targeting: registers mode (evidence: `BAIO/BAIO/BaseHero.cs`)
- Hero runtime → Harass targeting: registers mode (evidence: `BAIO/BAIO/BaseHero.cs`)
- Hero implementations → Combo handlers: selects handler (evidence: `BAIO/BAIO/Heroes/Base/Clockwerk.cs`)
- Hero implementations → Harass handlers: selects handler (evidence: `BAIO/BAIO/Heroes/Base/StormSpirit.cs`)
- Combo handlers → Combo targeting: uses targeting (evidence: `BAIO/BAIO/Heroes/Modes/Combo/GrimstrokeCombo.cs`)
- Harass handlers → Harass targeting: uses targeting (evidence: `BAIO/BAIO/Heroes/Modes/Harass/HuskarHarass.cs`)
- Hero implementations → Gameplay helpers: uses helpers (evidence: `BAIO/BAIO/Heroes/Base/Clockwerk.cs`)
- Unit discovery → Managed units: tracks units (evidence: `BAIO/BAIO/UnitManager/Updater.cs`)
- Managed units → Orbwalker control: creates movement control (evidence: `BAIO/BAIO/UnitManager/UnitManager.cs`)
- Ensage game → BAIO startup: hosts script
- Hero implementations → Ensage game: issues gameplay actions
