mirror of
https://github.com/tobspr/shapez.io.git
synced 2024-10-27 20:34:29 +00:00
fix jumps with desiredCenter
This commit is contained in:
parent
2f6b3afbab
commit
785f20c35f
@ -514,6 +514,7 @@ export class Camera extends BasicSerializableObject {
|
||||
if (mousePosition) {
|
||||
const worldPos = this.root.camera.screenToWorld(mousePosition);
|
||||
let de = worldPos.sub(this.center);
|
||||
this.desiredCenter = null;
|
||||
this.center = this.center.add(de.multiplyScalar(delta));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user