HTML game modes selector

+ pong.css in a separate file
This commit is contained in:
LuckyLaszlo
2022-12-06 01:56:39 +01:00
parent 7355a70821
commit 9dde821f67
11 changed files with 133 additions and 64 deletions

View File

@@ -1,7 +1,7 @@
import * as c from "./constants.js";
import * as en from "../shared_js/enums.js"
import { gc, clientInfo } from "./global.js";
import { gc, matchOptions, clientInfo } from "./global.js";
import { wallsMovements } from "../shared_js/wallsMovement.js";
let actual_time: number = Date.now();
@@ -28,7 +28,7 @@ function gameLoop()
ball.moveAndBounce(delta_time, [gc.wallTop, gc.wallBottom, gc.playerLeft, gc.playerRight]);
});
if (c.optionsPLACEHOLDER & en.MatchOptions.movingWalls) {
if (matchOptions & en.MatchOptions.movingWalls) {
wallsMovements(delta_time, gc);
}
}