Open Source 2D Gaming Platform - Play, Compete, and Create Together!
Welcome to 2D Champion - a community-driven platform where gamers play, compete on global leaderboards, and developers collaborate to build amazing 2D games!
๐ Live Platform: 2d-champion.vercel.app
- ๐ฏ Play Free Games - Enjoy a growing collection of 2D games, all free and open source
- ๐ Global Leaderboards - Compete with players worldwide and climb the ranks
- ๐ฅ User Profiles - Track your scores, achievements, and contributions
- ๐ง Open Source - All game code is public and available for contribution
- ๐ฑ Responsive Design - Play on desktop, tablet, or mobile
- ๐ Secure Authentication - Powered by Supabase with row-level security
| Game | Description | Play Count |
|---|---|---|
| Highway Hero | Dodge traffic and survive as long as you can! | ๐ |
| Pixel Python | Classic snake game with a modern twist | ๐ |
More games coming soon! Contribute yours
- Visit the platform (or run locally)
- Browse available games
- Click "Play" and start gaming!
- Sign up to save your high scores
# Clone the repository
git clone https://github.com/bytestrix/2DChampion.git
cd 2DChampion
# Install dependencies for the web platform
cd web
npm install
# Set up environment variables
cp .env.example .env.local
# Edit .env.local with your Supabase credentials
# Run the development server
npm run dev
# Open http://localhost:3000- Create a Supabase project
- Run the SQL schema in the Supabase SQL Editor:
# The schema file is located at: supabase/schema.sql - Copy your Supabase credentials to
.env.local
2DChampion/
โโโ web/ # Next.js web application
โ โโโ src/
โ โ โโโ app/ # App router pages
โ โ โโโ components/ # Reusable components
โ โ โโโ lib/ # Supabase client & utilities
โ โ โโโ types/ # TypeScript types
โ โโโ public/ # Static assets
โโโ games/ # Game source files
โ โโโ highway-hero/ # Highway Hero game
โ โโโ pixel-python/ # Pixel Python game
โ โโโ [your-game]/ # Add your game here!
โโโ docs/ # Documentation site (coming soon)
โโโ supabase/ # Database schemas & migrations
โโโ schema.sql # Database schema
- Framework: Next.js 16 (App Router)
- Language: TypeScript
- Styling: Tailwind CSS + Custom CSS
- Icons: Lucide React
- Hosting: Vercel (recommended)
- Database: Supabase (PostgreSQL)
- Authentication: Supabase Auth
- Storage: Supabase Storage (for game assets)
- Real-time: Supabase Realtime (for leaderboards)
- Technologies: Next.js (React), Tailwind CSS, TypeScript, Supabase
- Canvas API for game rendering
- No heavy game frameworks - keep games lightweight!
We welcome contributions from developers of all skill levels! Here's how you can help:
Important: Contributors don't need database access! Follow this simple workflow:
- Propose Your Idea - Create a GitHub Issue describing your game
- Fork the Repository - Clone and create your game component
- Build Your Game - Develop in a new subfolder:
games/your-game-name/YourGame.tsx- Use the existing game components as templates
- Implement scoring, controls, and game logic
- Test locally (game works without database connection)
- Create a PR - Submit with:
- Game component code
- Thumbnail image (512x512 PNG)
- Instructions on how to play
- Any special dependencies
- Maintainers Handle Backend - We'll register your game in the database and deploy
You DON'T need:
- โ Supabase credentials
- โ Database access
- โ Deployment permissions
Maintainers will:
- โ Review and test your game
- โ Register it in the platform
- โ Handle database setup
- โ Deploy to production
See SECURITY.md for more details on the separation between contributors and maintainers.
- ๐ Report bugs
- ๐ก Suggest features
- ๐จ Improve UI/UX
- ๐ Write documentation
- ๐งช Add tests
- Getting Started - Set up your development environment
- Game Development Guide - Learn how to create games
- API Reference - Supabase database schema & functions
- Deployment Guide - Deploy your own instance
- All sensitive credentials are kept in environment variables (never committed)
- Row Level Security (RLS) protects user data
- Supabase's anon key is safe for frontend use
- Authentication handled securely by Supabase Auth
- โญ Star this repo if you like the project!
- ๐ Report bugs via GitHub Issues
- ๐ฌ Discussions on GitHub Discussions
- ๐ข Follow updates on Twitter (coming soon!)
This project is licensed under the GNU General Public License v3.0 - see the LICENSE file for details.
- โ You can use this code for free
- โ You can modify and distribute it
- โ You can use it commercially
โ ๏ธ You must open source any modificationsโ ๏ธ You must use the same GPL-3.0 license
- Built with โค๏ธ by the open source community
- Powered by Supabase
- Deployed on Vercel
- Styled with Tailwind CSS
- Core platform with authentication
- Game listing and playing
- Leaderboard system
- User profiles with stats
- Game rating and reviews`
- Achievements and badges
- Multi-player support
- Game tournaments
- Mobile app (React Native)
Have questions or suggestions? Reach out!
- GitHub: @bytestrix
- Email: bytestrix@gmail.com
Made with ๐ by the 2D Champion community
Play games. Break records. Build together. ๐ฎโจ
