Skip to content

Latest commit

 

History

History
241 lines (177 loc) · 8.98 KB

README.md

File metadata and controls

241 lines (177 loc) · 8.98 KB

🎰 OpenHouse Casino

The first casino where YOU can be the house

Built by Alexandria - an open-source gaming studio on the Internet Computer.

Note: This repository contains only the frontend. Backend canisters are maintained separately in the OpenHouse-backend repository.

🎯 What Makes OpenHouse Different

Traditional online casinos keep all the profits and hide their odds. OpenHouse flips this entirely:

💰 Revolutionary Economic Model

You can own the house - Instead of playing against a faceless corporation, users provide the house liquidity and own shares of the games. The house money is provided by users like you, who earn a portion of the casino's profits.

Transparent 1% house edge - Every game maintains exactly 1% house edge, verifiable through:

  • Open-source code you can audit
  • Internet Computer's VRF (Verifiable Random Function) for provably fair randomness
  • Publicly visible multiplier tables and payout calculations

$ALEX stakers earn 100% of revenue - OpenHouse is built by Alexandria studio, and all revenue flows to $ALEX token stakers. The revenue model is beautifully simple: a 1% fee on house money withdrawals goes directly to $ALEX stakers.

✨ Core Principles

  • Provably Fair: Every game result is cryptographically verifiable using IC's VRF
  • Bot Resistant: VRF randomness cannot be predicted or manipulated
  • Fully Transparent: All code is open-source, all odds are public
  • Community Owned: Users provide liquidity, users own shares, users verify fairness

The name "OpenHouse" is a triple play on words:

  • We're the house (casino)
  • Everything is open-source with transparent odds
  • The house is open to everyone - you can become the house

🎮 Live Games

Game Description House Edge Max Win Play Now
Crash Multiplier rises until crash - cash out before it's too late 1% 1000x Play
Plinko Drop a ball through pegs into multiplier slots 1% 1000x Play
Roulette European roulette with single zero 2.7% 35x Play
Dice Roll over or under your target number 1% 100x Play
Life Conway's Game of Life simulation - - Play

Frontend: https://pezw3-laaaa-aaaal-qssoa-cai.icp0.io

💎 Economic Model & Revenue

How Being "The House" Works

In traditional casinos, the house provides all liquidity and takes all profits. At OpenHouse:

  1. Users provide house liquidity - Deposit ckUSDT (stablecoin pegged to $1) to become a liquidity provider (LP)
  2. Receive ownership shares - Get LP tokens representing your share of the house
  3. Earn from the edge - The 1% house edge flows to LP holders proportionally
  4. Withdraw anytime - Pull your liquidity plus earnings whenever you want

Revenue Distribution

OpenHouse has a transparent, simple revenue model:

  • Players play games with a transparent 1% house edge using ckUSDT
  • Liquidity providers earn from the house edge on every bet
  • $ALEX stakers receive 100% of platform revenue via a 1% fee on LP withdrawals
  • No hidden fees - That's it. No rake, no VIP programs, no misleading promos

Built by Alexandria

OpenHouse is created by Alexandria, an open-source gaming studio building on the Internet Computer. All OpenHouse revenue flows to $ALEX token stakers, making this casino a revenue-generating product for the Alexandria ecosystem.

Why this matters:

  • Aligned incentives: Alexandria succeeds when OpenHouse succeeds
  • Long-term thinking: Not a cash grab, but ecosystem building
  • Open-source commitment: Transparency is core to Alexandria's mission
  • Community first: $ALEX stakers benefit from all Alexandria products

🏗️ Architecture

OpenHouse is split into two repositories:

This Repository (Frontend)

openhouse/
├── openhouse_frontend/     # React/TypeScript UI
│   ├── src/                # Source code
│   └── dist/               # Built assets
├── deploy.sh               # Frontend deployment script
├── dfx.json                # IC configuration
└── CLAUDE.md               # Developer guide

Backend Repository

Backend canisters are maintained in OpenHouse-backend:

Canister ID Purpose
Crash fws6k-tyaaa-aaaap-qqc7q-cai Crash game logic
Plinko weupr-2qaaa-aaaap-abl3q-cai Plinko game logic
Roulette wvrcw-3aaaa-aaaah-arm4a-cai Roulette game logic
Dice whchi-hyaaa-aaaao-a4ruq-cai Dice game logic
Life1 pijnb-7yaaa-aaaae-qgcuq-cai Game of Life - Server 1
Life2 qoski-4yaaa-aaaai-q4g4a-cai Game of Life - Server 2
Life3 66p3s-uaaaa-aaaad-ac47a-cai Game of Life - Server 3

🚀 Quick Start

⚠️ Important: OpenHouse runs entirely on IC mainnet. There is no local testing environment - all development and testing happens in production.

# Deploy frontend to mainnet
./deploy.sh

# Deploy with tests
./deploy.sh --test

Note: Backend canisters are deployed separately from the OpenHouse-backend repository.

🔬 How Provable Fairness Works

1. Verifiable Random Function (VRF)

Every game uses the Internet Computer's raw_rand() function, which provides cryptographically secure randomness that:

  • Cannot be predicted before generation
  • Cannot be manipulated after request
  • Can be verified by anyone on-chain

2. Transparent House Edge

The house edge is hardcoded in the backend game logic and visible in the source code (see OpenHouse-backend).

3. Open Source Verification

Anyone can:

  1. Read the game logic on GitHub
  2. Verify the deployed canister matches the source code
  3. Calculate expected return from multiplier tables
  4. Confirm house edge matches claims

🎲 Game Details

Crash

  • Multiplier starts at 1.00x and increases
  • Cash out before the crash to win
  • Crash point determined by VRF
  • Min bet: 0.01 USDT | Max win: 1000x

Plinko

  • Drop ball through 8, 12, or 16 rows of pegs
  • Choose risk level: Low, Medium, or High
  • Different multiplier distributions per configuration
  • Min bet: 0.01 USDT | Max win: 1000x

Roulette

  • European roulette (single zero)
  • Multiple bet types: straight, split, street, corner, etc.
  • Min bet: 0.01 USDT | Max win: 35x (straight bet)

Dice

  • Roll a number from 0-100
  • Predict over or under your target
  • Adjustable win chance from 1% to 98%
  • Min bet: 0.01 USDT | Max win: 100x

🛠️ Development

Prerequisites

  • dfx (IC SDK)
  • Node.js and npm
  • Git

Project Structure

openhouse/
├── openhouse_frontend/
│   ├── src/                # React/TypeScript source
│   ├── public/             # Static assets
│   ├── package.json        # Dependencies
│   └── vite.config.ts      # Build configuration
├── deploy.sh               # Deployment script
├── dfx.json                # IC configuration
└── CLAUDE.md               # Developer guide

Local Development

cd openhouse_frontend
npm install
npm run dev

Deploy to Mainnet

./deploy.sh

Testing

# Deploy with automated tests
./deploy.sh --test

# Or manually check
open https://pezw3-laaaa-aaaal-qssoa-cai.icp0.io

🤝 Contributing

OpenHouse is open-source and welcomes contributions:

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Deploy and test on mainnet
  5. Submit a pull request

Frontend vs Backend Changes

  • Frontend changes: Submit PRs to this repository
  • Backend changes: Submit PRs to OpenHouse-backend

📚 Resources

🔐 Security

  • All randomness from IC's VRF - cryptographically secure
  • Each game manages its own treasury independently
  • Open source allows public security audits
  • Mainnet-only deployment ensures production-grade security

📜 License

OpenHouse is open-source software. See LICENSE file for details.


The house always has an edge. At OpenHouse, that edge is transparent - and you can own it.

Built with ❤️ by Alexandria