We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 34c7f6e commit 1957225Copy full SHA for 1957225
Assets/MRTK/Core/Definitions/Devices/ArticulatedHandDefinition.cs
@@ -131,10 +131,9 @@ public bool IsInPointingPose
131
if (unityJointPoses.TryGetValue(TrackedHandJoint.Palm, out palmJoint))
132
{
133
Vector3 palmNormal = palmJoint.Rotation * (-1 * Vector3.up);
134
- if (cursorBeamBackwardTolerance >= 0)
+ if (cursorBeamBackwardTolerance >= 0 && CameraCache.Main != null)
135
136
- Vector3 cameraBackward = -CameraCache.Main.transform.forward;
137
- if (Vector3.Dot(palmNormal.normalized, cameraBackward) > cursorBeamBackwardTolerance)
+ if (Vector3.Dot(palmNormal.normalized, -CameraCache.Main.transform.forward) > cursorBeamBackwardTolerance)
138
139
return false;
140
}
0 commit comments