JER'S MEDIA // ENGINEERING

Every number has a file path

BREACH PROTOCOL's engine is documented in architecture decision records that are immutable once accepted, and a specification written to be executed against: every number in it is a constant with a file path, a measurement with a method, or a target that says so. This page is the short tour — six decisions and what they bought.


// SERVER AUTHORITY

Nothing the client says is trusted

Every byte a client sends is a claim, arriving from a JavaScript runtime the player can open a debugger on. Taken at face value, the client's message set is a complete cheat toolkit: lie about position and you teleport; lie about fire timing and a 90-damage sniper shoots eight rounds a second; claim a shot origin 40 metres from your body and you shoot through walls you were never behind.

So no rule lives in the browser. The server simulates at 30 Hz, snapshots at 30 Hz, and validates every claim against its own state. Bots share the exact same player record as humans — one tick loop, one damage path, one scoring path, and not a single branch on "is this real".

// DETERMINISM

The map is eight bytes

The server sends a seed and no geometry. Both sides run the same generator from the same number and must land on identical collision — 70 boxes at the default seed, measured — or the client would render cover that stops nothing. The shared package that guarantees this has zero dependencies: no DOM, no sockets, no filesystem, imported by both sides and allowed to depend on neither.

Determinism turned out to be the engine's most load-bearing wall. It is what lets the whole game run headless at roughly ninety times real time per core — which is the property that made the bots trainable.

// NETCODE

"My shots don't register" is a measurable quantity

The netcode benchmark spawns a throwaway server, connects two synthetic clients, and has one aim at exactly where it renders a sprinting target. Perfect aim should hit about 100%; anything less is netcode error that a player experiences as shots not registering.

Two controls run in CI, and both matter. A stationary target must always be hit — that catches a broken harness. A deliberately mis-aimed shot must always miss — because if a wrong shot still lands, that is not lag compensation, that is an accidental aimbot.

// BOTS

People-shaped by constraint

The bot programme opened with a rule stated before any design work: bots must never become better shots. Improvements may make them harder to kill and more useful to their team; never more accurate — because accuracy is the dial that makes a bot feel unfair rather than skilled. Across the whole programme, rifle hits-per-kill moved from 6.99 to 7.07. Everything else changed.

Bots gained an awareness cone with notice latency, hearing, a wrist with a finite turn rate, acquisition delay on every fresh contact, cover sampling, reloads taken behind something. Time-to-first-shot in a close contact went from 0.155 seconds to 0.474: flanking now buys you the fight. And the rear-kill share fell when the cone landed — from 15.5% to 13.2% — which is the number that says the change created a flanking window rather than an assassination meta. The bots are now the most behaviour-pinned system in the repository, and the suite around them has since grown past 2,500 green tests.

// REINFORCEMENT LEARNING

Thirty-six hours of self-play, one seat at the table

A learned policy may occupy the bots' goal layer and nothing below it. It picks one of eight macro-goals — an objective, the fight in front of it, health, home — and the hand-built tactical layer, with all its human limits intact, executes. The reward is the win and the constraint is structural: the network cannot reach the trigger, so it cannot learn to pull it better than a person can.

The production policies came out of a 36-hour training campaign run across two machines, gated the way they ship: a seated policy draws no randomness — it takes the argmax, because a live arena's RNG stream is part of the determinism contract — so every champion had to win as a deterministic player, not as a sampler. One champion per side holds the production seats today.

The observation encoder is a frozen contract: a checkpoint whose schema does not match the build refuses to load, so checkpoints die in batches, on purpose, never as a side effect. And the campaign's write-ups keep the dead ends: the recipe that produced a champion on one level collapsed to a zero-percent win rate on another, and the record says so — with the control run that proves it was the level, not the build.

// EVERYTHING IS DATA

Identity is a directory

Every sound has a WebAudio synth voice behind it; generated takes are an overlay, and the failure mode is "the game sounds like it did yesterday", never silence. The text-to-speech pipeline sits behind a server-side proxy — the browser never holds an API key. The storyline is 28 beats of authored data, rebindable live. The boss's fight numbers are server-owned dials that edit the running match. And a complete second identity for the game — theme, strings, cast, voices, rules — is a directory of the game's own files with a label saying which are in the box: one pack installs it, and deleting it restores the default byte-for-byte. That format is the groundwork for Steam Workshop support: validated, floored, data-only packs are what make user content safe to subscribe to.

AVATAR//LAB's FIGHT tab beside a voxel slice editor for THE SYSADMIN's head. An amber banner warns these are server-owned numbers shared by the whole match, above three live sliders — SHADE INTEGRITY 260 hp, LASER DAMAGE 34, CANNON DAMAGE 55 — each annotated with what it costs an operator, such as "16 PACKET RIFLE rounds to blind him".

// THE INTEL BOUNDARY

The wallhack that isn't

The manager role's brief was "see where everyone is" — which, taken literally, is a live feed of sixteen positions to a player on voice with eight teammates: a permanent wallhack mediated by a human relay the game cannot rate-limit. The role had to be worth playing without being that. The fix is placement, not politeness: enemy position traffic is filtered before broadcast and never reaches a manager's socket. A client that was never sent the data has nothing to reveal, no matter how it is modified.

The proof runs in a browser tab

All of the above is live at breach.jers.media. Flank a bot. Take the chair. Count the seconds the smoke telegraphs before it lands.