Skip to content

A fun multiplayer browser-based online spaceship-themed game using React, Node.js, Firebase and Websocket.

License

Notifications You must be signed in to change notification settings

ziliHarvey/Online-Spaceship-Battle-and-Hunting-Game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spaceship Battle and Hunting!

A fun multiplayer browser-based online spaceship-themed game using React as frontend, Node.js as backend, Firebase as cloud database and SockJS for realtime communication. We also used redux-firestore for accessing data easily.

Features

         In this game, user can register and log in and create customized personal profile (including avatar, bio and spaceship color) and check other player's profile.
         Hunt: user plays himself and try to hunt as many points as possible in one minutes by getting fuels and shooting asteroids through basic keyboard control.
         Battle: user joins game with another player and try to beat each other in one minute.

Install and Run

git clone https://github.com/ziliHarvey/Online-Spaceship-Battle-and-Hunting-Game  
cd Online-Spaceship-Battle-and-Hunting-Game/  

Build your own firebase (Cloud Firestore option) instance and configure firebase apikey in store.js as firebase config setup instructed.
Be sure to add a waitingRoom collection with one document of boolean field gameIsOn, string field id1, id2, player1 and player2.

npm install  
npm start

Open another terminal to launch websocket server

cd Online-Spaceship-Battle-and-Hunting-Game/src/websocket/  
node server.js

And enjoy!

Contributors

Zi Li    Tianyi Xie

Reference

http://codepen.io/bungu/pen/rawvJe
https://github.com/chriz001/Reacteroids
https://www.udemy.com/react-front-to-back
https://truongtx.me/2014/06/07/simple-chat-application-using-sockjs

About

A fun multiplayer browser-based online spaceship-themed game using React, Node.js, Firebase and Websocket.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published