fix: add frame factor calculations
Deploy to GitHub Pages / deploy (push) Failing after 1m2s

This commit is contained in:
2026-06-26 22:23:47 +05:00
parent 0928eba0e3
commit ec01e1ce56
7 changed files with 42 additions and 26 deletions
+3 -3
View File
@@ -112,9 +112,9 @@ class Enemy {
}
update() {
this.y += this.speed;
this.pulse += 0.05;
if (this.flashTimer > 0) this.flashTimer--;
this.y += this.speed * frameFactor;
this.pulse += 0.05 * frameFactor;
if (this.flashTimer > 0) this.flashTimer -= frameFactor;
}
draw() {