Commit Graph

8 Commits

Author SHA1 Message Date
dejvino
06c7555188 Phase 5: four real jobs, radio, and work found in the field
Mission types. Four of them, differing in pacing and risk rather than in the
noun on the board: a quick supply drop, a retrieval whose danger is all on the
return leg, a long stationary intel transmission in the open, and a cheap survey
whose payoff is the map. Retrieval carries cargo that impacts damage, and pays
for what arrives rather than what you set off with, which makes the drive home a
different problem from the drive out.

Radio. Chatter framing the player as an undercover driver being talked at by
people busy elsewhere. Every line is triggered by something actually happening
in the sim — crossing a border, a road you personally made notorious, a car past
saving, or the front genuinely drifting. The enemy-has-other-priorities line
fires off measured drift, so the brief's ambient-drift-is-the-mechanism idea is
said out loud without ever showing a number. Topics carry cooldowns and never
repeat a sentence back to back; a test caught that they could.

Field work. Past the line, with nothing in hand, a wounded stranger or a contact
or a strippable wreck occasionally turns up. Deliberately not on a board: no
route preview, no comparison, no shopping between them. Take the detour in front
of you or drive on. They never appear behind your own lines, where a safe errand
would defeat the point.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 13:35:37 +02:00
dejvino
90dc18fd17 Braking, stutter, a real road hierarchy, denser towns, and autosave
Braking. Rapier brake impulses were far too small next to a 1100kg chassis, so
the car would not come to a standstill. Raised, plus a coast brake so lifting
off actually slows you and a hold below walking pace so "stop the car" for a
mission is not a fight. First attempt overshot to 1.9g, which reads as hitting a
wall; tuned to about 0.8g, ~25m from 70km/h, and pinned with tests that assert
both an upper and a lower bound on stopping distance.

Stutter. The render drew the raw latest physics transform, so frames that
consumed two steps or none landed as visible jitter at speed. Now interpolated
between the last two steps by the leftover accumulator. Buildings moved into one
instanced draw call and the minimap dropped to 10Hz, both of which were wasted
work in a frame budget that also has to fit a shadow pass.

Roads. Three classes: single-track lanes, two-lane roads, four-lane trunks that
cross the whole map and are never thinned away. Class drives width, the route
corridor, barricade span, map line weight, surface colour, and two things that
matter more: routing is now by travel time so journeys prefer trunks, and
attention scales with class, so a farm track is slow and unwatched while a trunk
is fast and the first place anyone looks.

Towns. Buildings were small and sparse enough to drive around freely. They are
now laid out on a jittered lattice — rejection sampling cannot pack boxes and
saturated at a third of the target — which takes bypass lanes around a barricade
from 0% obstructed to about two thirds. World scaled to 400m half-extent, 81
junctions, 107 roads.

Autosave. Every 20 seconds, plus an immediate checkpoint on taking and
completing a job. Saves carry the subsystem ceilings, what the player knew
including the parts that are now wrong, and where the war had got to. A save is
validated against seed, format version and array lengths before anything is
applied: half-restoring a campaign is worse than starting a fresh one.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 13:28:15 +02:00
dejvino
f5742de595 Phase 4: a front line that moves, and stops the map from telling you
The objective beacon now goes out once the cargo is dropped or the survey is
done. The target is no longer somewhere the player needs to be, and the bases'
own beacons take over for the trip home.

The front moves from two independent sources. Mission completions push it
forward, weighted by what the job was worth, and that contribution decays over
about seven minutes so ground won is not held for free. On top of that the line
drifts on its own in both directions, which the brief is explicit about: ambient
drift is what makes this a war rather than a level, and it is the only mechanism
for the enemy's attention being pulled elsewhere.

Drift is a sum of slow waves, not a random walk. A first attempt at a damped
walk moved 3m in four minutes, because white noise scaled by dt averages itself
out. Waves at incommensurate periods are unpredictable in practice, bounded by
construction, and reproducible from the seed, so a test can assert that a region
changed hands while the player was away. Most of the movement is shared across
boundaries, since a front advances as a whole; independent per-band waves were
squeezing bands into the ordering clamp.

Crucially the map no longer reads live state. Intel now records who held each
cell when the player last stood in it, and the minimap draws that, with the
border inferred from where remembered control changes rather than from the
front's true position. Otherwise the map would quietly hand the player a live
readout of a line that is supposed to move behind their back. Stale roads are
drawn faded, so untrustworthy notes look untrustworthy.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 11:42:34 +02:00
dejvino
477195a7d6 Phase 3: regional control, sketch minimap, and fix the base hut
Three things, all tangled together enough to land at once.

Regions. A single directional front cuts the map into liberated, contested,
occupied and frontier. Heat accrual behind your own lines is exactly zero, not
merely small — a trickle would eventually fortify your own back garden, and
would mean the safe area quietly punished you for using it. Decay is judged by
whoever holds the road, not whoever holds the ground the car is standing on.
Modelled as one front rather than blobs of territory because the brief wants the
line to move in both directions, and Phase 4 can then just slide the offsets.

Territory is signalled by tone, never by the world announcing itself: crossing a
border eases the fog, light and palette between four looks. Phase 3's gate is
telling occupied from liberated without being told, so the HUD line naming the
band is debug scaffolding like the heat numbers.

Minimap. There was no way to tell where a target was. The map is drawn from
Intel, not from the world: the road network's shape is always faintly visible,
but only roads actually seen carry remembered heat, only ground actually driven
through is filled in, and the front line is dashed in only where both sides of
it have been explored. Adds a coarse fog-of-war grid to Intel, plus an
eight-point compass arrow in the HUD.

Base huts. The building was centred on the junction, so the starting hut sat
directly over the car and hid it. Huts now stand off the junction, in whichever
direction is furthest from tarmac, and are solid.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 10:23:23 +02:00
dejvino
73e8ac68f1 Phase 2: bases, quest board, and known-vs-new targets
Four allied bases, placed by greedy farthest-point so no choke point can strand
the player, with the first at the spawn junction so the loop is available at
once. Missions hand in at any base, not the issuing one.

The board offers known and new targets side by side and describes each route in
words. Crucially it never reads heat directly — it reads sim/intel.ts, a record
of what the player has actually observed and when. Notes age while roads keep
escalating unwatched, so a known route is knowable, stale, and never a promise.
Recon missions survey everything within 130m, which is how a new target becomes
a known one without driving every road there.

New targets pay 1.8x. That multiplier is the phase's tuning dial: too low and
nobody takes the unknown, too high and nobody takes the known.

Payment is parts, which repair the car. To keep "decline, not reset" intact,
each subsystem gains a ceiling that falls permanently with damage — repairs
restore up to what the car is still capable of, never to what it was. Without an
economy the board's rewards had no stakes; with one, the risky job is what keeps
the car running a while longer.

Adds Dijkstra over the road graph, taking a cost function so a "safest route"
preview is a small change later.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 10:06:32 +02:00
dejvino
475db8773c Heat: credit the verge to the road, and block the whole corridor
Driving alongside a road accrued no heat at all, so the dominant strategy was
to never actually use one. Heat is now credited to any road within 12m of the
centreline, tarmac or verge.

The cutoff is hard rather than tapered: a taper leaves a gradient to optimise
along, where sitting at 80% of the catchment costs 20% of the heat. A cliff
edge means you either use the route or genuinely leave it.

12m is a balance, not a guess. It puts ~7.5m of verge past the kerb — two car
widths, so hugging the shoulder gains nothing — while leaving 57% of the map
off-route. At 20m two thirds of the map counts as on-route, heat becomes
unavoidable everywhere, and choosing a different route stops meaning anything.

Barricades now span the full corridor for the same reason. Stopping at the kerb
left them free to round on the verge at speed.

Junction heat is still deferred; a point near a junction is credited to the
nearest segment.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 09:41:52 +02:00
dejvino
506d07be5d Phase 1: road network and heat
Roads are a jittered 7x7 grid with ~a quarter of the edges thinned out, kept
connected. The loops are the point: "take a different road" is not a decision
without alternative routes.

Every metre driven adds heat to that segment; all roads shed it slowly. Crossing
a threshold escalates Clear -> Patrol -> Barricade -> Turret, each of which puts
real obstructions on the tarmac. Hysteresis stops a road on a boundary from
rebuilding its barricade every few seconds.

Level changes are deferred while the car is on the segment. Building a barricade
around the player would spawn a static collider inside the chassis, and the
player is meant to discover escalation by returning to a road, not by watching
it assemble behind them.

Checkpoint positions are seeded from the segment id, so a stretch of road always
fortifies in the same place — recognising it is part of learning the map.

Scenery now avoids the tarmac and the car spawns at a junction.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 07:47:19 +02:00
dejvino
a66032674d Phase 0: drivable car with persistent wear
Vite + TypeScript + three.js + Rapier raycast vehicle, fixed 60 Hz step.

Flat plate, seeded obstacle scatter, chase camera, debug HUD. Car condition
(engine/tires/chassis) degrades permanently and is derived into handling
numbers, so decline is felt through the wheel rather than read off a meter.

src/sim/ is kept free of three.js and Rapier imports — the later heat, region
and front-line systems all live there, and staying engine-free is what makes
them unit-testable without a browser.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 07:39:05 +02:00