Traditional hash commitments require two operations and cannot prevent second-mover attack. Onetappy compresses player interaction to a single action via a partner deposit mechanism, completely blocking second-mover attack through economic penalties.
[01] — Roles
[02] — Deposit Mechanism
When a partner creates a game, they deposit the full amount (ticket price × quantity), held in escrow by the smart contract. No one — including the partner — can withdraw it early.
10 tickets × 0.1 ETH = 1 ETH deposit
If the partner refuses to submit the seed or submits an incorrect seed, the contract immediately triggers a penalty, slashing part or all of the deposit and distributing it to affected players. The economic cost of cheating far outweighs any potential gain.
Look-ahead gain < Deposit loss
The deposit mechanism makes honest operation the rational dominant strategy for partners. Normal settlement returns the full deposit plus 5–10% revenue, fully aligning economic incentives with fairness.
Honest settlement → Full deposit returned + Revenue
[03] — Full Flow
Set ticket price at 0.1 ETH, 10 tickets, game duration 1 hour, with Apple MacBook Pro as the prize.
Share the game link via communities and platforms to recruit 10 users interested in purchasing a MacBook Pro.
Transfer 1 ETH deposit to the smart contract. No one — including the platform or the partner — can withdraw it early.
Submit an encrypted commitment to the smart contract. The configured game parameters are written in and enforced by the smart contract.
Each player only needs one transaction with the smart contract: simultaneously submit 0.1 ETH ticket payment and a personal random number. Atomically written to the contract — no second reveal step required.
After the 1-hour game ends, the partner submits the original revealData. All player random numbers are mixed to select the winning user. The random number is verifiable.
Upon settlement, the contract immediately executes distribution: the winning player receives the prize, the partner earns 5% revenue, and the deposit is fully returned. No manual intervention required.
[04] — Comparison
| Metric | Traditional Commit-Reveal | Onetappy |
|---|---|---|
| Player Actions | 2 | 1 |
| Look-ahead Protection | None | Deposit Mechanism |
| Gas Cost | High (2 txns) | Low (~50% savings) |
| Comm. Cost | O(2) | O(1) (~50% savings) |
| Economic Incentive | None | Partner 5–10% Revenue |
| Game Organizer Role | No defined role | Partner Mechanism |
| Fund Distribution | Manual | Auto real-time by contract |
| On-chain Verifiable | ✓ | ✓ |
[05] — Get Started
Configure games independently, promote freely, and enjoy a stable 5–10% revenue share. Deposit fully refunded after normal settlement.
Apply →Connect your wallet and participate in one action. Fair and transparent — results verifiable on-chain, winnings automatically transferred.
Connect Wallet (soon) →