❗️ This project has been moved to Rivet's example repo.
Microgravity.io is a web game where the player is tasked with building a space civilization. The player must mine resources, build defenses, fabricate weapons, join alliances, and attack enemies to stay on the top of the leaderboard.
While the development of Microgravity has been minimal recently, there has been interest from the community to crowdsource the development of new features.
This open-source copy of Microgravity is not built to be distributed, since the live version of the game depends on matchmaking and deployment code which cannot be made open-source at the moment. If you need help running Microgravity on your own server, please file an issue.
- NodeJS v12+
- FFMPEG
- If you are on macOS or Linux, we recommend that you install with Homebrew by running
brew install ffmpeg
. - If you are on Windows, we recommended that you install with Chocolatey by running
choco install ffmpeg
in PowerShell with administrative privileges. - If you have trouble with this installation, please file an issue.
- If you are on macOS or Linux, we recommend that you install with Homebrew by running
- Make sure that the above software is installed correctly.
- Open a shell in the root directory of the project and run
npm run setup
.- This will install necessary dependencies, compile required assets, and build the client.
- If you have Nix installed, simply run
nix-shell
to install all of the above.
- The server can be run normally with
npm start
. - If you wish to have the server automatically restart every time you make a change, you can run the server with
npm run nodemon
. - Visit https://127.0.0.1:8080/ to play the game
- To run the development server, run
npm run serve
. - If you are building to deploy to production, run
npm run build:prod
.
- Run
npm run setup
. - Open a shell and run
npm run nodemon
. Keep this open. - Open another shell and run
npm run serve
. Keep this open. - Visit https://127.0.0.1:8080.
Microgravity is built to be deployed on Rivet. Rivet is in private beta at the moment, so we can't share the deploy process yet.
We would love to see what creative additions you all come up with for Microgravity! We recommend you fork the project and submit pull requests if you wish to see your changes be included in the live version of the game.