Search Unity

Is it normal if this... (Starting UI)

Discussion in 'UGUI & TextMesh Pro' started by Nigey, Aug 27, 2014.

  1. Nigey

    Nigey

    Joined:
    Sep 29, 2013
    Posts:
    1,129
    Is it normal if this?

    Example1.png
    becomes this when clicked...

    Example2.png

    Whenever I watch a tutorial when they first make a UI component with a canvas it snaps to the camera size. Mine isn't. I've tried the tutorial example projects in the Forum's top bit and they're working okay. It's only when I try and make one myself.
     
  2. Nigey

    Nigey

    Joined:
    Sep 29, 2013
    Posts:
    1,129
    And then from looking like this:

    Example3.png

    To looking like this, when I move the 'Game View' to the right, making it's overall screensize smaller.. ?

    Example4.png
     
  3. BeforeTheLight

    BeforeTheLight

    Joined:
    Jan 7, 2011
    Posts:
    168
    There are multiple posts on this already but to make your ui auto adjust like in the videos you need a ReferenceResolution component on the canvas. Then use anchors to make the elements stay relative to an area of the screen. I hope I understood your question and this helps.
     
  4. Nigey

    Nigey

    Joined:
    Sep 29, 2013
    Posts:
    1,129
    That's great, thanks BeforeTheLight. It seems pretty strange that they neither mention this in any of the tutorials I've seen (about 5), or that the ReferenceResolution isn't a component by default when created, like the Canvas. Perhaps something for Unity to think about on their final release I guess..

    All the same, works perfectly. Thanks
     
  5. BeforeTheLight

    BeforeTheLight

    Joined:
    Jan 7, 2011
    Posts:
    168
    Yes the video does appear to be on a version other than the beta released to the public but I did see somewhere that once unite is all squared away they will be doing a new video series. Glad it helped.
     
    Nigey likes this.