Search Unity

Bug BUG? New Blank Scene Has Game Random Game Objects in it?

Discussion in 'Editor & General Support' started by Immersive-Matthew, Jan 26, 2022.

  1. Immersive-Matthew

    Immersive-Matthew

    Joined:
    Mar 24, 2020
    Posts:
    137
    I have run into a very odd issue where I create a new fresh/blank scene, but instead of getting a Directional Light and a Main Camera, I get object(s) from other scenes? See the short video. This was not happening until tonight, that said, I have had A LOT of async load issues which perhaps is related. Specifically scenes suddenly taking an extraordinarily long time to load with only one way so far to resolve that I stumbled on. Simply, I create a new, fresh scene and then copy over the objects from the scene that takes a long time to load into the new one. This somehow solves the slow load even though the scene contents are exactly the same as before and I even rename the new scene to match the slow broken one. That is working fine, but new problem scenes keep popping up randomly like a game of whack-a-mole and now on top of that I cannot even get a fresh scene as it always behaves like this video. Seems sketchy and hints at something bigger going on here. Sometimes a new scene will have just one game asset object, sometimes several. What on earth is going on here? Bug? I am going to perform a library reimport overnight and see if that solves this issue. Love to hear your thoughts here. Might be a support ticket. Unity 2021.1.17f1 https://drive.google.com/file/d/1E3NplyN0WwTGjeuFGtr18VvhWn8xieA6/view?usp=sharing
     
    Last edited: Jan 26, 2022
  2. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,742
    Check your scene templates. You can set those up to contain whatever you like.
     
  3. Immersive-Matthew

    Immersive-Matthew

    Joined:
    Mar 24, 2020
    Posts:
    137
    Scene templates are somehting I have never touched nor knew anout. This said a reimport fixed and now it is behaving as it should again. Any idea what happened?
     
  4. Immersive-Matthew

    Immersive-Matthew

    Joined:
    Mar 24, 2020
    Posts:
    137
    SOLVED: You all will not believe the issue especially since I could find any mention of this anywhere. It was the skyboxes. I had skyboxes in many scenes (due to duplicating some of them during their creation) and while they do not change the sky in the Player or on the Quest when you async load the scene (which I am really unsure why) they must still have an impact in the load process, especially for heavier scenes that are already pushing the Quest. To fix, I "Set Active Scene" for each scene and then deleted it's skybox as I already set them elsewhere with code in strategic spots in my title. Once I did that all went back to perfect 72FPS without a single hiccup.



    This explains why creating a new scene and copying the contents of an offending scene fixed the issue as a new scene has the default skybox which is a much lighter skybox than my others ones. This is also why when I created that fresh scene another scene would start acting up as the 2 scene shared the same skybox and hence when I fix one, the next one after is now the first to load that skybox in memory. No wonder I felt like I was playing Whack-A-Mole! GOSH...this was a hard one to detect. I spent many hours pouring over the various anlysis tools and performing untold trial and error builds, but the problem was very evasive especially since you never see the sky change. I cannot believe it was the Skybox for all these months. I encourage you to even delete the default skybox on a new async scene as even they have a small impact. I hope this solution helps others and prevents
     
    Kurt-Dekker likes this.