This commit is contained in:
2025-12-07 16:57:44 +02:00
parent c66fb58b9f
commit 02b29e920e
+1 -1
View File
@@ -228,7 +228,7 @@ class Hero{
let cameraPosition = new Vector3().copy(this.camera.position) let cameraPosition = new Vector3().copy(this.camera.position)
let cameraDesiredPosition = new Vector3( let cameraDesiredPosition = new Vector3(
this.model.position.x + this.#cameraZ* Math.sin(this.model.rotation.y + Math.PI + this.cameraDelta + this.cameraIdleDelta), this.model.position.x + this.#cameraZ* Math.sin(this.model.rotation.y + Math.PI + this.cameraDelta + this.cameraIdleDelta),
pc.controls.isLocked? this.size.y*0.9 : (this.cameraY + this.model.position.y), this.model.position.y + (pc.controls.isLocked? this.size.y*0.9 : this.cameraY),
this.model.position.z + this.#cameraZ* Math.cos(this.model.rotation.y + Math.PI + this.cameraDelta + this.cameraIdleDelta) this.model.position.z + this.#cameraZ* Math.cos(this.model.rotation.y + Math.PI + this.cameraDelta + this.cameraIdleDelta)
) )