Question by
DaresFireson · May 05, 2019 at 08:03 PM ·
c#scenescene-loadingfadeout
[SOLVED]Problems loading the scene
i have the same scene fader script which is working for every other game but I don't think it have any issues. The problem is when I need to pass to the next scene it happen like in the picture
the code which load the scene is:
if(col.tag == "EndLevel")
{
Destroy(col.gameObject);
score += 1000;
PlayerPrefs.SetInt("Score", score);
if(score > bestScore)
{
PlayerPrefs.SetInt("BestScore", score);
}
sceneFader.FadeTo(nextScene);
return;
}
Anyone have any idea why this is happening ? I use the latest Unity Engine 2019.1.1
scene.png
(200.6 kB)
Comment
Best Answer
Answer by DaresFireson · May 07, 2019 at 12:59 PM
It seems I had to create 2 bools and return out of the function when they where true
Your answer
Follow this Question
Related Questions
Cannot interact with new scene 0 Answers
How do i create a scene variable? 3 Answers
Script is detecting input with ZERO actions 0 Answers
[SOLVED] How to load next level? 0 Answers
Get current scene number 3 Answers