
Pyth Roulette: Building a BTC Price Betting Game with Pyth Entropy and Price Feeds
What is Pyth Roulette? Imagine a roulette wheel, but instead of a ball landing on a number, the "spin" is a live countdown powered by on-chain verifiable randomness, and the result is determined by the real-time price of Bitcoin. Pyth Roulette is a browser-based game where you: Pick ODD or EVEN Place a bet (play money -- no real funds) Watch as Pyth Entropy generates a random countdown between 3 and 30 seconds When the timer hits zero, the app grabs the live BTC/USD price from Pyth Hermes The last two digits of the whole-dollar price decide your fate If BTC is at $65,953, the last two digits are 53 - that's odd. Bet odd? You win. Bet even? Better luck next time. The key insight: the randomness comes from timing. Nobody can predict what BTC's price will be 17 seconds from now at the per-dollar level. Entropy decides when to look, and Price Feeds decide what we see. How Pyth Network Powers the Game Pyth Roulette is built on two Pyth products working in concert, each playing a distinct ro
Continue reading on Dev.to Tutorial
Opens in a new tab



