diff --git a/hampsterengine b/hampsterengine index 34d196b67f14040db020862d858b8e448ff639e3..e0227fba7aae15c8482dbed73947bb62c2350a48 160000 --- a/hampsterengine +++ b/hampsterengine @@ -1 +1 @@ -Subproject commit 34d196b67f14040db020862d858b8e448ff639e3 +Subproject commit e0227fba7aae15c8482dbed73947bb62c2350a48 diff --git a/src/js/objects/player.js b/src/js/objects/player.js index 3aefe7ecd824f67c7df322107dc0a0a3e0462727..594905541bf39315029fac9c7ac404a96ab73069 100644 --- a/src/js/objects/player.js +++ b/src/js/objects/player.js @@ -10,11 +10,11 @@ export default class Player extends Entity { draw() { canvas.setFillColor('red'); - const timeSinceLastFrame = (performance.now() - engine.lastPhysicsFrame) / 1000 / (query.get('slowdown') ? 60 : 1); - const interpolationX = this.vx * timeSinceLastFrame; - const interpolationY = this.vy * timeSinceLastFrame; + // const timeSinceLastFrame = (performance.now() - engine.lastPhysicsFrame) / 1000 / (query.get('slowdown') ? 60 : 1); + // const interpolationX = this.vx * timeSinceLastFrame; + // const interpolationY = this.vy * timeSinceLastFrame; // const interpolationX = 0; // const interpolationY = 0; - canvas.fillRect(roundToRatio(this.x+interpolationX),roundToRatio(this.y+interpolationY),this.width,this.height); + canvas.fillRect(roundToRatio(this.x),roundToRatio(this.y),this.width,this.height); } }