MEGABOTS

Megabots — Combat Flow

Order of operations for a single battle. Calculations are listed with their inputs only —

concrete formulas live in combat-formulas.md

(see notes.md for stat/move definitions).

Participants

Zone Model

The battlefield is a shared distance track with one marker: CQ ↔ Mid ↔ Long

— the relative distance between the two bots. Battle starts at Mid.

move two zones in one turn (a two-step option is offered only when two full

steps of track remain — chasers can close Long→CQ in one turn).

from Mid means: first mover shifts Mid→Long, then the second mover's retreat is

already at the edge and clamps.

but the attack still fires from the current zone. Direction riders

("+X if retreating") trigger only if the zone actually changed.

out; at CQ, advance options are.

second mover's attack now fires from a zone its mobility gate disallows, the

attack still resolves but off-balance: −15 hit and ×0.85 damage [tunable].

(Full NOT-POSSIBLE enforcement was A/B'd: it inverts the meta into kiter

monoculture; zero enforcement lets mobility-1 melee ignore the gates entirely —

the audit measured 43–47% of tank damage as gate-illegal.)

judges award the win to the bot with the higher HP fraction (exact tie = draw).

Draw-forcing stall was a measured exploit (85–90% forced draws in waterlog

mirrors); now a stall must also win the HP race.

Wheel Composition

Arms and legs each put 2 moves on the wheel. A head puts 1 — it carries

two and you load one of them before the fight. So a full build shows 5.

Any part slot may be left empty (2 fewer wheel moves, weight saved). Cobra

builds are forcibly armless — a cobra head requires a lizard chassis + cobra

legs — and so that frame is not left short, a cobra head loads both of its

moves. A cobra still shows 4.

Top-Level Turn Loop

 PIL-A           BOT-A             ENGINE              BOT-B           PIL-B
   |               |                  |                   |               |
═══╪═══════════════╪═══════ TURN START ═══════════════════╪═══════════════╪═══
   |               |                  |                   |               |
   |               |   read state     |    read state     |               |
   |               |<-----------------|------------------>|               |
   |               |  (charges, mobility, parts,          |               |
   |               |   active effects, zone)              |               |
   |               |                  |                   |               |
   |               |          [C1] MOVE AVAILABILITY      |               |
   |               |          (computed per pilot)        |               |
   |               |                  |                   |               |
   |   move wheel UI (6 moves,        |     move wheel UI (6 moves,      |
   |   each enabled/disabled)         |     each enabled/disabled)       |
   |<---------------------------------|--------------------------------->|
   |               |                  |                   |              |
   |  select: move OR inspect,        |     select: move OR inspect,     |
   |  + advance / retreat / hold      |     + advance / retreat / hold   |
   |--------------------------------->|<---------------------------------|
   |               |                  |                   |               |
   |               |        [C2] PRIORITY CALC            |               |
   |               |        (computed ONCE per turn;      |               |
   |               |         tie -> random roll)          |               |
   |               |                  |                   |               |
   |               |   ┌──────────────┴────────────────┐  |               |
   |               |   │ RESOLVE MOVE: first mover     │  |               |
   |               |   │ (see MOVE RESOLUTION below)   │  |               |
   |               |   └──────────────┬────────────────┘  |               |
   |               |                  |                   |               |
   |               |   ── KO CHECK: defender at 0 HP? ──  |               |
   |               |      YES -> COMBAT ENDS IMMEDIATELY  |               |
   |               |      (second mover never acts)       |               |
   |               |                  |                   |               |
   |               |   revalidate second mover's move     |               |
   |               |   (validity recomputed, priority     |               |
   |               |    is NOT recomputed)                |               |
   |               |                  |                   |               |
   |               |   ┌──────────────┴────────────────┐  |               |
   |               |   │ RESOLVE MOVE: second mover    │  |               |
   |               |   │ (see MOVE RESOLUTION below)   │  |               |
   |               |   └──────────────┬────────────────┘  |               |
   |               |                  |                   |               |
   |               |   ── KO CHECK: defender at 0 HP? ──  |               |
   |               |      YES -> COMBAT ENDS IMMEDIATELY  |               |
   |               |                  |                   |               |
═══╪═══════════════╪═══════ TURN END — loop to TURN START ╪═══════════════╪═══

Notes on selection:

below half health (then it is free and the pilot still selects a move).

Inspect gives a full rundown of all the enemy's part stats. Double inspect is

not possible — once inspected, the option is no longer available.

Struggle fallback is always available: 10 atk, no elemental type, no CC,

costs 0 charges.

(the core runs hot when force-cycled), and recovers 3 charges. A

plant-stacked bot cannot vent — vines clog the vents — and **neither can a held

bot (no venting in a clinch); a vent voided mid-turn simply fizzles. Ice

cores vent at no HP cost** — cold cores run cool. Venting breaks the synergy

chain.

Charge Headbutt cannot be used in retreat) and per track edge (no retreat

at Long, no advance at CQ).

Move Resolution (per bot, runs once for each mover)

 ATTACKER                       ENGINE                        DEFENDER
    |                              |                              |
    |        [C3] PREMOVE CALC     |                              |
    |<-----------------------------|----------------------------->|
    |   (reads both bots' state)   |                              |
    |                              |                              |
    |   result: HIT | DEFLECTED | MISS | NOT POSSIBLE             |
    |   (DEFLECTED = full resolution, but damage, elemental CC    |
    |    chance, and active-effect chances are halved AFTER       |
    |    each is calculated)                                      |
    |                              |                              |
────┼── NOT POSSIBLE ──────────────┼──────────────────────────────┼────
    |   nothing happens: no zone change, no charge cost.          |
    |   Resolution ends.           |                              |
    |                              |                              |
────┼── MISS ──────────────────────┼──────────────────────────────┼────
    |   zone change still applied ([C4] ordering)                 |
    |   skip damage / CC / effects, go directly to [C8] charges   |
    |                              |                              |
────┼── HIT / DEFLECTED ───────────┼──────────────────────────────┼────
    |                              |                              |
    |   (a) PRE-ATTACK ZONE CHANGE, if [C4] says move-then-attack |
    |------------------------------>                              |
    |                              |                              |
    |   (b) [C5] DAMAGE CALC       |                              |
    |       (DEFLECTED: halve result after calculation)           |
    |                              |------- apply damage -------->|
    |                              |                              |
    |       >> KO CHECK: 0 HP? -> COMBAT ENDS IMMEDIATELY <<      |
    |                              |                              |
    |   (c) [C6] ELEMENTAL CC CHANCE                              |
    |       (DEFLECTED: halve chance after calculation)           |
    |                              |---- roll; apply CC if ------>|
    |                              |     roll succeeds            |
    |                              |                              |
    |   (d) [C7] ACTIVE EFFECT TRIGGER CHANCES                    |
    |       (DEFLECTED: halve chances after calculation)          |
    |       one chance per candidate effect;                      |
    |       roll every non-zero chance;                           |
    |       if multiple succeed -> apply ONLY the                 |
    |       highest-chance one                                    |
    |                              |---- apply winning effect --->|
    |                              |                              |
    |   (e) POST-ATTACK ZONE CHANGE, if [C4] says attack-then-move|
    |------------------------------>                              |
    |                              |                              |
────┼── ALL PATHS except NOT POSSIBLE ────────────────────────────┼────
    |                              |                              |
    |   (f) [C8] CHARGE COST CALC  |                              |
    |<----- deduct charges --------|                              |
    |       (full cost on HIT, DEFLECTED, and MISS)               |
    |                              |                              |

[C4] Zone Change Ordering (direction × move type)

DirectionMove typesOrder
Advancinggrapple, cut, strike, beam, breath, ensnare, hexmove zone → attack
Retreatingcut, strikeattack → move zone
Retreatingbeam, breath, ensnare, hexmove zone → attack
Retreatinggrapplenot allowed
Holdany (beam explicitly may attack without a zone change)attack only

Ensnare is only usable from mid or long range — since it attacks after moving, an

advance that lands in CQ is invalid (so it can only advance from long range).

Hex moves (pure CC) run the same resolution but **skip step (b) — no damage is

dealt and no KO check occurs**; they proceed straight to elemental CC (c) and active

effects (d). Their zone-change riders (extra debuff, or a one-turn self-buff) apply

during (c)/(d) based on the direction chosen.

Calculations (inputs only — formulas TBD)

[C1] Move Availability (per move, at selection time)

(e.g. water CC lowering mobility, "held" blocking zone change)

[C2] Priority (once per turn, after both selections)

[C3] Premove (immediately before each bot's move resolves)

Produces one of: HIT / DEFLECTED (half damage) / MISS / NOT POSSIBLE

CQ breath debuff, mobility gates per zone)

→ NOT POSSIBLE)

[C5] Damage

[C6] Elemental CC Chance

core element

[C7] Active Effect Trigger Chance (one per candidate effect)

[C8] Charge Cost

grapple ends)

Standing Rules

move; a KO'd bot's pending move never resolves.

mover acts (via its [C3] premove).

until the battle ends, a move undoes them, or a move ticks them down.

CC applied?). A move whose synergy trigger matches the bot's previous landed move

gets its combo payoff (evaluated in [C5], [C6], or [C7] depending on payoff class);

misses, NOT POSSIBLE, inspect, and Struggle break the chain.

chance ([C6]), and each active-effect trigger chance ([C7]) are halved after

they are calculated.