The next thing we'll do is let you regenerate the anchor position of the solar system. The plan is when you touch the screen of your iPhone or iPad device, the app calculates a likely position you are indicating in real-world 3D coordinates. We'll move the root position there. We will do this with a script named SolarSystemHitHandler:
- In your Scripts folder, create a new C# script named SolarSystemHitHandler.
- Drag it to the SolarSystem object as a component.
- Then, open the script for editing as follows:
File: SolarSystemHitHandler.csusing System.Collections;using System.Collections.Generic;using UnityEngine;using UnityEngine.EventSystems;using UnityEngine.XR.iOS;public class SolarSystemHitHandler : ...