Docs

How Hooxy works, from the hook up. Everything here describes the design running on Solana.

Overview

Hooxy is a Solana launchpad where every token launches with a game built in. A Token-2022 transfer hook watches every trade on the token's Meteora Dynamic Bonding Curve (DBC) and updates on-chain game state. Trading fees fill a pot, and the winner of each round takes a share of it.

The core constraint shapes the product: DBC runs transfer-hook pools only while the bonding curve is live. At graduation Meteora revokes the hook from the mint and migrates liquidity to a DAMM v2 pool with a plain Token-2022 mint. So the curve is the game. Graduation is the grand finale: the last round settles, the pot pays out, and from then on the token trades like any other.

Hooxy is a hackathon submission for the Colosseum Crypto World's Fair, Meteora DBC side track (submissions close 2026-10-12). It runs on Solana. The lobby shows real on-chain games, where trades, settles and claims are real transactions.

Program id: GD2GSp6nFQqV4VHZBZe1b1FGCKPs2tbNFkRfqTzxfDwW. Meteora DBC: dbcij3LWUppWqq96dh6gJWwBifmcGfLSB5D4DuSMaqN.

How the hook works

The hook observes and never refuses. Token-2022 calls it on every transfer of a Hooxy token. It classifies the transfer, updates the game, and returns OK for every valid call, because any error would revert the trader's swap. The only calls it rejects are spoofed ones: a wrong mint or a wrong game account.

To classify, it reads the owner of the source and destination token accounts. DBC's pool authority (FhVo3mqL8PW5pH5U2CN4XE33DokiyZnUwuGpH2hmHLuM) owns the pool vaults, so:

TransferTestPlayer
Buysource owner is the pool authoritydestination owner
Selldestination owner is the pool authoritysource owner
Wallet transferneithersource owner (counts as an exit)

Fees are collected in SOL (collectFeeMode: QuoteToken), so DBC never moves the token for fees or referrals. A token transfer out of the vault is always a real buy.

  • Tiny by design: no CPIs, no loops over lists, no account creation, under 15k compute units.
  • No allow or deny logic, so it cannot be turned into a sell blocker.
  • Emits events into logs (NewLeader, TimerReset, LeaderVoided, RoundClosed) that the indexer, bots and this site read.
  • Buys are valued in SOL: the hook converts the token amount with the pool's sqrt_price, so Crown ranks by SOL spent and min buys are set in SOL.

Games

5 games ship now. Each is decided in constant time inside the hook. Each card shows the classic name too, so you know what you are playing.

Crown

Classic: King of the Hill

Biggest buy of the round takes the crown.

Rounds run on a fixed clock. The biggest single buy in the round holds the crown when time runs out and takes a share of the pot. If the holder sells or moves tokens, they lose the crown.

Preset: 15 min rounds, 50% of the pot per round.

Fuse

Classic: Last Buyer

Every buy relights the fuse. Last buyer standing wins.

Each qualifying buy adds time to a countdown, up to a cap. When the fuse burns out, the last buyer takes a share of the pot. If they sell or move tokens first, they lose the spot.

Preset: +30 s per qualifying buy, capped at 5 min, 50% of the pot per round.

Bullseye

Classic: Every Nth

Be the Nth buy. Hit the number, take the pot.

Every qualifying buy moves a public counter up by one. The buy that lands exactly on the target number (say the 69th) wins the round, and the counter starts again. Everyone can see the count, so timing is the whole game.

Preset: Buy #69 wins 50% of the pot. If nobody reaches #69 within 60 min, the round closes and the pot rolls over.

Summit

Classic: Milestones

Push the curve past 25, 50, 75%. Plant the flag.

The buy that carries bonding-curve progress past 25%, 50% and 75% wins that checkpoint's prize. Also available as an overlay on any other game.

Preset: Flags at 25%, 50%, 75% of curve progress, each paying 25% of the pot. Also available as an overlay on any other game.

Combo

Classic: Chain Breaker

Buys stack a combo. Sells break it. Longest combo pays.

Back-to-back buys build a combo; any sell breaks it. When the round ends, whoever made the last buy of the longest combo takes the prize. Buyers keep a streak alive; sellers are the villains.

Preset: 15 min rounds. The last buyer of the longest unbroken run of buys wins 50% of the pot.

Anti-gaming

  • Min buy, in SOL. Any size trades normally. The creator sets the smallest buy that counts for the game (default 0.01 SOL, range 0 to 0.1 SOL; 0 means every buy counts), so dust spam can't relight a fuse or pad a Bullseye count.
  • Exits void leadership. In Crown and Fuse, if the leader sells or moves tokens, they lose the spot. No buy-and-dump. In Combo, any sell breaks the chain.
  • Self-trading pays. Every trade pays the 2% fee, which feeds the pot, so wash trading to game a round costs more than it wins.
  • Sybils are fine. Every wallet still has to be the biggest, the last, or the Nth.

Game catalog

Twelve games fit inside a DBC transfer hook. They sort into tiers by what the hook needs: tier A runs on game state alone and ships now, tier B adds opt-in player accounts, tier C needs randomness at settle time.

GameHow you winHook logic per transferTier
CrownKing of the HillBiggest buy in the round by SOL spent, no exitsConvert the token amount to SOL with the pool sqrt_price; a buy above leader_sol takes the crown; any exit by the leader voids itA · live
FuseLast BuyerLast qualifying buy before the timer hits zeroA buy sets the leader and extends the timer, cappedA · live
BullseyeEvery NthThe Nth qualifying buy of the roundbuy_count += 1; when it hits N, that buyer becomes pending_winner and the round rollsA · live
SummitMilestonesThe buy that pushes curve progress past each checkpointCompare the pool's quote_reserve to the next threshold; record the crossing buyerA · live
ComboChain BreakerLast buyer of the longest unbroken run of buys in the roundBuy: chain += 1, remember buyer. Sell: if the chain is the best so far, store its last buyer, reset the chainA · live
DiamondDiamond HandsRegistered players who bought this round and never exited share the pot, pro rataBuy: player.round_bought += amount, game.eligible += amount. Exit: remove the player's amount, mark outB · player account
Red vs BlueTeam WarsThe team with more buy volume in the round splits the pot, pro ratateam_volume[team] += amount; player.round_bought += amountB · player account
StreakStreakBuy in N rounds in a row without sellingplayer.streak grows on the first buy of each new round, resets on exitB · player account
Lucky BuyLucky BuyOne buy per round, odds weighted by sizeHook adds to total_tickets; keeper posts a Merkle root of ticket ranges; Switchboard VRF picks a ticket; winner claims with a proofC · needs VRF, v2
Hot PotatoHot PotatoHolder of the potato when it blows at a hidden VRF timeHook writes a ring buffer of the last 32 (time, holder) pairs; settle looks up the holder at the revealed timeC · needs VRF, v2
Mystery TimerMystery TimerLast Buyer, but the end time stays hidden until revealEnd time committed at round start; hook keeps a ring buffer of buys; settle takes the last buy before the revealed endC · needs VRF, v2
Tug of WarTug of WarTwo tokens, one rope; when one graduates its buyers get the rival's potBoth hooks write a shared War PDAC · needs VRF, v2

Not possible on DBC

DBC creates the mint itself with only the transfer-hook extension, so Splits (Scaled UI Amount) and Mortal coins (permanent delegate) would need a launch flow outside DBC. They are not on the list.

No sell taxes, no blocked sells. The hook never refuses a trade, in any game.

Round engine & player accounts

One round engine

Rounds, lazy rollover, settle_round, Prize and claim_prize work the same for every game. A game only decides who the current leader is; the engine handles timing and payouts. That is why each new tier A game is about half a day of work once Crown works.

The hook can also read the DBC pool (quote_reserve, sqrt_price) as an extra account, which is how Summit knows when the curve crosses a checkpoint. Overlays run on every game: the graduation jackpot is always on, and Summit checkpoints can be added on top of any primary game.

Player accounts (opt-in)

Tier B games need per-wallet state. A player account is a PDA with seeds ["player", mint, wallet], created on this site for about 0.002 SOL of rent, refunded when you close it. The hook receives the source and destination owners' player accounts as extra accounts. If one is not initialized, the hook skips it, so unregistered wallets and trading terminals still trade normally; they just don't play the tier B game.

End goals

The end goal is how much SOL the curve raises before it graduates. DBC bakes that threshold (migrationQuoteThreshold) into its immutable config, so each end goal is its own platform config: 3 configs in total, shared by every game. The game itself (Crown, Fuse, and so on) lives in the Hooxy game state and is set by init_game, not in the DBC config.

End goalGraduates atFinaleIn short
Sprint~85 SOL raisedYesShort game, loud ending.
Marathon~800 SOL raisedYesMany rounds, big finale.
Endless~50,000 SOL raisedOnly if the ceiling is reachedThe game is the token.
Endless is honest about what it is. DBC has no infinite setting; the threshold only has the limits of MAX_SQRT_PRICE and u64 supply. Endless sets it very high (about 50,000 SOL raised) so in practice rounds run indefinitely. If the ceiling is ever reached, the normal finale runs. Summit is not offered on Endless, because its first flag would sit at 25% of that ceiling.

Pot & fees

Hooxy takes nothing. Of each trade's 2% fee, Meteora keeps its fixed protocol cut, the token's creator gets 25% of the rest, and everything else goes to the game's pot: about 1.20% of all curve volume. Every 100 SOL traded adds about 1.20 SOL to the prize.

StepShareOf 100 SOL volume
Trading fee (config)2% of volume2.00 SOL
Meteora protocol (fixed)20% of fee0.40 SOL
Creator25% of remainder0.40 SOL
Hooxy platform0%0.00 SOL
Pot (the whole partner share)everything else1.20 SOL

The pot's share is claimed by a program PDA (["fee_authority"]), not a hot wallet, and swept on-chain straight into the game's pot vault; no wallet of ours ever holds it.

Graduation adds a migration fee to the finale. When the curve completes, DBC takes a 3% migration fee on the SOL raised, and all of it is swept into the pot: about 2.55 SOL on a Sprint game and 24.00 SOL on a Marathon game, on top of everything still in the pot. That makes the finale much bigger than any single round.

Rounds & payouts

  • Lazy rollover. A round can end with no transaction at that moment, so rollover happens in whichever runs first: the hook on the next trade, or settle_round. The winner is copied to a pending slot, the round id bumps, and the new trade counts for the new round. Nobody loses a win.
  • Payouts are a share of the free pot (vault balance minus prizes still owed), so the program can never promise more than it holds.
  • Pull-based claims. Each settled round creates a Prize account. The winner claims it from the site, a Blink or an embed; the program unwraps wSOL into SOL.
  • 7-day expiry. A prize nobody claims within 7 days goes back into the pot for the next rounds.
  • Grand finale. When the curve completes, start_finale freezes the game and runs Winner Takes All. See Grand finale.

Grand finale

Winner Takes All. When the curve completes, the leader of the final round takes 100% of the pot plus the migration fee. No leader at that moment? The buy that completes the curve takes it all.

  • Who wins. The leader of the final round under the game's own rules: the biggest buy for Crown, the last buyer for Fuse, the longest-combo keeper for Combo. If there is no leader at that moment (a voided crown, a Bullseye count not hit, or Summit), the buy that completes the curve wins. The hook records that graduating_buyer with the pool read it already does, so every game has a finale winner.
  • Final stretch. Once curve progress passes 90%, normal round payouts stop and rounds roll over, so the whole pot builds up for the finale. Summit's 75% checkpoint still pays. Game pages show a “Final stretch” state and mark the 90% line on the curve bar.
  • The prize. 100% of the free pot plus the swept partner migration fee (finale_bps fixed at 10000).
  • Endless. No finale unless its ~50,000 SOL ceiling is ever reached; if it is, the same Winner Takes All runs.

Keeper & permissionless cranks

The keeper is a convenience, not a trust point. Every instruction except init_game and claim_prize is permissionless and idempotent, so if the keeper goes down anyone can settle a round, including the winner, from this site.

InstructionWhoWhat it does
sweep_feesanyoneClaims the partner fee from DBC by CPI, sends the platform share to treasury and the rest to the pot
settle_roundanyoneIf the round ended with a leader, creates the Prize, reserves the payout, starts the next round
expire_prizeanyoneAfter 7 days, releases an unclaimed prize back to the pot
start_finaleanyoneWhen the curve is complete, freezes the game and settles the final round
close_gameanyoneAfter the finale and all prizes are resolved, marks the game ended
claim_prizewinnerPays the prize to the winner as SOL

The keeper loops every few seconds: sweep fees about once a minute, settle rounds as they end, start the finale when the curve completes, expire old prizes hourly.

Embed, API, SDK

All game state is a public account, so any creator can show the live game on their own site. Three ways, from zero code to raw.

1. Embed widget

<script src="https://gamepad.fun/embed.js" data-mint="<MINT>" data-theme="dark" async></script>

Or as an iframe: https://gamepad.fun/embed/<MINT>. Every game page has an “Embed this game” button with the snippet filled in.

2. Public HTTP API

EndpointReturns
GET /api/games?status=live&sort=potLobby list
GET /api/game/:mintFull game state
GET /api/game/:mint/rounds?limit=20Past rounds: winner, payout, tx
GET /api/game/:mint/feed?limit=50Recent game events
GET /api/wallet/:address/prizesClaimable and past prizes
{
  "mint": "…", "name": "Throne Goblin", "ticker": "GOBLN",
  "mechanic": "crown", "endGoal": "sprint", "status": "live",
  "round": { "id": 14, "endsAt": 1759140000, "secondsLeft": 212 },
  "leader": { "wallet": "7xKp…3fQ", "amount": 1250000 },
  "pot": { "sol": 38.2, "nextPayoutSol": 19.1 },
  "lastWinner": { "wallet": "9aQ…", "sol": 12.4, "round": 13 },
  "curve": { "progressPct": 64.2, "graduated": false, "targetSol": 85, "raisedSol": 54.6 },
  "tradeCount": 1840, "createdAt": 1759100000
}

Try it: /api/games. It serves real on-chain games (each tagged "source": "chain").

3. TypeScript SDK

import { GamePad } from "@gamepad/sdk";

const gp = new GamePad(connection);
const game = await gp.getGame(mint);          // decoded GameState + pot balance
const stop = gp.onGameChange(mint, cb);       // accountSubscribe on GameState
const tx   = await gp.buildBuyTx({ mint, owner, solIn, slippageBps });
const ctx  = await gp.buildClaimPrizeTx({ mint, round, winner });
const url  = gp.blinkUrl(mint);               // shareable Blink

The SDK reads the chain directly and builds swaps with the hook's extra accounts already resolved. It has no dependency on our servers.

Safety & limits

  • Immutable mint authority. Launches use DBC's Immutable token authority: nobody keeps mint or update authority, which removes the mint rug.
  • Locked liquidity. 100% of migrated liquidity is permanently locked at graduation.
  • The hook cannot block sells. It has no allow or deny logic and returns OK for every valid transfer. The worst a game bug can do is score a round wrong, not trap your tokens.
  • Upgradeable and unaudited. The team holds the upgrade key for the hackathon; it gets frozen after an audit. The program hash is published.
  • An emergency pot cap. The admin can cap every pot in one transaction, without a redeploy; fees above the cap wait in the curve until prizes pay out.

Known limits

  • During the curve, trades must go through DBC's transfer-hook swap. Some terminals and aggregators may not route it yet, so early trading may happen on this site, Blinks and embeds only. After graduation the token trades everywhere.
  • Crown ranks by SOL spent, measured at the post-swap pool price, so a buy's value is slightly generous (the price has already moved up by that buy). The effect is small and the same for everyone.
  • The game only runs until graduation. After that the hook is gone.
Legal. Every game here is decided by skill and timing, with no randomness in the current version. Nothing on this site promises a return, and a pot is not an investment. Randomness-based games are v2 and would need separate legal review before launch.

FAQ

+Can I lose my tokens to the game?

No. The game never takes or locks tokens. It only watches trades and pays prizes from fees.

+What happens if I sell while I'm the leader?

In Crown and Fuse you lose the spot. The sell always goes through.

+Who pays the prize?

The pot, which is filled by the partner share of trading fees on that token's curve. Nothing else.

+Do I need an account?

No. Any wallet plays tier A games just by trading. Tier B games will need a small, refundable player account (about 0.002 SOL).

+What if nobody settles the round?

Any trade after the round ends rolls it over, and anyone can call settle_round. On live games the page gets a Settle button for exactly that; in this simulation rounds settle on their own.

+Why only during the curve?

Meteora removes transfer hooks at graduation. That's the design: the curve is the game, graduation is the finale.

+Is this live?

Yes, on Solana: games in the lobby are real on-chain games (real SOL). It's a hackathon submission for the Colosseum Crypto World's Fair.