mirror of
https://github.com/lubosz/overte.git
synced 2025-08-07 20:06:02 +02:00
Make handControllerGrab independent of whether we're using laser or
Reticle.
This commit is contained in:
parent
0366c891cc
commit
526fc7d062
1 changed files with 4 additions and 1 deletions
|
@ -300,7 +300,10 @@ function propsArePhysical(props) {
|
||||||
// and we should not be showing lasers when someone else is using the Reticle to indicate a 2D minor mode.
|
// and we should not be showing lasers when someone else is using the Reticle to indicate a 2D minor mode.
|
||||||
var EXTERNALLY_MANAGED_2D_MINOR_MODE = true;
|
var EXTERNALLY_MANAGED_2D_MINOR_MODE = true;
|
||||||
function isIn2DMode() {
|
function isIn2DMode() {
|
||||||
return EXTERNALLY_MANAGED_2D_MINOR_MODE && Reticle.visible;
|
// In this version, we make our own determination of whether we're aimed a HUD element,
|
||||||
|
// because other scripts (such as handControllerPointer) might be using some other visualization
|
||||||
|
// instead of setting Reticle.visible.
|
||||||
|
return EXTERNALLY_MANAGED_2D_MINOR_MODE && (Reticle.pointingAtSystemOverlay || Overlays.getOverlayAtPoint(Reticle.position));
|
||||||
}
|
}
|
||||||
function restore2DMode() {
|
function restore2DMode() {
|
||||||
if (!EXTERNALLY_MANAGED_2D_MINOR_MODE) {
|
if (!EXTERNALLY_MANAGED_2D_MINOR_MODE) {
|
||||||
|
|
Loading…
Reference in a new issue