Skip to content

aryamangodara/snake_controller

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

23 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ Cross-Device Snake Game

A modern take on the classic Snake game where you play on your desktop and use your smartphone as a wireless controller!

Play Demo Firebase License: MIT


๐ŸŽฎ How to Play

1. Host on Desktop

Open the Live Demo on your computer. A unique 6-digit session code and QR code will appear.

2. Connect Mobile

Scan the QR code with your phone or enter the session code manually.

3. Control

  • Joystick: Rotate to turn, pull further for a speed boost.
  • Play Button (โ–ถ): Start the game.
  • Restart Button (โ†ป): Play again after a crash.

๐Ÿš€ Local Development

If you want to run the project locally or contribute:

Prerequisites

Setup

  1. Clone & Install

    git clone https://github.com/yourusername/snake-game.git
    cd snake-game
    npm install
  2. Configuration Add your Firebase credentials to public/js/config.js.

  3. Run

    npm start
    # Visit http://localhost:3000

๐Ÿ”ฅ Key Features

  • Zero Latency: Real-time sync via Firebase Firestore.
  • Cross-Platform: Works on any modern browser (iOS, Android, Windows, macOS).
  • Smart Fallback: Automatic localStorage mode for testing on a single device.
  • Responsive Design: Custom-built touch joystick for mobile controllers.

Made with โค๏ธ for the retro gaming community.
Feel free to โญ star this repo if you enjoyed the game!

About

๐Ÿ A modern Snake game with cross-device multiplayer - play on desktop with mobile controller via Firebase

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors