User prompt
add a 0 infront of every timer thats lower than 10 so 0 is 00 and 9 is 09
Code edit (5 edits merged)
Please save this source code
User prompt
add a 0 infront of every score thats lower than 10 so 0 is 00 and 9 is 09
Code edit (1 edits merged)
Please save this source code
User prompt
the location of scoretxt should be determend by coordinates
===================================================================
--- original.js
+++ change.js
@@ -105,9 +105,9 @@
size: 150,
fill: "#ffffff"
});
scoreTxt.x = 2048 / 2; // Center the score text horizontally
-scoreTxt.y = 100; // Position the score text 100 pixels from the top
+scoreTxt.y = 0; // Position the score text 100 pixels from the top
game.addChild(scoreTxt); // Add score display to the game
// Function to spawn targets
function startGame() {
gameEndTime = Date.now() + gameDuration; // Calculate game end time