React 360 input events

In order to make the game interface interactive, we will utilize some of the input event handlers exposed in React 360. Input events are collected from mouse, keyboard, touch, and gamepad interactions, and also with the gaze button click on a VR headset. The specific input events we will work with are the onEnter, onExit, and onClick events.

  • onEnterThis event is fired whenever the platform cursor begins intersecting with a component. We will capture this event for the VR objects in the game, so the objects can start rotating around the Y-axis when the platform cursor enters the specific object.
  • onExitThis event is fired whenever the platform cursor stops intersecting with a component. It has the same properties ...

Get Full-Stack React Projects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.