Update README.md

This commit is contained in:
StevenJoeZhang committed 2019-05-23 16:19:59 +08:00
1 parent 0abbd33cfa
commit 71075a53cf
3 files changed
+14 -9

No files matched your search

+12 -8
View File
@@ -1,14 +1,21 @@
# Paper.IO
This is a clone of the original Paper-IO released by Voodoo, except for one aspect. This will attempt to implement a multi-player aspect of the game (like a real IO game). Currently this has a playground at this [link](https://thekidofarcrania.github.io/BlocklyIO). It's a demo version of what to come. Hopefully by that time, the necessary server infrastructure could be obtained.
> This is a clone of the original Paper-IO released by Voodoo, except for one aspect. This will attempt to implement a multi-player aspect of the game (like a real IO game). Currently this has a playground at this [link](https://thekidofarcrania.github.io/BlocklyIO). It's a demo version of what to come. Hopefully by that time, the necessary server infrastructure could be obtained.
This is just a fun side-project for me. If you would want to use this code, it would be nice to let me know.
> This is just a fun side-project for me. If you would want to use this code, it would be nice to let me know.
## Screenshots
![Screenshot](screenshot.png)
## Install
```bash
# Clone this repository
git clone https://github.com/stevenjoezhang/paper.io.git
# Go into the repository
cd paper.io
# Install dependencies
npm install
```
@@ -22,7 +29,7 @@ npm start
You can configure the game by editing `config.json`.
**WARNING: Remember to BUILD AGAIN after editing ANY FILE, INCLUDE `config.json`.**
**WARNING: Remember to build again after editing any file, include `config.json`.**
## Build
@@ -51,9 +58,6 @@ node bot.js ws://localhost:8080
## License
This is licensed under MIT. As such, please provide due credit and link back to this repository if possible.
This repo is forked from [BlocklyIO](https://github.com/theKidOfArcrania/BlocklyIO) by theKidOfArcrania.
Original Repo:
- Author: theKidOfArcrania
- Link: https://github.com/theKidOfArcrania/BlocklyIO
> This is licensed under MIT. As such, please provide due credit and link back to this repository if possible.
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

+2 -1
View File
@@ -225,7 +225,7 @@ function gridSerialData(grid, players) {
function findEmpty(grid) {
var available = [];
for (var r = 1; r < grid.size - 1; r++)
for (var r = 1; r < grid.size - 1; r++) {
for (var c = 1; c < grid.size - 1; c++) {
var cluttered = false;
checkclutter: for (var dr = -1; dr <= 1; dr++) {
@@ -241,6 +241,7 @@ function findEmpty(grid) {
col: c
});
}
}
return (available.length === 0) ? null : available[Math.floor(available.length * Math.random())];
}
module.exports = Game;