Skip to content

Commit 2e46bb0

Browse files
committed
eslint and some screenshots
1 parent e65f0f0 commit 2e46bb0

File tree

4 files changed

+27
-13
lines changed

4 files changed

+27
-13
lines changed

README.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,19 @@ To run this game you need to start real minecraft server (by default it is 1.16.
3131
</details>
3232

3333

34+
<details>
35+
<summary>Linting</summary>
36+
37+
```bash
38+
#Only show whats wrong
39+
npm run lint
3440

41+
#Fix what is wrong
42+
npm run lint:fix
43+
44+
```
45+
46+
</details>
3547

3648
<details>
3749
<summary>Development setup </summary>
@@ -59,6 +71,8 @@ npm start
5971

6072
</details>
6173

74+
75+
6276
<details>
6377
<summary>Browser support</summary>
6478

@@ -70,6 +84,6 @@ It is preferred to run this game on [Google Chrome](https://www.google.pl/chrome
7084

7185

7286
## Screenshots
73-
[<img src="https://i.ibb.co/BLyct2H/Screenshot-from-2021-01-27-21-20-23.png" alt="screen6" width="100%">](https://i.ibb.co/BLyct2H/Screenshot-from-2021-01-27-21-20-23.png)
87+
[<img src="https://i.ibb.co/bPh99MV/hypixel.png" alt="screen6" width="100%">](https://i.ibb.co/bPh99MV/hypixel.png)
7488
[<img src="https://i.ibb.co/jzZVrT2/Screenshot-from-2021-01-27-21-13-37.png" alt="screen6" width="100%">](https://i.ibb.co/jzZVrT2/Screenshot-from-2021-01-27-21-13-37.png)
7589
[<img src="https://i.ibb.co/tKmnJ8D/Screenshot-from-2021-01-27-21-16-12.png" alt="screen6" width="100%">](https://i.ibb.co/tKmnJ8D/Screenshot-from-2021-01-27-21-16-12.png)

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"prebuild": "node src/prebuild.js",
99
"clean": "rimraf src/client/dist/*",
1010
"items": "node src/itemDump.js",
11-
"lint": "eslint --fix src/",
11+
"lint": "eslint src/",
1212
"lint:fix": "eslint --fix src/"
1313
},
1414
"dependencies": {

src/client/scripts/FirstPersonControls.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ FirstPersonControls = class FirstPersonControls {
66
constructor(game) {
77
this.game = game;
88
this.kc = {
9-
"KeyW": "forward",
10-
"KeyD": "right",
11-
"KeyS": "back",
12-
"KeyA": "left",
13-
"Space": "jump",
14-
"ShiftLeft": "sneak",
15-
"KeyR": "sprint",
9+
KeyW: "forward",
10+
KeyD: "right",
11+
KeyS: "back",
12+
KeyA: "left",
13+
Space: "jump",
14+
ShiftLeft: "sneak",
15+
KeyR: "sprint",
1616
};
1717
this.keys = {};
1818
this.setState("menu");

src/index.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -179,10 +179,10 @@ io.sockets.on("connection", function (socket) {
179179
}
180180
},
181181
move: function (state, toggle) {
182-
if(state==="right"){
183-
state="left"
184-
}else if(state==="left"){
185-
state="right"
182+
if (state === "right") {
183+
state = "left";
184+
} else if (state === "left") {
185+
state = "right";
186186
}
187187
bot.setControlState(state, toggle);
188188
},

0 commit comments

Comments
 (0)