VB-110: Worn paths speed walking, and routes prefer them
Status: done (2026-10-30)
Priority: 3
Size: M
Design ref: Land and ecology (Worn paths: faster walking, sharing paths; Decided, 30 Oct). Kim, 30 Oct 2026 (merging main): paths are drawn first (VB-094), the speed-up comes in this follow-up.
Goal: VB-094 counts crossings and draws trodden ground, paths and lanes, but walking ignores them. The design wants paths to speed walking, so routes merge onto them and the merged path wears deeper.
Acceptance criteria:
Walking is 5% faster on trodden ground, 15% on a path and 30% on a lane than on the bare terrain, multiplying the terrain speed of VB-096.
The route search counts the faster walking in its step costs, so a pawn takes a path when it is quicker even if it is longer. Cached routes are dropped when a tile changes stage, at most once a game day for each tile.
A test: two farms with a lane between them that bends around a meadow; a pawn takes the lane when it is quicker than the straight way, and the straight way when it is not.
Founders at seed 7 after 20 years and populous medium at seed 7 after 5: tiles per stage and mean walk time to fields, well and woodlot, against VB-094’s numbers (reported); the cost of route search per game day, before and after.
Re-record the golden file and list the changed entries in the PR.
Notes / questions:
Depends on VB-094 (worn paths) and VB-096 (terrain costs in the route search); mark it ready when both are done.
Whether animals wear paths too is Open in the design; this task counts pawns only, as VB-094 does.
Kim, 30 Oct 2026: taken up with VB-094 and VB-096 in one change; routes over paths may also serve route reuse if route search costs too much (VB-097).
Done 2026-10-30, with VB-094 and VB-096. tileCost divides by PATHS.speed[w.worn[i]] (1, 1.05, 1.15, 1.3), so the route search and the walk agree; ROUTE.minStep is 1/1.3, the cheapest step, which keeps the A* bound admissible. fadeWear calls costChanged for each tile that changes stage, and refreshRoutes drops at the end of the day only the cached routes that tile could change (steps from start to tile plus tile to end, times the cheapest step, within the route’s cost); a stage is set once a game day, so a tile drops routes at most once a day.
The test is in tests/routes.js: a lane one row off the straight way between two farms (12 steps at a lane’s cost against 10 of meadow) is taken; one four rows off (18 steps) is not.
Populous medium seed 7 over 5 years (worn in): trodden/path/lane 173/32/1, against 172/26/0 grown from clean ground. Mean walks (populous seed 7, one year, with VB-113’s layout): fields 1.01 h, firewood 1.58 h, water 0.52 h. Route search does not show in the profile: tests/perf.js gives 84 to 93 ms a game day, against 88 before the speed-up.
Golden: every founders and heirs entry from year 1.