clean: respect es11

This commit is contained in:
2024-02-20 09:22:11 +01:00
parent 54ef19a340
commit c143d96443
36 changed files with 163 additions and 163 deletions

View File

@ -1,6 +1,6 @@
import { sleep } from "../../utils/sleep.js";
import { Ball } from "./Ball.js";
import { GameConfig } from "./GameConfig.js"
import { GameConfig } from "./GameConfig.js";
import { Player } from "./Player.js";
import { Time } from "./Time.js";
import { Wall } from "./Wall.js";
@ -150,7 +150,7 @@ class Game
if (data.detail === "update_paddle")
this._receive_update_paddle(data);
else if (data.detail === "update_ball")
this._receive_ball(data)
this._receive_ball(data);
else if (data.detail === "init_game")
this._init_game(data);
}
@ -160,7 +160,7 @@ class Game
/**
* @type {Ball}
*/
this.ball = (new Ball(this)).from_json(data.ball)
this.ball = (new Ball(this)).from_json(data.ball);
/**
* @type {[Wall]}
@ -174,7 +174,7 @@ class Game
/**
* @type {[Player]}
*/
this.players = []
this.players = [];
const players_data = data.players;
players_data.forEach((player_data) => {
this.players.push(new Player(this).from_json(player_data));
@ -216,4 +216,4 @@ class Game
}
}
export { Game }
export { Game };