'use client'; import type { Action, GameView } from '@/game/engine'; import { Button } from '@/components/ui/button'; export function BureaucratPayment({ game, act, busy, }: { game: GameView; act: (action: Action) => void; busy: boolean; }) { const pending = game.bureaucrat?.pending; const decision = game.decision; if ( !pending || decision?.kind !== 'bureaucratPayment' || decision.player !== game.me || decision.event !== pending.event || pending.owner !== game.me ) return null; const payer = game.players.find((player) => player.id === pending.payer)?.name ?? pending.payer; const payee = game.players.find((player) => player.id === pending.payee)?.name ?? pending.payee; const redirectAmount = pending.amount - pending.redirect; return (

Bureaucrat payment

The payment from {payer} to {payee} is {pending.amount} spice. You may redirect {pending.redirect}{' '} spice to the Bank: {payee} receives {redirectAmount} spice and the Bank receives{' '} {pending.redirect}, while {payer} still pays the full amount.

{pending.kind === 'bribe' && (

The recipient keeps this spice in front of their shield until the next Mentat Pause. It cannot be spent before then.

)} {pending.kind === 'revival' && (

This is the actual revival price. A separate free-revival award, if any, stays with Tleilaxu.

)}

Allowing the full payment preserves Bureaucrat for later use this phase.

); }