Skip to content

Commit

Permalink
docs: add readme and rename scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
erics118 committed Jun 9, 2024
1 parent 305cc73 commit c7dc5cf
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 6 deletions.
41 changes: 41 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,44 @@
# diep-clone

A clone of the diep.io game made with colyseus.js and phaser.js

## How to play

Move with WASD or arrow keys, press or hold SPACE to shoot.
Play with other people on the same local network as you.
Goal: survive and kill other players.

## How to run

### Development

- Server
- Run server `npm run start:server`
- Client
- Run client `npm run start:client`

### Production

- Server
- Build server `npm run build:server`
- Run server `npm run start:server:prod`
- Client
- Build client `npm run build:client`
- Run client `npm run start:client:prod`

<details>
<summary>

## Dev Cheats

</summary>

- `K` to increase speed to 2.5x
- `O` to increase bullet speed to 2x
- `P` to increase have infinite bullet damage
- `L` to have infinite health
- `I` to be invisible
- `J` to reload at tick speed
- `0` to disable joins

</details>
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@
"serve": "^14.2.3"
},
"scripts": {
"start-server": "tsx watch src/server/index.ts",
"start-client": "parcel serve public/client.html",
"build-server": "rimraf lib && tsc",
"build-client": "rimraf dist && parcel build public/client.html",
"server": "node lib/server/index.js",
"client": "serve dist",
"start:server": "tsx watch src/server/index.ts",
"start:client": "parcel serve public/client.html",
"build:server": "rimraf lib && tsc",
"build:client": "rimraf dist && parcel build public/client.html",
"start:server:prod": "node lib/server/index.js",
"start:client:prod": "serve dist",
"clean": "rimraf lib && rimraf dist",
"format": "biome format --write ./src",
"lint": "biome lint ./src",
Expand Down

0 comments on commit c7dc5cf

Please sign in to comment.