Hello friends,
I’m doing a question tipically of a noob. But I’m starting in the programming of games and in Unity3d too. I have to say this is awesome, but I have this problem, I can’t change the scene without delete the previous scene and their objects.
I have a Trigger in a location of the screen, and an event, the events makes change the scene when the mouse is pressed into the trigger, but when it happends, the scene changes but the colors and objects are mixed with the “current” scene. How can I fix it?
The code below is the same I have in the event (and using the same script in both scenes):
*Scene escenaActual = SceneManager.GetActiveScene();
string nombreDeEscena = escenaActual.name;
Debug.Log(nombreDeEscena);
if (nombreDeEscena == "scene2")
{
Application.Quit();
SceneManager.LoadScene("scene", LoadSceneMode.Additive);
}
else if (nombreDeEscena == "scene")
{
Application.Quit();
SceneManager.LoadScene("scene2", LoadSceneMode.Additive);
}*