snake: move extraneous logging to debug

This commit is contained in:
Trianta 2024-11-05 21:23:34 -06:00
parent de80157f2e
commit 33d5c491c2

View File

@ -81,7 +81,7 @@ class SnakeCore {
}
reset() {
console.log("[LOG] Reset was triggered");
console.debug("[TRACE] Reset was triggered");
this.gameover = false;
this.foodAte = true;
for (let i = 0; i < this.height; i++) {
@ -105,6 +105,7 @@ class SnakeCore {
foodRegen() {
if (!this.foodAte)
return;
console.debug("[TRACE] Food reset was triggered");
this.foodAte = false;
while (true) {
let tmp = new Point(Math.floor(Math.random() * this.width), Math.floor(Math.random() * this.height));