Search Unity

Canvas does not show up in Scene View (UI Layer is set to visible)

Discussion in 'UGUI & TextMesh Pro' started by Auticus, Jun 27, 2022.

  1. Auticus

    Auticus

    Joined:
    Jul 18, 2013
    Posts:
    99
    Attached gif shows what I perceive to be the bug.
    Game shows a health bar that I have added to a canvas (an image with a slider control on it).
    Scene view - it disappears.

    When game is stopped same thing. I cannot position elements on the Canvas because I cannot see them and have to use game mode while running to try to guess where things should go.

    Canvas:
    upload_2022-6-26_22-24-52.png

    The only fix I can find on google is to make sure the layers are visible, and all of my layers are visible.

    Expected Behavior
    When I add a canvas to my hierarchy, that I see a rectangle on the scene view and I can add elements to that canvas which immediately display so that I can position them.

    Unity Version: 2021.3.2f1
     

    Attached Files:

  2. JuliaP_Unity

    JuliaP_Unity

    Unity Technologies

    Joined:
    Mar 26, 2020
    Posts:
    700
    The Canvas shows up "separately" from the 3D objects. Have you tried selecting the Canvas on your Hierarchy View, moving the mouse over the scene view without clicking anything, and then clicking "F" on your keyboard? That would focus the Canvas there and help you find it, then you can navigate around to help you use it better as it's laid out in a weird way if you're not used to it. You can also use the "2D" toggle on your Scene View to help you work on your UI :)
     
    xKumei likes this.
  3. Auticus

    Auticus

    Joined:
    Jul 18, 2013
    Posts:
    99
    Thank you for your reply Julia. Indeed if I hit "F" it takes me to a point far off well beyond where my game is and my UI appears to be there.

    I have never had it do this before in several projects, the overlay usually will just appear where I need it over my screen since its defined as a Screen Space Overlay.

    Is there a good way to bring it down onto my actual scene instead of having it 10,000 units above? This is probably how its always been and I have just been lucky to have the UI not be located this far from my scene before so this threw me.

    The 2D did not do anything for me.
     
    Last edited: Jun 27, 2022