To begin our exploration of input mechanisms, let's set up our scene. The plan is to let players create balloons. Everyone loves balloons!
For this scene, you could start with a new scene (File|New Scene) and then add an XR Rig from the GameObject | XR menu. Instead, I've decided to start with the Diorama scene used in the previous chapter and remove all but the GroundPlane and PhotoPlane, as follows:
- Open the Diorama scene.
- Remove all the objects, except for XR Rig, XR Interaction Manager, Directional Light, GroundPlane and PhotoPlane.
- Position the XR Riga few feet from the scene origin, Position (0, 0, -1).
- Select File | Save Scene As and give it a name, such as Balloons.
Now that the scene stage is set, we are first going to define a balloon game object, make it a prefab, and add an empty controller object in the hierarchy and script that will instantiate the balloon prefab...