VB-1584: Wells are dug: a household’s at its house and a village’s on its green, their hours by the depth; village.well becomes a tile
Status: done (2026-11-24)
Priority: 2
Size: M
Design ref: design.md, Goods and the farming year (Water by the site); backlog/VB-1543.md
Goal: a household far from water can buy its time back by digging, and a village’s well costs what its ground asks
Acceptance criteria:
A well’s hours and stone are by the depth of its tile (design.md, Goods and the farming year, Water by the site, Wells): WELL.flat 16 + WELL.perMetre 4 a metre, a load of stone and one more for every 2 m; one rule, read by the household’s well and the village’s. The plan shows the band’s range of hours until water is struck, never the metres ahead.
A household’s well: a project at the house (long work, as a cart’s building), on the house’s tile, begun by the head when the fetching it saves in WELL.payYears (2 years) is more than its hours at the band’s middle, with no project under way and the stone on its heap; the played head may begin it when it likes, through a verb that says why not (no well in this ground, one already, a project under way).
The village’s well: sim/green’s well step takes its hours and stone from the depth of the green’s tile in place of BUILD.wellHours and BUILD.wellStone, the green’s tile is chosen where the water is shallowest among those it may take, and a green whose ground has no well is laid out without one.
village.well becomes the well’s tile (none where there is none); every reader moves (the page’s sweep and curb, the village card, the portraits, sim/paths, sim/layout, sim/byhand); a save with the boolean loads. A finished well sets w.fresh to well on its tile and the farms it changes find their source again.
Checks on a small constructed state: a well in 2 m of ground takes 24 hours and 2 loads, in 10 m 56 hours and 6; a household inland digs and its fetch falls to 0.1 hours a trip; a household beside a river does not dig; no well is begun on ground with none.
Measured once, before and after (small, seeds 7 and 42; founders and populous; 15 years): wells dug by households and by villages, their hours by band, hours a household-day on water, dry household-days; whether households are better off. (Measured over 10 years, not 15, as the run’s orchestrator asked on the shared machine: the numbers are below.)
Cost, named before building: one project a household or a village at most; the head’s test of whether a well pays on its planning day, a comparison of numbers the farm’s source already holds (250 households x a seventh a day x no search).
Noted by VB-1543, 23 November 2026.
Built, 24 November 2026 (VB-1584). world/water: wellHours, wellStone (1 + a load every 2 m begun), bandStone; new module sim/wells (the making well, kind housewell, pays, stoneLacking, the head’s test on planReviewed); sim/green (the step’s hours and stone by the depth, the green by the band, a green alone where the ground has no well); village.well a tile or null, wellsLoaded for a save’s boolean; tests/wells.js.
Decided: heaps hold almost no stone that no work asked for (populous 7: 52 of 52 heaps empty at the start, 56 of 75 under 2 loads at year 3), so a head whose well pays gathers the lining’s stone through its building step, as the foundation’s (sim/building reads stoneLacking); with “the stone on its heap” alone almost no well would be dug. Close call, noted.
Decided: the depth is not known before the digging, so the stone set aside is the band’s most (3, 6, 11 loads) and the lining takes its depth’s when water is struck; the plan’s row shows the band and its range of hours. The green is chosen by band, then nearness to the houses’ middle: the villagers’ estimate, and the green stays between the farms. Both noted.
Decided: the well is marked small (its own row, given up alone) but is refused while a large project of the household’s is under way, as the criterion says; and the head’s rule makes its land first (no well while fields are fewer than wanted, or animals are kept with no meadow): without it founders 42’s second farm lost its first meadow to the digging (tests/meadows.js). And it begins the digging in the slack of the year (early summer, winter), as a house is raised: a well begun in the hay harvest starved a byre (tests/byre.js, founders 7). The played head is bound by neither.
Decided: a village that starts with its green keeps its well whatever its ground (the design’s At the start). Tried the other way (no starting well on ground with none, 2 of 17 centres on populous 7): 194 household-days with no source, the mean fetch 0.88 -> 1.44 h, hungry days 578 -> 786; reverted. The tile card then says “no well” under a standing well: noted.
Measured, small, 10 years, the run’s branch with VB-1596 -> this branch on it. Populous 7: wells dug by households 0 -> 38 (shallow 12, middling 14, deep 12; 20 to 85 h), by villages 0 -> 0; dry household-days 1985/34608 (5.74%) -> 2582/35867 (7.20%); hours a household-day on water (the farm’s fetch) 0.84 -> 0.58; the fetch at the end q1/median/q3/max 0.47/0.75/1.10/7.16 -> 0.10/0.38/0.65/5.09 h; over half their days dry 5 -> 11; marsh days 11 -> 203; deaths 119 -> 122, hungry days 445 -> 466. Populous 42: 0 -> 28 (18, 10, 0; 20 to 56 h), villages 0 -> 0; dry 2621/36148 (7.25%) -> 1408/36291 (3.88%); 0.88 -> 0.64 h; 0.40/0.63/0.95/8.56 -> 0.10/0.39/0.70/7.33; over half dry 7 -> 2; marsh days 1237 -> 1175; deaths 86 -> 80, hungry days 402 -> 354. Founders 7: 3 wells (30 to 44 h), the village’s 0 -> 1 (23 h); dry 1 -> 0; 0.58 -> 0.24 h. Founders 42: 3 wells (20 to 26 h), the village’s 1 -> 1 (30 h); dry 0 -> 0; 0.50 -> 0.26 h.
Households: better off in time (the middle farm’s fetch halves, a quarter of the farms fetch at the door, the mean falls by a quarter to a third), not reliably in dry days: down by half on seed 42, up on seed 7, and across this task’s four builds of the rule the same seed gave 6.3 to 7.2% (seed 7) and 3.8 to 6.0% (seed 42) against 5.7 to 7.0% and 6.7 to 7.3% before, so the walk is not what makes most dry days (VB-626’s ranking, VB-1585’s thirst). Left far at the end of populous 42 in an earlier build (13 farms over 1.5 h or at marsh): 6 on ground with no well, 3 in deep ground with no stone to pick or quarry in reach (11 loads), 2 with a project under way, 1 in a booth; a marsh’s poor water is not in the head’s test (hours alone). Left as tuning notes.
Found: tests/browser-saves.js went red on this branch’s run (not at 4b10409): a swap offered to the played pawn came due after the fair, when the loads are unpacked, and sim/fair’s weigh read a null load. Guarded in the basis (declined); the lapsing at the fair’s end is VB-1598. tests/browser-editor.js is red before and after (VB-1495). Counters: 0 out; sourceSettled 0.039 -> 0.043 a pawn-day.