Dhaniverse

Learn about money, earn for real. Protocols get noticed, players get paid.

Dhaniverse

Created At

ETHGlobal Mumbai

Project Description

Dhaniverse is a multiplayer 3D town that runs in your browser, where the money is real. There are no coins, gems or play money. Everything you earn, spend or save in the town is USDC, every cent has a receipt, and what you earn you can withdraw.

You live there like you would anywhere: you work, eat, trade, save and decide what to do with what you have. Because the money is real, the choices feel real, and you end up understanding money the way you understand a game you’ve played a hundred times. Nobody lectures you. You just play, and it sticks.

The town’s quests are funded by protocols and sponsors. A protocol puts in a real budget, its quest shows up in the town, and players earn USDC by actually using the product: swapping on it, holding its token, trying what it built. The protocol gets real people trying it for the first time, not bots clicking through a form. Players get paid in real money for their time.

The town runs on its own economy. Energy comes from food, and players buy meals with USDC. Every meal is a real swap on Uniswap v4 in the town’s food market, and the food token can never leave the game. The money players spend on food goes to the town treasury, which sends most of it (70%) back into the house pool and keeps the rest to run the game. Sponsor budgets don’t just sit there either. While a campaign is live, the unspent part is put into yield vaults that can be withdrawn instantly, and the interest flows into the house pool. Sponsors can still take back what’s unspent when their campaign endsThe house pool pays everything the town gives back in real USDC: daily errands, login streaks, competition prizes, the weekly draw and treasure chests that can drop real dollars. It also buys free rescue meals for anyone who runs out of money.. It can only spend a small share of its balance each day, so it never runs dry. Food spending and sponsor yield keep refilling it, and that’s how the town pays players every day without printing fake money.

To keep it fair, every player proves they’re one real person with World ID before the town pays them, so nobody can farm the house pool with a hundred accounts. The game pays the gas, so players never see a wallet popup or need to know anything about crypto to start. The town’s records, the odds of every reward and the house pool’s daily books are published openly on Arkiv, so anyone can check that the game plays fair.

The town is shared and it keeps going when you log off. Other players move the same market, eat at the same tables and walk the same streets. Every meal anyone eats nudges the food price for everyone else.

How it's Made

Dhaniverse has four parts: a Godot game client, a Rust game server, Solidity contracts on Ethereum Sepolia, and a small Node service that publishes the town’s public data to Arkiv and Swarm.

The game. The client is Godot 4.7 written in GDScript and exported to the web as WebAssembly. We use the Compatibility (WebGL 2) renderer and a single-threaded build on purpose. That way it runs inside an iframe on any site without the special cross-origin headers threaded builds need. The town is built in code at startup: 17 buildings we modelled, about 390 street pieces, 336 trees and the terrain, water and grass, all drawn with our own shaders. Our first web build froze for a few seconds while shaders compiled, so now we compile them behind the loading line and ship our own loader with an offline cache. Returning players don’t download the game again. The UI is drawn by hand to our design boards: dark plates over the world for energy, money and the clock; a phone with wallet, quests, feed, town and mentor pages; paper sheets for letters and the daily paper; and our own fonts and colours throughout.

The server. The server is Rust. The core is a rules crate with no clock, no network, no disk and no randomness. Every action goes through one function that either applies it or refuses it with a named reason. Players, the farm, the newspaper and even reports from the blockchain all go through that same door. The town’s characters (Kofi’s farm, the residents, the mentor and The Tally, our newspaper) are agents that send commands exactly like players do, so they can’t break a rule either. The save file is an append-only log, and the town restarts by replaying it. Money is counted in USDC base units with overflow checks left on in release builds, so a balance can never silently wrap around. Players talk to the server over WebSockets.

On-chain. The contracts are Solidity, built and tested with Foundry. There are 217 tests, with 5,000 fuzz runs in CI, and CI also checks the code against a plain-English spec of every contract. The server talks to the chain with Alloy. It holds each player’s wallet, signs meal tickets and payout vouchers with EIP-712, sends transactions from separate per-key queues, and reads confirmed events back into the game. Players never see a wallet popup or pay gas. Instead of sending a swap for every meal, the server adds up a few minutes of meals across the whole town and sends one trade.

Partner tech, and why it mattered.

Uniswap v4: the food market is a v4 pool with our own hook. Only our router can trade in it, and the price can move at most 15% a day within a fixed floor and ceiling. FOOD can only move between the game’s own contracts, and that list is locked forever after deploy. We made both sides of every transfer check the list, because v4’s PoolManager could otherwise hand tokens to anyone. The Spice Run quest goes through Uniswap’s Universal Router. World ID 4.0: this is what makes paying real USDC safe. One person gets one Town Pass, so nobody can drain the house pool with fake accounts. We wrote the request-signing step ourselves in Rust and test it against World’s published test vector. The server rejects a proof that’s for the wrong action, the wrong environment, the wrong wallet or a reused nonce before it even asks World. ENS v2: every verified player gets a name, and the shop sign you paint is saved on it. Arkiv: this is our database. The whole save is pushed to it encrypted, in hash-chained batches, and the server can be rebuilt from Arkiv alone. A restore test does exactly that. Public data (chest draws with their odds, the house pool’s daily books, leaderboards, prices, sponsor campaigns) is stored as queryable entries that expire on their own. A login streak is an entry that lasts 8 days and gets extended each day you log in: if it expires, your streak is broken, and no cleanup job is needed. Tests check that no balance, wallet or World ID result ever appears in public. Swarm: stores the newspaper text, season snapshots and sponsor campaign files. The campaign file’s Swarm address is saved on-chain.

Web pages. A Next.js site hosts the game. There’s a World ID page with a QR code you scan with World App, a sponsor console for creating campaigns, and a live dashboard that reads the contracts directly with viem.

background image mobile

Join the mailing list

Get the latest news and updates