adventure: tell Pete this build knows what a party seat is

The party list is omitempty, so a solo run and a game box too old to push
seats reach Pete as the same empty slice, and those two want opposite
buttons. Pete's page was reading the empty one as "solo, therefore leader"
and offering a party member the button that throws away everyone's day.

One boolean, set on every sheet a build makes — in town, solo, or seated
with three others. It says something about the sender, never about the
character, so it is set unconditionally: a conditional flag would read as
"this player is solo" and land straight back in the hole it closes. An
older build sends no key at all, which decodes to false, which is the
answer Pete wants when it cannot tell.

Pete's half shipped already and withholds the button until this arrives.

Verified end to end against a local Pete, not just in tests: a solo leader
on a live expedition gets "Call the whole thing off" back, a member still
gets "Turn back alone" and never the abandon, and stripping the flag from
the same push takes the solo button away again.
This commit is contained in:
prosolis
2026-07-24 23:03:58 -07:00
parent ba41dc2d1b
commit 10d1e4adf5
3 changed files with 83 additions and 0 deletions
+12
View File
@@ -288,6 +288,18 @@ type RosterDetail struct {
// run — a party of one is not a party, and the page should say nothing rather
// than draw a roster with a single chair in it.
Party []PartySeatView `json:"party,omitempty"`
// PartyKnown says this sender knows what a party seat is. It is a fact about
// the build, never about the character, so it is set unconditionally on every
// sheet — in town, solo, or seated with three others — and must never be
// computed from whether Party has anything in it.
//
// Party being omitempty is why it exists: a solo run and a game box too old to
// push seats both arrive at Pete as an empty slice, and Pete's page has to
// decide from that whether the viewer may throw away everybody else's day. An
// old build sends no key, which lands as false, and Pete withholds the button.
// No omitempty here for the same reason — an absent field is the fail-closed
// answer and this one is never absent on purpose.
PartyKnown bool `json:"party_known"`
}
// PartySeatView is one body on a shared expedition, as the public page may see