Coop: stack same-type gifts on the same day into a single vote post

Multiple baskets (or multiple mimics) sent during the same day now share
one game-room post, one vote, one resolution. First-in becomes the stack
"lead"; subsequent same-type sends become followers that inherit the
lead's deadline and votes.

Behavior:
- Send a basket → new lead, new post, 6h timer starts
- Send another basket within the window → silently joins the stack,
  edits lead's post to bump count
- At stack size 2, TwinBee adds a "this gift looks REALLY special" line
  (one of 5 variants picked deterministically by lead id). No further
  escalation as the stack grows
- One !coop giftvote on the lead's id covers the whole stack
- Resolution applies the same outcome to every gift in the stack;
  modifier is N × ±6
- End-of-run gift log groups by stack with all senders attributed

Schema: coop_dungeon_gifts.stack_lead_id INTEGER (NULL for lead/standalone,
otherwise points at lead's id). Migration entry included.

Why first-in deadline (vs extending on each follower): exploitability.
Saboteurs could spam-extend a stack to delay resolution. Locked deadline
keeps senders honest about timing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
prosolis
2026-04-28 22:28:23 -07:00
parent 48e5000745
commit 07ca5288c3
6 changed files with 385 additions and 117 deletions

View File

@@ -389,6 +389,19 @@ var TwinBeeGiftArrival = []string{
"Majority rules. Ties go to {leader}.",
}
// ── GIFT STACK ESCALATION ─────────────────────────────────────────────────────
// Posted once when a stack reaches size 2+. TwinBee notes the escalation and
// then leaves it alone — further additions silently bump the count without
// fresh narration.
var TwinBeeGiftStackEscalation = []string{
"Oh snap.. upon closer inspection, this gift stack looks REALLY special!",
"Wait wait wait. Wait. There's MORE. Someone else sent something! This is becoming an event!",
"Hold on -- is this... another one? Someone really wants you to have this. The energy here is escalating!",
"Plot twist! This isn't just a gift, it's a gift situation. I love a gift situation!",
"That's not one gift, that's a whole stack of gifts! Someone is COMMITTED. I respect commitment!",
}
// ── GIFT OUTCOME NARRATION ────────────────────────────────────────────────────
// Care basket opened (good outcome):