Hi I have a scene with just a camera animation. Its an end game cutscene so the user doesn’t interact. How can I load the next scene after the camera animation finishes. Ive tried the follow code and attached it to the camera but no luck.
{
void changescene ()
{
StartCoroutine (change());
}
IEnumerator change()
{
yield return new WaitForSeconds (8);
Application.LoadLevel (2);
}
}
Assuming the camera moves in the cutscene: If you have a way of knowing when the camera isn’t moving anymore, you can do the following
For example, in the update function:
newCamPos = mainCam.transform.position;
if (oldCamPos == newCamPos) {
cutSceneEnded = true;
}
if(cutSceneEnded) {
SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex + 1);
}
oldCamPos = newCamPos;
This loads the next scene once the camera stops moving. However, if the camera isn’t moving, and you have to wait several seconds, you need to try a different approach. Unfortuntaly I’m not that much of a pro on Unity, so I’m not 100% sure how to do that, but I’m sure someone else might. Hopefully you found this at least somewhat helpful.
Good day.
What verison of Unity are you using? now you load levels with SceneManager
Replcace
Application.LoadLevel (2);
for
SceneManager.LoadScene(2);
Rememebr to add this at the beggining of your script:
using UnityEngine.SceneManagement;
Bye! 
Ive figured it out I just replaced the void changescene with void start and it worked