add new Gameplay func.
All checks were successful
Dynamic Branch Deploy / build-and-deploy (push) Successful in 1m59s
All checks were successful
Dynamic Branch Deploy / build-and-deploy (push) Successful in 1m59s
This commit is contained in:
BIN
static/assets/coin.png
Normal file
BIN
static/assets/coin.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 71 KiB |
BIN
static/assets/desk.png
Normal file
BIN
static/assets/desk.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 107 KiB |
BIN
static/assets/eraser.png
Normal file
BIN
static/assets/eraser.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 70 KiB |
BIN
static/coin.png
Normal file
BIN
static/coin.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 71 KiB |
@@ -25,7 +25,7 @@ function updateGameLogic() {
|
||||
if (player.y + originalHeight >= GROUND_Y) {
|
||||
player.y = GROUND_Y - originalHeight; player.vy = 0; player.grounded = true;
|
||||
} else { player.grounded = false; }
|
||||
|
||||
|
||||
|
||||
// 3. Obstacles
|
||||
let nextObstacles = [];
|
||||
|
||||
@@ -109,10 +109,12 @@ function drawGame() {
|
||||
if(bootTicks > 0) statusText += `👟 ${(bootTicks/60).toFixed(1)}s`;
|
||||
|
||||
// Drift Anzeige
|
||||
/*
|
||||
if (obstacles.length > 0 && serverObstacles.length > 0) {
|
||||
const drift = Math.abs(obstacles[0].x - serverObstacles[0].x).toFixed(1);
|
||||
statusText += ` | Drift: ${drift}px`;
|
||||
}
|
||||
*/
|
||||
ctx.fillText(statusText, 10, 40);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user