Set of tools to load scenes and monitor its progress.
- Put the LoadScene script in a game object on your first scene.
- Enter the scene name you want to load.
- Tick the async checkbox if you want an asynchronous loading process
- Select OnStart if you want the load to be launched as soon as the game object is loaded and enabled in your scene.
- Select OnCall to disable auto load, and call the public StartLoading() method when you want to load the next scene.
- Select OnEvent so the load is done when the specified event is raised in your scene.
- Select OnSceneLoaded if you want the new load to be triggered as soon as this object detect a scene load.
- Put the LoadScene script in a game object on your first scene.
- Enter the scene name you want to load.
- Tick the async checkbox if you want an asynchronous loading process
- Select OnStart if you want the load to be launched as soon as the game object is loaded and enabled in your scene.
You can select OnCall to disable auto load, and call the public StartLoading() method when you want to load the next scene. Or you can select OnEvent so the load is done when the specified event is raised in your scene. Or select OnSceneLoaded if you want the new load to be triggered as soon as this object detect a scene load.
This manager allows to chain load multiple objects before starting to load the next scene. It is useful if you have heavy components to load and must be sure they are loaded one after another (like a translation file that must be loaded before showing them as tips for instance).
- Put the LoadingObjectManager in a game object on your scene.
- Add multiple components in the object list
- Set the LoadScene object.
Starting from the first, it will enable each GameObject attached to the component if not already. If the component implements the IShouldWait interface, it will yield until the component set the initialization as complete, otherwise it waits for the end of frame. Loop until all linked components are initialized. Wait for one last frame, then call the StartLoading function on the LoadScene linked object.
See the FourScenesTemplate project for a full demo of this easy loading package. More information will be share on my Medium profile.