F
F
FC182019-10-23 19:58:54
Game development
FC18, 2019-10-23 19:58:54

Why doesn't the transition to another scene work?

Good day to all who read. The league of inepts is crying out for help
Cannot make the transition on the button to another scene. I don't understand where is the error
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class NewG : MonoBehaviour
{
public void NewGame()
{
SceneManager.LoadScene("S1");
}
}
The script was attached to the button

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Y
Yuri Kai, 2019-10-23
@FC18

Did you put the specified scene in Scenes in Biuld?
For starters, I would like to read the error log !!!

I
Ilya Rastorguev, 2019-10-24
@Ocugine

1) Attach your scene in the game's build options;
2) I recommend loading levels asynchronously. Learn Coroutine in Unity.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question