MixedRealityToolkit-Unity icon indicating copy to clipboard operation
MixedRealityToolkit-Unity copied to clipboard

Null reference exception when clicking on manipulation handler with gaze pointer

Open luis-valverde-ms opened this issue 7 years ago • 2 comments

Steps to reproduce the behavior:

  1. Open HandInteractionExamples scene
  2. Play scene with an Xbox controller connected
  3. Look at an object with a manipulation handler and press the A button in the controller
  4. Observe following error:
NullReferenceException: Object reference not set to an instance of an object
Microsoft.MixedReality.Toolkit.UI.ManipulationHandler.GetPointersVelocity () (at Assets/MixedRealityToolkit.SDK/Features/Input/Handlers/ManipulationHandler.cs:232)

This is happening because manipulation handler assumes that all pointers have a valid controller, which is not the case for the gaze pointer.

luis-valverde-ms avatar Apr 29 '19 15:04 luis-valverde-ms

You're right, not all pointers have controllers, but they all do have valid InputSources

StephenHodgson avatar Apr 29 '19 16:04 StephenHodgson

Fixed by #4118

luis-valverde-ms avatar May 01 '19 16:05 luis-valverde-ms