Rules & privacy
Casual mode. No wagers, no timers, no penalties — just the bluff.
How a table plays
- 2 or more players join a table and each gets 5 dice.
- The host starts the game; the contract rolls everyone's dice as encrypted values.
- Players take turns making public bids: a quantity and a face, e.g. "six 4s".
- Each new bid must raise the quantity, or match the quantity with a higher face.
- Instead of bidding, the current player can challenge the last bid.
- A challenge counts every die across every active player's hand that matches the bid's face — a face of 1 is always wildand counts toward any bid that isn't itself about 1s.
- If the true count meets or beats the bid, the bid was good and the challenger is eliminated. Otherwise the bidder is eliminated and the bid was a lie.
- Every hand from that round is revealed so the table can see the proof, then the survivors roll fresh hands for a new round.
- Last player standing wins the table.
What CoFHE hides
Dice are generated and stored as encrypted valuesby the smart contract itself using Fhenix CoFHE's FHE.randomEuint8(). No plaintext die value is ever written to storage or emitted in an event while a round is active — not to other players, not to an indexer, and not to the contract's own operator. Only the owning wallet can unseal its own hand off-chain, by signing a CoFHE permit.
When a challenge happens, the contract counts matches homomorphically — entirely over encrypted values — and only ever decrypts a single boolean: was the bid's quantity met? The actual count is never revealed, before or after the challenge.
What stays public
- Table membership, host, and turn order
- Every bid — its quantity, face, and bidder
- Who challenged whom, and the resulting good/lie verdict
- Who was eliminated, and each round's hands once revealed after that round's challenge
Known tradeoffs (MVP)
Die faces are derived as FHE.randomEuint8() % 6 + 1. Since 256 isn't evenly divisible by 6, faces 1–4 land very slightly more often than 5–6 — a small, documented bias acceptable for a casual MVP.
This is an MVP/prototype and has not been audited. Casual mode only: no wagers, ranked play, timers, or tournaments yet.