Skip to content
 
 

Repository files navigation

0G RollPlay

Decentralized AI-Powered Multi-Chain Gaming Platform

Blockchain Gaming on the 0G Network
0G RollPlay is a gaming platform built on the 0G Network, using decentralized AI. It supports multiple blockchains like Ethereum (EVM), Solana, and more. Play-to-Earn (P2E) mechanics let you earn real crypto rewards.


Current Features

  • Decentralized AI
  • Multi-Chain Support: Play on Ethereum (EVM), Solana, and other supported blockchains. Your assets and rewards can move between chains.
  • Play-to-Earn (P2E): Earn real crypto rewards while playing. Rewards are powered by the 0G Network's AI to make payouts fair.
  • NFT Avatars: Create and use NFT avatars, supported on Ethereum, and other networks.
  • On-Chain Game Logic: All gameplay is controlled by smart contracts.
  • Token Integration: Stake and earn with native tokens across different blockchains.
  • Mobile and Desktop Ready: The platform works on both desktop and mobile devices.

Coming Soon

  • More Games: New games like Blackjack, Roulette, Slots, and others. All powered by decentralized AI.
  • Tournaments: Compete in cross-chain tournaments with prize pools. AI will manage the events and rewards.
  • Social Features: Chat, add friends, and interact with other players across different blockchains.
  • Better P2E: Improved reward systems that will work across all blockchains with the help of AI.

React Node.js TypeScript MongoDB Socket.IO Bootstrap Styled Components Axios

Quick Start

git clone <git-repository-url>
cd 0gRollplay

# Install root dependencies
npm install

# Go to the client folder and install its dependencies
cd client
npm install

# Start
npm start

Config

  • JWT issuancePOST /api/auth in controllers/auth.js signs a JWT with config.JWT_SECRET_KEY (see SESSION_EXPIRES_IN). The payload only contains user.id so you can safely extend it.
  • Client storage – Tokens are pushed into Axios’ default headers via client/src/helpers/setAuthToken.js. Persist them in localStorage/sessionStorage from your auth screen and call setAuthToken(token) on boot.
  • Protected routesmiddleware/auth.js expects the token in the x-auth-token header and injects req.user. Use the middleware on any route that needs authenticated identity.

Contributing Guidelines

Pre-PR Checklist

  • Branch is updated with main
  • No linting errors
  • No stray console logs or unused variables
  • UI changes tested on desktop and mobile
  • Added documentation or comments where needed
  • Any new .env variables are documented

Pull Request Rules

  • Use clear PR titles:
    • feat: add tournament lobby UI
  • PR description must include:
    • What changed
    • Why it changed
    • How to test
    • Screenshots for UI updates
  • Tag related issues/tasks.

Confidentiality

This repository is proprietary to 0G AI.

About

On-Chain Gaming Platform

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages