https://github.com/solzarr/casino-game-smart-contract
Casino Game Smart Contract: A decentralized casino(Jackpot) smart contract built on the Solana blockchain using the Anchor framework. This project implements a jackpot system with secure random number generation using ORAO Network's VRF (Verifiable Random Function).
https://github.com/solzarr/casino-game-smart-contract
casino-games casino-smart-contract coinflip crash-game gamefi jackpot web3-game
Last synced: 18 days ago
JSON representation
Casino Game Smart Contract: A decentralized casino(Jackpot) smart contract built on the Solana blockchain using the Anchor framework. This project implements a jackpot system with secure random number generation using ORAO Network's VRF (Verifiable Random Function).
- Host: GitHub
- URL: https://github.com/solzarr/casino-game-smart-contract
- Owner: solzarr
- Created: 2025-10-05T13:20:42.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2025-11-08T15:21:58.000Z (9 months ago)
- Last Synced: 2025-11-12T00:11:54.412Z (8 months ago)
- Topics: casino-games, casino-smart-contract, coinflip, crash-game, gamefi, jackpot, web3-game
- Language: Rust
- Homepage: http://casino-muxin.vercel.app
- Size: 26.4 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Chess game smart contract(Casino)
Onchain casino game smar contract - A Solana smart contract for Chess game between two parties, designed for use cases like chess or other competitive games.
## Overview
This program allows two users to securely deposit SOL into an escrow account, with funds released to the winner (or split as needed) after the result is determined. The contract handles fee distribution, rent exemption, and ensures only valid parties can interact with the escrow.
## Contact
If you have any quesion, contact here: [Telegram](https://t.me/solzarr) | [Twitter](https://x.com/asma)
## Features
- **Initialize Escrow:** Either party can create or join an escrow by depositing SOL.
- **Withdraw Escrow:** After the result is determined, the winner (or both parties) can withdraw the escrowed funds.
- **Fee Distribution:** A small fee is distributed to admin and fee accounts, with the majority of funds held in escrow.
- **Rent Exemption:** Ensures escrow accounts are rent-exempt on Solana.
## Directory Structure
- `src/processor.rs` — Main logic for processing instructions and handling escrow state.
- `src/instruction.rs` — Defines the instructions (init, withdraw) and their serialization.
- `src/state.rs` — Escrow account structure and packing/unpacking logic.
- `src/error.rs` — Custom error types for the program.
- `src/entrypoint.rs` — Solana program entrypoint.
## Accounts
- **Creator:** The user who initializes the escrow.
- **Competitor:** The second party joining the escrow.
- **Admin/Fee Accounts:** Receive a small portion of the wager as fees.
- **PDA Account:** Holds the escrowed funds securely.