Skip to content

Latest commit

ย 

History

History
110 lines (87 loc) ยท 3.45 KB

File metadata and controls

110 lines (87 loc) ยท 3.45 KB

Vaibe Arcade

Vaibe Arcade is a modern, AI-powered gaming platform and creator ecosystem. It features a rich catalog of games, real-time leaderboards, quest systems, and a dedicated zone for creators to manage their content and view analytics.

๐Ÿš€ Tech Stack

Frontend

  • Framework: React 18 with Vite
  • Language: TypeScript
  • Styling: Tailwind CSS + Radix UI
  • State Management: TanStack Query (React Query)
  • Icons: Lucide React & Heroicons

Backend

  • Framework: FastAPI (Python)
  • Database & Auth: Supabase (PostgreSQL)
  • AI Integration: Google Generative AI (Gemini) & Replicate
  • Middleware: CORS & GZip compression

Infrastructure

  • Hosting: Vercel (Frontend & Backend)
  • Database: Supabase with migrations and real-time triggers

โœจ Key Features

  • ๐ŸŽฎ Game Hub: Integrated Unity game embeds with session tracking and ratings.
  • ๐Ÿ† Leaderboards: Dynamic weekly and all-time leaderboards with historical tracking.
  • ๐Ÿ—บ๏ธ Quests & Raffles: Gamified user engagement through questing and raffle systems.
  • ๐ŸŽจ Creator Zone: A specialized dashboard for creators to manage games and view player insights.
  • ๐Ÿ’ฐ Shop & Economy: Virtual currency system (Atomic Coins) with an integrated shop.
  • ๐Ÿค– AI-Powered: Generative AI capabilities for asset creation and assistant features.

๐Ÿ› ๏ธ Project Structure

โ”œโ”€โ”€ backend/            # FastAPI Python server
โ”‚   โ”œโ”€โ”€ app/            # Main application logic
โ”‚   โ”‚   โ”œโ”€โ”€ api/        # API endpoints (v1)
โ”‚   โ”‚   โ”œโ”€โ”€ core/       # Config and security
โ”‚   โ”‚   โ”œโ”€โ”€ crud/       # CRUD operations
โ”‚   โ”‚   โ”œโ”€โ”€ db/         # Database (Supabase)
โ”‚   โ”‚   โ”œโ”€โ”€ models/     # Database models
โ”‚   โ”‚   โ””โ”€โ”€ schemas/    # Pydantic schemas
โ”‚   โ””โ”€โ”€ main.py         # Local development entry point
โ”œโ”€โ”€ frontend/           # React + Vite application
โ”‚   โ”œโ”€โ”€ src/            # Source code
โ”‚   โ”‚   โ”œโ”€โ”€ components/ # Reusable UI components
โ”‚   โ”‚   โ”œโ”€โ”€ contexts/   # React contexts (Auth, Game)
โ”‚   โ”‚   โ”œโ”€โ”€ hooks/      # Custom React hooks
โ”‚   โ”‚   โ””โ”€โ”€ pages/      # Application views/routes
โ”œโ”€โ”€ supabase/           # Migrations, seed data, and Edge Functions
โ””โ”€โ”€ scripts/            # Utility development scripts

๐Ÿ Getting Started

Prerequisites

  • Node.js (v18+)
  • Python (v3.11+)
  • Supabase Account

Installation

  1. Clone the repository:

    git clone <repo-url>
    cd arcade
  2. Install all dependencies:

    # From the root directory
    npm run install:all
  3. Environment Setup: Create a .env file in the backend/ directory with the following:

    SUPABASE_URL=your_supabase_url
    SUPABASE_KEY=your_supabase_key
    GOOGLE_API_KEY=your_google_ai_key
    REPLICATE_API_TOKEN=your_replicate_token

Running Locally

  • Run Everything: Use the root commands to start both services.

    # Frontend
    npm run dev
    
    # Backend
    npm run dev:backend
  • Manual Start:

    # Frontend
    cd frontend && npm run dev
    
    # Backend
    cd backend && source .venv/bin/activate && uvicorn app.main:app --reload

๐Ÿ“ฆ Deployment

The project is configured for seamless deployment on Vercel.

  • Frontend is deployed as a static site.

  • Backend is deployed as Serverless Functions via the vercel.json configuration in the root.