Fix: moveRivers() -> moveLogs() Aufruf

This commit is contained in:
2026-04-18 19:18:19 +02:00
parent 288d5f5734
commit 2f43727ffa

View File

@@ -284,6 +284,15 @@
});
}
// Bäume bewegen
function moveLogs() {
logs.forEach(log => {
log.x += log.speed * log.direction;
if (log.x < -200) log.x = canvas.width;
if (log.x > canvas.width) log.x = -200;
});
}
// Aligatoren bewegen
function moveAlligators() {
alligators.forEach(alligator => {
@@ -295,15 +304,6 @@
});
}
// Bäume bewegen
function moveLogs() {
logs.forEach(log => {
log.x += log.speed * log.direction;
if (log.x < -200) log.x = canvas.width;
if (log.x > canvas.width) log.x = -200;
});
}
// Kollisionserkennung
function checkCollisions() {
// Aligatoren