Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion BACKLOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ The order tasks are taken in, the first first (`node tools/backlog.js next`). So
| [VB-1908](backlog/VB-1908.md)<a id="VB-1908"></a> | The build panel as a yard: every building a tile of an icon, a ring and a number | - | 2 | M | The new interface's build panel shows the farmstead as a yard (the house with its size and parts, the yard's buildings, those away, the village's), icons first, from docs/mocks/building-yard.html; page only. |
| [VB-1910](backlog/VB-1910.md)<a id="VB-1910"></a> | What lies out degrades: a share a game day in the wet and after the frost, not all at the frost | - | 2 | M | Sheaves and hay lying out lose a share of their amount each game day (a small one on a wet day, a larger one once the frost has come) in place of rotting whole at the frost; no condition on any item. |
| [VB-1925](backlog/VB-1925.md)<a id="VB-1925"></a> | The generator lays exactly one salt spring a map, picked by the seed | - | 2 | S | The generator draws a salt spring per island by chance (0.1), so a map may have none or several; Kim, 27 Nov: exactly one in the whole archipelago, which is the only salt until a town brings an import. |
| [VB-1926](backlog/VB-1926.md)<a id="VB-1926"></a> | The head's call is urgent or not: bring the load in, or drop everything | plans | 2 | M | Two calls home (Kim, 27 Nov): non-urgent, the default, brings the load in and arrives within about an hour; urgent drops the load and comes now. The head's call today is one kind, instant, and sets a load down only when the caller says so. |
| [VB-1931](backlog/VB-1931.md)<a id="VB-1931"></a> | Cut firewood wherever timber lies | - | 2 | M | A cut-firewood task may be planned at any tile holding timber that is the household's or nobody's, not only at the house |
| [VB-1932](backlog/VB-1932.md)<a id="VB-1932"></a> | Fell and Cut firewood are always available; the head plans the winter's wood | - | 2 | M | Fell and Cut are never withheld because of a store's goal: Fell on any tile the household may fell, Cut whenever unreserved timber is home; the winter's wood is the head's planning |
| [VB-1933](backlog/VB-1933.md)<a id="VB-1933"></a> | Refactor: a test declares its tier in its header; tests/run.js discovers it | - | 2 | M | tests/suites.js 28 tasks to 1 (VB-1406 step 1) |
Expand Down Expand Up @@ -166,6 +165,7 @@ The order tasks are taken in, the first first (`node tools/backlog.js next`). So
| [VB-1923](backlog/VB-1923.md)<a id="VB-1923"></a> | Q10: read displaced hours where windows bind | - | 3 | S | Q10 read where windows bind |
| [VB-1929](backlog/VB-1929.md)<a id="VB-1929"></a> | Plan: a rich farmer's wooden church, the first large work | ship | 3 | M | Decided 27 Nov (Kim): a rich farmer raises a wooden church beside his own farm, with levy days on his neighbours; it needs a design pass for its stages, its owner, its levy and what the village gains. |
| [VB-1930](backlog/VB-1930.md)<a id="VB-1930"></a> | Plan: land bartered and sold, with the kin's right | debt | 3 | M | Decided 25 Nov (Kim): land is bartered and sold, and dear by mechanism; the offer, the holder's reasons, the kin's right, a public act and payment are Proposed and need a design pass before any task builds them. |
| [VB-1958](backlog/VB-1958.md)<a id="VB-1958"></a> | The unplayed head weighs an urgent call when a deadline would be missed | plans | 3 | S | The deadline call is always non-urgent; the head should weigh the urgent kind when the load first would miss the deadline (VB-1926 review F6) |

</details>

Expand Down
1 change: 1 addition & 0 deletions BACKLOG_ARCHIVE.md
Original file line number Diff line number Diff line change
Expand Up @@ -895,3 +895,4 @@ Done tasks and closed archs, moved out of `BACKLOG.md` so its tables list only o
| [VB-1485](backlog/VB-1485.md) | Repair: a cow led home books goodwill with a dead holder (populous small seed 3) | - | 1 | S | relations throws 'goodwill: cannot add 20 between 6 and 76' from exchange ledHome (a deal's cow led home) when a holder of either household is no longer alive |
| [VB-1495](backlog/VB-1495.md) | Repair: tests/browser-editor places no empty farm near the village | - | 1 | S | tests/browser-editor.js fails five checks, from 'no empty farm could be placed near the village' on; seen on main at 5e69f31, before VB-1491. |
| [VB-459](backlog/VB-459.md) | The harvest home: a yearly feast at the farm of a household with plenty | - | 2 | S | A new occasion kind: once a year a household above the feast's threshold asks kin and its holder's strongest ties, up to 20, to its farm when the grain is in. |
| [VB-1926](backlog/VB-1926.md) | The head's call is urgent or not: bring the load in, or drop everything | plans | 2 | M | Two calls home (Kim, 27 Nov): non-urgent, the default, brings the load in and arrives within about an hour; urgent drops the load and comes now. The head's call today is one kind, instant, and sets a load down only when the caller says so. |
1 change: 1 addition & 0 deletions backlog/VB-1807.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ Acceptance criteria:
- [ ] From VB-1906: design.md section 7, The levy and own hours (The labour budget): a daily routine's hours left (the meal, water, milking, fodder: sim/kinds daily) are the head's estimate of each day's job over the season's days after today, and fall due evenly day by day across the game weeks (sim/levies shortOf), not all at the step's last week
- [ ] From VB-1767: design.md section 9, Outer levies (an estate's levy comes on top): a due laid on a village is split at once into household lots by fields (largest remainder), each its own days record beside the routine lots; design.md does not say whether the village bears one record its alderman apportions or the households each bear a lot
- [ ] From VB-1769: design.md, The terms, the ladder and the breach (What the levier's agent does): forgive both strikes the goodwill and books it as a gift
- [ ] From VB-1926: Plans at four scales, A load in hand: a non-urgent call aims to be at the called task within MATCH.day.within = 1 game hour of the call (agent.calledTo.by), shown on the reason line; nothing lapses if later

A line a finding, added by `node tools/backlog.js collect design` (tools/lib/collect.js): findings of a kind are collected, not given a task each.

Expand Down
19 changes: 14 additions & 5 deletions backlog/VB-1926.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# VB-1926: The head's call is urgent or not: bring the load in, or drop everything
Status: ready
Status: done (2026-11-27)
Priority: 2
Size: M
Arch: plans
Expand All @@ -8,7 +8,16 @@ Design ref: design.md, Plans at four scales (The head calls; The cut and the cal
Touches: sim/day (call); sim/jobs (allot, slotIn); sim/reasons; page/play; tests/call.js
Goal: A head's call to a member is non-urgent by default (the member brings its load in, arrives within about an hour) or urgent (drops the load, comes now), and the panel names which and its cost before the call.
Acceptance criteria:
- [ ] A call carries `urgent` (default false). A non-urgent call to a member with a load in hand lets it finish its leg and bring the load to its body's store, and the member plans to be at the called task within about a game hour of the call (a target the plan aims at; nothing lapses if it is later); an urgent call sets the load down as a pile at once (the stray pile's rules) and sends the member now.
- [ ] The deadline call (a meal due today) is non-urgent unless its head or the rule marks it urgent; a head's call beyond the member's levy is still a demand (design.md, The levy and own hours) whichever kind it is.
- [ ] The play panel and the call's cost line name the kind and its cost before the call (the wait, or the load left and the walk home), as an icon and label with the sentence one tap in (design.md, section 15, Icon and label first).
- [ ] Tests on a constructed state: a member carrying a load is called non-urgent and the load reaches the store before it arrives; called urgent, the pile lies where it stood and it arrives sooner; `tests/call.js` and `tests/reasons.js` pass.
- [x] A call carries `urgent` (default false). A non-urgent call to a member with a load in hand lets it finish its leg and bring the load to its body's store, and the member plans to be at the called task within about a game hour of the call (a target the plan aims at; nothing lapses if it is later); an urgent call sets the load down as a pile at once (the stray pile's rules) and sends the member now.
- [x] The deadline call (a meal due today) is non-urgent unless its head or the rule marks it urgent; a head's call beyond the member's levy is still a demand (design.md, The levy and own hours) whichever kind it is.
- [x] The play panel and the call's cost line name the kind and its cost before the call (the wait, or the load left and the walk home), as an icon and label with the sentence one tap in (design.md, section 15, Icon and label first).
- [x] Tests on a constructed state: a member carrying a load is called non-urgent and the load reaches the store before it arrives; called urgent, the pile lies where it stood and it arrives sooner; `tests/call.js` and `tests/reasons.js` pass.
Touches (as built): sim/agents (work, onward, release, answer); sim/day (call, the verb call); sim/timetable (callCost); sim/reasons (reasonOf); sim/roles (MATCH.day.within); page/day (callHTML, callKinds, dayEntry, dayClick).
Notes:
- The kind rides on the work command (args.call, args.urgent), so sim/agents alone writes the new agent.calledTo {key, by}; the load in hand goes on by the rule, and once it is down the hand lets its task go and takes the called one (answer), within the working day only.
- Urgent is the old path: release sets the load down as a titled pile; a called task of the load's own kind picks that pile up again first (the stray pile's rule), which is the design's.
- The deadline call is never urgent (no rule marks it; the played head marks it by the verb). A loaded hand used to be skipped by it until the next allotment; it is now called after its load.
- Past the levy the verb is a demand either kind: the demand's yes re-issues the verb with its args, urgent included.
- The play panel names the kind by the pawn's reason line ("brings its load in first, then plow, by about 10:30"); the Plan tab gives each entry a Call… with both kinds as icon, label and hours, the sentence in a fold.

- Review (revise): F1 mended (a call home clears a call waiting for the load); F3, F5 mended; F2, F4, F6 (VB-1958), F7 declined.
14 changes: 14 additions & 0 deletions backlog/VB-1958.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# VB-1958: The unplayed head weighs an urgent call when a deadline would be missed
Status: ready
Priority: 3
Size: S
Arch: plans
Phase: implement
Design ref: design.md, Plans at four scales (A load in hand); Principles for decisions (Every act is a pawn's)
Touches: sim/day (call); tests/methods.js
Goal: An unplayed head calls urgently when bringing the load in first would miss a deadline today
Acceptance criteria:
- [ ] The unplayed head weighs the urgent kind of its call (sim/day call): where bringing the load in first (callCost come.calm) would make a task due today late against its deadline, and the load set down costs less than the lateness by the head's estimate, the deadline call is urgent.
- [ ] A test on a constructed state: a meal due within the hour, its hand far off with a load in hand, is called urgent; with time to spare, non-urgent.

Noted by VB-1926, 27 November 2026.
104 changes: 71 additions & 33 deletions src/page/day.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
// progress so far is exact), and, for the played pawn that is the head, the head's verbs on the day (Sim.head: dayOrder, assign,
// call), a call named with its cost before it is made (Sim.callCost)
// ======== the day ========
// The page's own state: the member whose call is asked and waits for its confirmation (calling, a pawn id, or null), and the member
// The page's own state: the call asked that waits for its confirmation (calling, {member, key: the task called to, or null for home}, or
// null), and the member
// chosen in each Give list (daySel: "member:key" to a pawn id), kept across the tab's redraws.
let calling = null;
const daySel = new Map();
Expand Down Expand Up @@ -41,7 +42,15 @@ function dayEntry(T, r, k, list, mine) {
'↑',
`Take ${e.label.toLowerCase()} earlier in the day`,
up >= 0,
)}${planBtn({ plan: 'dayOrder', member: r.id, from, to: down }, '↓', `Leave ${e.label.toLowerCase()} till later`, down >= 0)}` +
)}${planBtn({ plan: 'dayOrder', member: r.id, from, to: down }, '↓', `Leave ${e.label.toLowerCase()} till later`, down >= 0)}${
// the head's call to this task now (VB-1926): its kinds and their costs are named first (callHTML)
planBtn(
{ plan: 'callAsk', member: r.id, key: e.key },
'Call…',
`Call ${Sim.fullName(st.pawns[r.id])} to ${e.label.toLowerCase()} now: see what it costs first`,
!now && !e.side,
)
}` +
(others.length
? `<select class="day-to" data-sel="${esc(sk)}" aria-label="${esc(`Whom to give ${e.label.toLowerCase()} to`)}">${others
.map(
Expand All @@ -58,39 +67,67 @@ function dayEntry(T, r, k, list, mine) {
}
const title = e.unseen && e.unseen.length ? ` title="${esc(`Not reckoned with: ${e.unseen.join(', ')}`)}"` : '',
what = `<b>${esc(e.label)}</b> <span class="day-hours">${esc(bits.join(' · '))}</span>`;
return `<li class="day-entry${now ? ' now' : ''}"${title}><span class="day-what">${what}</span>${ctl}</li>`;
return `<li class="day-entry${now ? ' now' : ''}"${title}><span class="day-what">${what}</span>${ctl}${mine ? callHTML(r.id, e.key) : ''}</li>`;
}
// The call of member id: a button that asks, then its cost and the confirmation (the call is made on the second press).
function callHTML(id) {
if (calling !== id) {
const ask = `Call ${Sim.fullName(st.pawns[id])} home: see what it costs first`;
// The two kinds of call (VB-1926; design.md section 15, Icon and label first): an icon and its label with the hours it costs, the
// sentence one tap in. Not urgent: the load in hand is brought in first (the wait); urgent: the load is left where it stands, a pile,
// and the walk out and back to fetch it is the cost.
function callKinds(c, name, what) {
const calm = c.come ? c.come.calm : c.bring,
now = c.come ? c.come.now : c.walk,
load = Math.round(c.load * 10) / 10;
const kind = (icon, label, n, sentence) =>
`<details class="day-kind"><summary>${actIcon(icon)} <b>${esc(label)}</b> <span class="day-hours">${esc(n)}</span></summary>` +
`<p class="card-note">${esc(sentence)}</p></details>`;
if (!(c.load > 0))
return kind(
'walk',
'Now',
dayHours(now),
`${name} carries nothing: it ${what} at once, in about ${dayHours(now)}.`,
);
return (
kind(
'wait',
'Load first',
dayHours(calm),
`${name} brings the ${load} it carries to the store first, and ${what} in about ${dayHours(calm)}, aiming within the hour.`,
) +
kind(
'walk',
'At once',
`${dayHours(now)}, load left`,
`${name} sets the ${load} it carries down where it stands and ${what} in about ${dayHours(now)};` +
` fetching it is ${dayHours(c.fetch)} out and back.`,
)
);
}
// The call of member id (to task `key`, or home when null): a button that asks, then its kinds with their costs and the confirmation
// (the call is made on the second press).
function callHTML(id, key = null) {
const name = Sim.fullName(st.pawns[id]);
if (!calling || calling.member !== id || calling.key !== key) {
if (key !== null) return '';
const ask = `Call ${name} home: see what it costs first`;
return `<p class="plan-ctl menu">${planBtn({ plan: 'callAsk', member: id }, 'Call home…', ask, true, 'wide')}</p>`;
}
const c = Sim.callCost(st, id, dayViewer()),
name = Sim.fullName(st.pawns[id]);
if (!c) return '';
const words = [
c.walk > 0 ? `${name} walks home ${dayHours(c.walk)}` : `${name} is at home`,
c.load > 0
? `the ${Math.round(c.load * 10) / 10} it carries is brought in first, in about ${dayHours(c.bring)}` +
` (or, called at once, put down where it stands: ${dayHours(c.fetch)} out and back to fetch it)`
: 'it carries nothing',
c.task && c.left
? `its task in hand, ${dayRange(c.left)} left by ${dayWhose()} reckoning, waits`
: 'it has no task in hand',
];
const c = Sim.callCost(st, id, dayViewer(), key);
if (!c || (key !== null && !c.come)) return '';
const label = key !== null ? Sim.KINDS[st.jobs.get(key).kind].label.toLowerCase() : null,
what = key !== null ? `is at ${label}` : 'is home',
data = key !== null ? { plan: 'call', member: id, key } : { plan: 'call', member: id },
words = [
c.task && c.left
? `its task in hand, ${dayRange(c.left)} left by ${dayWhose()} reckoning, waits`
: 'it has no task in hand',
];
if (key === null) words.unshift(c.walk > 0 ? `${name} walks home ${dayHours(c.walk)}` : `${name} is at home`);
const go = key !== null ? `Call ${name} to ${label}` : `Call ${name} home`;
return (
`<p class="card-note day-cost" role="status">A call costs: ${esc(words.join('; '))}.</p>` +
`<p class="plan-ctl menu">${planBtn({ plan: 'call', member: id }, 'Call home', `Call ${name} home`, true, 'wide')}${
c.load > 0
? planBtn(
{ plan: 'call', member: id, urgent: 1 },
'Call at once',
`Call ${name} at once, the load set down`,
true,
'wide',
)
: ''
`<div class="card-note day-cost" role="status"><details class="day-kind"><summary>A call costs:</summary>` +
`<p class="card-note">${esc(`${words.join('; ')}.`)}</p></details>${callKinds(c, name, what)}</div>` +
`<p class="plan-ctl menu">${planBtn(data, c.load > 0 ? 'Load first' : 'Call', go, true, 'wide')}${
c.load > 0 ? planBtn({ ...data, urgent: 1 }, 'At once', `${go} at once, the load set down`, true, 'wide') : ''
}${planBtn({ plan: 'callNo' }, 'Leave at work', `Leave ${name} at its work`, true, 'wide')}</p>`
);
}
Expand Down Expand Up @@ -141,7 +178,7 @@ function dayHTML(hh, mine) {
function dayClick(b, hh) {
const d = b.dataset;
if (d.plan === 'callAsk') {
calling = +d.member;
calling = { member: +d.member, key: d.key === undefined ? null : d.key };
return undefined;
}
if (d.plan === 'callNo') {
Expand All @@ -150,7 +187,8 @@ function dayClick(b, hh) {
}
if (d.plan === 'call') {
calling = null;
return Sim.head(st, st.player.pawn, 'call', d.urgent ? { member: +d.member, urgent: true } : { member: +d.member });
const args = d.key === undefined ? { member: +d.member } : { member: +d.member, key: d.key };
return Sim.head(st, st.player.pawn, 'call', d.urgent ? { ...args, urgent: true } : args);
}
if (d.plan === 'dayOrder')
return Sim.head(st, st.player.pawn, 'dayOrder', { member: +d.member, from: +d.from, to: +d.to });
Expand Down
Loading
Loading