Spaces:
Paused
Paused
Commit History
-
Remove the Refinery/Foundry/Arsenal forward drop-off capabilityβ
Claude +1: Claude Sonnet 5Unverified signatureThey no longer double as decentralized resource collection points β the Command Center is the only drop-off. Removes the now-dead finite-intake buffer branches in gather/haul, the AI's forward-Refinery placement logic, and updates HUD/docs/tests accordingly. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HW46d81A9V6VumZWqw7XZU4ed9122
-
Make an explicit home-base assignment a hard zone boundaryβ
Claude +1: Claude Sonnet 5Unverified signatureA player-assigned home base (unit.homeCC) fell back to a global search just like the default nearest-CC guess whenever its zone came up empty -- meaning a hauler pinned to one Command Center could still get poached into another base's territory, defeating the point of assigning it in the first place. zoneFirst now tracks whether its home zone came from a valid override or the default distance guess, and only widens to the whole empire in the latter case. A unit pinned to a Command Center now cycles through whatever other jobs that zone has to offer and simply waits when it has none, until the player reassigns it to a different CC or clears the override -- while a building-level manual assignment (service/repair/ ferry) keeps behaving as the single, hard-locked target it already was. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SYFtYzV8C6Scdpz5dMJpoWee2f17b -
Add player-assigned home base override and worker repair of wounded unitsβ
Claude +1: Claude Sonnet 5Unverified signatureCloses the two items flagged as future work in the previous zone-affinity commit: a home-base override, and repairing mobile units. engine/gather.js zoneFirst now takes an optional homeId that, when it resolves to a live owned Command Center, wins over the usual nearest-CC distance guess. Right-clicking a completed own CC with eligible units selected (worker, Mender, freighter) pins unit.homeCC to it (issueSetHomeBase) β a passive assignment that only changes the unit's next idle job search, never its current order. A stale override (its CC destroyed) is ignored and falls back to the distance guess. Threaded through every zone-first call site in haul.js and repair.js's pickRepairTarget, so it covers haul/service/ferry job search and both the worker repair job and the Mender's own autoRepairRoam. assignRepair no longer restricts itself to buildings: a worker can now be assigned to chase down and patch a wounded mobile unit the same way it patches a turret, walking toward the target's β¦06de929 -
Add Command Center zone affinity for haulers, plus a worker repair jobβ
Claude +1: Claude Sonnet 5Unverified signatureHaulers/servers/ferriers used to pick jobs by raw nearest-distance across the whole empire, with no notion of "which base do I belong to." Once a busy base's own β€2-per-target caps filled up, idle labour got routinely poached across the map by another base's job. engine/gather.js zoneFirst now restricts each search to the worker's own Command Center zone first, only widening to the whole empire when the home zone has nothing to offer (byte-identical to before on any single-CC game). The auto-repair Mender's roam target-pick adopts the same zone-first logic via a shared pickRepairTarget helper (engine/repair.js). Buildings could previously only be healed passively by a Mender in range. Workers can now be assigned a repair job (auto, zone-first, after ferry/haul/service in priority; or manual via right-click, issueRepairBuilding), patching a damaged own building at a flat rate, capped per building like the existing haul/service caps. Both changes are pure functions of state and reused β¦32d2559
-
Let workers load/unload freighters and add an AI-logistics freighter modeβ
Claude +1: Claude Sonnet 5Unverified signatureWorkers can now physically ferry cargo to and from a landed freighter (right-click it, like assigning a worker to service a building) β the freighter becomes a mobile collection point for nearby production instead of every load detouring through the Command Center. Also adds a new Datacenter research, Autonomous Freight AI, that lets a freighter join the local haul/service logistics chain on its own, like a worker but at its own much larger cargo capacity. Running autonomously burns AI Cores from the treasury while active; out of AI Cores it just pauses in place instead of losing its job or cargo. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AdsYZQyGk32n8x3UBiPGup6f39bc5
-
Logistics Phase C: finite forward drop-offs + gather reroute (player-only)β
Claude +1: Claude Opus 4.8Unverified signatureThe last piece: collection buildings get finite storage too. A PLAYER's forward drop-offs (Refinery/Foundry/Arsenal) now have a finite intake buffer (storeCap 100). A gatherer banks its haul into that buffer; when it's full, nearestGatherDrop skips it so the gatherer reroutes to the next collection point β and the Command Center, the bottomless treasury/warehouse, never fills. Phase A haulage clears a forward buffer to the CC automatically. Goods now flow strictly through the warehouse: gather β forward drop-off buffer β haul β CC treasury β supply β factory β haul β CC. Haulage delivers and supply picks up at the nearest Command Center (nearestCommandCenter), never sideways between drop-offs. Factories are excluded from gather drop-offs (isGatherDropOff): their `store` is refined output, not a raw-intake bin. - entities.js: storeCap on refinery/foundry/arsenal; isGatherDropOff helper. - gather.js: player forward-drop-off banks to the building's buffer (capped, leftover reroutes); β¦89beffa -
Logistics Phase B: factory input larders + a real supply networkβ
Claude +1: Claude Opus 4.8Unverified signatureFactories stop sipping from an infinite global pool: each now draws its inputs from a FINITE local larder (building.input) and banks output into a finite buffer (building.store), both capped at 80 by default for any building with a recipe (storeCapOf/inputCapOf). updateProduction runs a factory only while it's been supplied AND has output room β it stalls starved or backed-up, exactly like the Plasma Rig. Worker haulage gains a supply leg (engine/haul.js): an idle player worker picks the nearest own factory low on an input the treasury can provide, carries a cargo from the Command Center into its larder. Output is cleared by the Phase A haul path, which now covers factories automatically. Idle workers try haul first (clear backlogs, refill the treasury) then supply (feed the starving). Both capped at 2 per building, deterministic nearest-by-id, player-only. The industry chain is now a genuine network routed through the treasury: raws β CC β supply β smelter β metals β haul β CC β supβ¦832f494 -
Logistics Phase A: finite rig output buffer + worker haulageβ
Claude +1: Claude Opus 4.8Unverified signatureStorage stops being an infinite sink and workers get a job that lasts to the end of the game. The Plasma Rig (a leaf producer of raw goods β the safest surface to prove the mechanic, since its output feeds no other factory) now banks each dig into a FINITE local buffer (building.store, capped at def.storeCap 120) and stalls the moment it's full. Those goods aren't spendable until hauled to a Command Center. New worker haulage (engine/haul.js): an idle PLAYER worker auto-assigns to the nearest own producer whose buffer is β₯34% full (β€2 haulers per producer, ties broken by id), walks there, loads a cargo, carries it to the nearest drop-off, and banks it into the treasury 1:1 β no gather multiplier, since the rig already extracted it. Run short on haulers and the buffer fills and the rig stalls: logistics is now a live demand on labour, exactly as intended. - entities.js: storeCapOf / storeTotal / storeRoom helpers; storeCap on the rig def. - rig.js: bank to store (top off the final digβ¦91ad84b -
Docs: logistics overhaul brainstorm + phased finite-storage/haulage designβ
Claude +1: Claude Opus 4.8Unverified signatureCaptures the plan of record for the finite-storage + worker-haulage half of the logistics request. Records the energy grid-efficiency feature that shipped, then lays out why per-building storage is a core-economy reshape (one global player.resources pool feeds gather/industry/rig/market/costs/wonder/AI/HUD), the forgotten aspects the brainstorm surfaced (AI deadlock, what counts as spendable, determinism, save coercion, auto-haulage, balance), and a three-phase plan β A: production output buffers + auto-haulage (player-only, safe first slice); B: factory input buffers + a real supply network; C: finite collection storage (touches the AI, highest risk) β each its own determinism-verified merge. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AEQUVetLk31Jj7niDQAsXL6dbb379