Search Apps Documentation Source Content File Folder Download Copy Actions Download State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

bubblerumble4 package

Overview

Package bubblerumble4 is the fourth Bubble Rumble realm. v3's game stays whole: of every bid 55% goes to the pot, 30% is credited at once to the pool's earlier bidders pro-rata to what they paid in, 10% to whoever invited the bidder, 5% to the pool's creator; every pool has a last day, a flag war at the close, credited earnings and Withdraw, a clock that can be bought down but never under MinClock. What v4 changes is the shot: it can now win the pot.

  • A shot is still extra money on a bid, a chance to pop the bubble at once. The chance is 0.8 × shot / take, at most 1% a shot, where the take is what a pop would pay the shooter right now: the pot less the team's 35%, times the winner's live share (LiveBps). So the pot keeps a fifth of every shot's fair value however far the last day has slid, and a hit pops the bubble: the pool closes with the shooter as its winner and Claim pays it as any pop.
  • The draw's randomness is a commit-reveal by the keeper — the operator's own box, which also settles pools on time. The keeper publishes sha256 hashes of secrets ahead of time (Commit); a bid with a shot takes the next unused one; the shot is drawn when someone (the keeper, or anyone) reveals that secret (Reveal) in the blocks ShotDelay to ShotDelay+ShotWindow after the bid. The seed is the secret with the shot's own facts and the reveal block's height and time. Nobody without the secret can grind it: not the shooter, not a validator. The secret's holder knows the two candidate block times a block ahead and may pick which of the window's three blocks to reveal in — three rolls, at most 2.4× fair on a 1% shot — which is why the keeper key and its operator never bid or shoot.
  • A shot not revealed in its window, or on a pool that closed first, is void: it goes into the pot and counts as a miss, as in v3. Nothing is refunded, so withholding a reveal never pays whoever withholds it. What remains is that a keeper who leads a pot could withhold a stranger's hit and let the money fall into the pot it leads: refused shots are counted on the pool for all to see, and so are reveals that came in the window's later blocks (the honest keeper always reveals at the first), so a keeper choosing its block would show.
  • Shots are sold only while the keeper is alive: a shot needs a free commitment and a sign of life (Commit or Heartbeat) within KeeperFresh. Otherwise the bid stands and the shot's money goes straight back in the same transaction.
  • Shots are refused in the last quarter of a pool's life (which also keeps every reveal window clear of the last day) and under MinShot. RevealTip is taken from every shot and credited to the keeper whoever sends the reveal (the secret sits in the mempool, and a proposer could copy it), so the keeper pays for itself. The keeper's own shots are refused outright.
  • Reveals go in shot order, so among two pending shots nobody chooses which pops.

Residuals, stated plainly: the secret holder's three rolls; the keeper-defender veto above; a proposer who reads the keeper's reveal in the mempool holds the secret too, and proposing the window's blocks could drop the reveal for a roll it does not like or leave it out altogether (a void), which Late and Voided show; keeper and validator together could grind. SetShots is the switch if any of it is seen. SetKeeper drops every unused commitment.

Function

ShotBps

func ShotBps(shot, take int64) int64

ShotBps is the chance a shot buys against what a pop would pay, in basis points.

Params

Command

gnokey query vm/qeval -remote "https://rpc.gno.land" -data "gno.land/r/g1leu8d2vsplhehcfkjg50mwgdpxdkt8tztu95wr/bubblerumble4.ShotBps(,)"

Result