GeoGacha is a Web3-powered exploration app that turns the real world into a loot map. Users walk to GPS-based locations, check in, and trigger onchain randomized rewards secured by onchain randomness on Flow . Designed for outdoor adventurers, brand activations, and gamified tourism, GeoGacha blends physical movement with provably fair digital rewards.
How GeoGacha Was Built
Core Stack:
- Frontend: Next.js 15 + TypeScript + Tailwind CSS for a mobile-first PWA experience
- Web3: Ethers.js connecting to Flow EVM Testnet (Chain ID: 545)
- Smart Contract: Solidity contract using Flow's Cadence Random Consumer for true on-chain randomness
- UI: Shadcn/UI components with custom animations and responsive design
Architecture Flow:
- GPS Simulation → Mock location data triggers proximity detection
- Wallet Connection → Auto-detects MetaMask, switches to Flow EVM, handles network addition
- Contract Calls → Two-step randomness:
getRandomNumber()
for rarity, selectRandomItem()
for specific rewards
- Fallback System → Graceful degradation when contract calls fail
Partner Tech Benefits:
- Flow EVM: Ethereum compatibility with Flow's performance and native randomness
- Cadence Random Consumer: Eliminates need for external oracles like Chainlink VRF
Notable Hacks:
- Dual Randomness Strategy: Contract-first with local fallback ensures 100% uptime
- Network Auto-Switching: Automatically adds Flow EVM Testnet to MetaMask if missing
- GPS Proximity Simulation: Uses percentage-based positioning for demo without requiring actual GPS
- Weighted Rarity System: Single contract call determines rarity (5% legendary, 20% rare, 75% common) then selects from appropriate pool
Clever Implementation: The app calls your deployed randomness contract for authentic blockchain-based rewards while maintaining smooth UX through optimistic UI updates and error handling.