Skip to content
Snippets Groups Projects
Commit 36d3f8d9 authored by joni's avatar joni
Browse files

Use locked head position value when locked.

parent 6a240034
No related branches found
No related tags found
No related merge requests found
......@@ -136,7 +136,7 @@ AFRAME.registerComponent("hud-detector", {
const EPSILON = 0.001;
this.isYLocked = t > 1 - EPSILON;
hud.position.y = (this.isYLocked ? head.position.y : this.lockedHeadPositionY) - offset - offset * (1 - t);
hud.position.y = (this.isYLocked ? this.lockedHeadPositionY : head.position.y) - offset - offset * (1 - t);
hud.rotation.x = (1 - t) * THREE.Math.DEG2RAD * 90;
// update the app mode when the HUD locks on or off
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment