Interacting with the AR environment
One of the ways that we can have the player interact with the world is by allowing them to spawn objects within the scene to help players see where items will spawn. We can create an indicator to show where they will actually spawn to. Let’s look at the steps to do just that:
- Create a quad using GameObject | 3D Object | Quad.
Quads represent a plane, the simplest type of geometry. In our case, we will use the quad as an indicator to the player where they will be spawning an object if they tap on the screen.
- With the quad selected, go to the Inspector window and go to the Transform component and set Position to
(0,0,0)
, X Rotation to90
, and Scale to(0.2,0.2,1)
.
We made the quad smaller to be 20 centimeters long and rotated it so it could represent a floor better. We do not want these values to change but we will eventually want to move and rotate this object to follow our player when they move the camera. To...