Reference a scene via its asset instead of its name. It can also give suggestions based on it being null / not in build
More...
Reference a scene via its asset instead of its name. It can also give suggestions based on it being null / not in build
namespace Example
{
public class Game : ScriptableObject
{
[SerializeField] private SceneReference _scene;
public IEnumerator LoadGameAsync(Game currentGame)
{
yield return currentGame._scene.UnloadSceneAsync();
yield return _scene.LoadSceneAsync(LoadSceneMode.Additive);
}
}
}
>