Skip to content

Commit

Permalink
Update InitCommon.js
Browse files Browse the repository at this point in the history
  • Loading branch information
erichlof authored Dec 1, 2023
1 parent 27e11ef commit e2cdd07
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion js/InitCommon.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ let cameraRecentlyMoving = false;
let isPaused = true;
let oldYawRotation, oldPitchRotation;
let mobileJoystickControls = null;
let mobileShowButtons = true;
let mobileUseDarkButtons = false;
let oldDeltaX = 0;
let oldDeltaY = 0;
Expand Down Expand Up @@ -192,7 +193,7 @@ function onWindowResize(event)
pathTracingUniforms.uVLen.value = Math.tan(fovScale);
pathTracingUniforms.uULen.value = pathTracingUniforms.uVLen.value * worldCamera.aspect;

if (!mouseControl)
if (!mouseControl && mobileShowButtons)
{
button1Element.style.display = "";
button2Element.style.display = "";
Expand Down Expand Up @@ -481,6 +482,7 @@ function initTHREEjs()
{
mobileJoystickControls = new MobileJoystickControls({
//showJoystick: true,
showButtons: mobileShowButtons,
useDarkButtons: mobileUseDarkButtons
});
}
Expand Down

0 comments on commit e2cdd07

Please sign in to comment.