The last object we need to create is a scene controller with an attached SceneController script. A Controller GameObject is often used as a repository for scripts that need to run but are not attached to any object. These scripts generally listen for specific actions (like those from a player) and manage multiple instances (like those generated by AI GameObjects) within a scene:
- Create an empty GameObject in the Hierarchy window and rename it Controller.
- Add a blank script to the Controller called SceneController. This will be our last script and like the ImageSelector we will modify it in the next chapter.
- Move the SceneController scripts into the Script folder.
- Save the scene and Unity ...