Search Unity

[SOLVED] Hide Feature 2019.1.7 Can't unhide scene

Discussion in 'Editor & General Support' started by ManuelSegura, Jun 20, 2019.

  1. ManuelSegura

    ManuelSegura

    Joined:
    Dec 12, 2015
    Posts:
    19
    I have no idea if there is a way to do this quicker, but looks like it's not the case, so:

    When I click the hide button for a scene in the hierarchy, it hides all gameobjects, but if I click it again, they don't unhide! Am I really supposed to click all of them one by one? The only workaround I can see is creating a temporal gameobject, make it parent of all my objects, unhide that gameobject and unparent everything again. (If you have prefabs, there is a 50% chance it won't let you ?¿?¿)

    Please, wtf.
     
  2. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,299
    What version of 2019.1 are you using? It works for me
    . Jun-20-2019 19-59-58.gif
     
  3. ManuelSegura

    ManuelSegura

    Joined:
    Dec 12, 2015
    Posts:
    19
    We are using 2019.1.7f1. We are observing it only works for 2 of the 3 scenes we have in our game.
     
  4. dgoyette

    dgoyette

    Joined:
    Jul 1, 2016
    Posts:
    4,196
    I was pretty sure this was fixed under 2019.1.6 or 2019.1.7. I reported bug #1156127 on this a while back, and the underlying issue is that some object in the scene was using HideFlags to hide a game object (in my case, it was CineMachine using a hidden object), but this would happen if any game object in the scene was hidden via HideFlags. The SceneVisibility tool got confused by the HideFlags, it seems.

    Anyway, I was happy to see this wasn't happening for me anymore, so I figured it was fixed...
     
  5. ManuelSegura

    ManuelSegura

    Joined:
    Dec 12, 2015
    Posts:
    19
    We have never introduced (manually at least) HideFlags. Packages are as tidy as they can be and don't include Cinemachine.

    Capture.PNG

    Several restarts later I can confirm this bug is consistently happening in only one of the three scenes there are in the game. Removing every object does not solves the problem. Cloning the scene does not solves the problem. Any combination of both, same thing. It's looks like the bug is the scene itself.
     
  6. dgoyette

    dgoyette

    Joined:
    Jul 1, 2016
    Posts:
    4,196
    So you can delete everything from the scene, add a single Cube, and the issue is still happening?

    If you open that scene in a text editor, and search for "m_ObjectHideFlags", does it show anything? Any items with a value of "1" for m_ObjectHideFlags? I'm just wondering if some hidden object got created in your scene at some point, and now you can't see if to delete it.

    If not, then it sounds like this is unrelated to the similar bug I ran into.
     
  7. ManuelSegura

    ManuelSegura

    Joined:
    Dec 12, 2015
    Posts:
    19
    Just found there are 3 components with HideFlags enable.

    Capture.PNG

    I then edited the numbers to "m_ObjectHideFlags: 0" and reloaded scene via reload popout window.
    Then, I HAVE NO IDEA HOW, an enemy prefab appeared unhidden, while every other object were hidden.

    Capture2.PNG

    The enemy object isn't complete, it only have the transform and rigidbody, while the prefab have all kinds of additional things, lots of children and a whole different name (we changed it months ago from "Enemy 1" to "Enemy 1-HIT").

    At this point the bug was solved and having this weird enemy in the game have no effect at all.

    Thank you, dgoyette!
     
    dgoyette likes this.
  8. dgoyette

    dgoyette

    Joined:
    Jul 1, 2016
    Posts:
    4,196
    Cool. But I guess that means there are still issues with Scene Visibility and Hide Flags... I wonder why it started working for me recently.
     
  9. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,299
    dgoyette likes this.