Resolution problem when Build

Hi!
I’m working on Unity 2022.3 and I have a newbie problem that drives me crazy because I don’t even know how to search for a solution.

I developed an interface for more than 8 hours. Every little change I made I check and played it, and everything seemed to look fine.
So far there’s no game, all the scenes are menu pages (settings, credits, artwork, etc.).

After all, I decide to build all the scenes for Windows/Mac/Linux.

When I started the exe file I realized that the main screen was just the half of the monitor. It’s like my game is inside a huge frame (I think it’s a resolution-camera problem).
And one scene in particular, the one with some Panel in it, it’s totally deformed and the components in the panels seems scattered around the screen (I think it’s just a panel behaviour I didn’t understand).

Then I checked on Unity and I understand the difference between “Play focused” and “Play maximized”. :frowning:

That’s my questions about it:

  1. Is there any tutorial for understand scale, resolution and panel behaviour inside a scene for avoid this in the future?
  2. Can I make a build of just what I see in “Play focused”?

Thanks a lot and sorry if I made silly questions.

Here are the official docs on how to make your UI handle various resolutions and aspect ratios cleanly:

Here are some notes on UI Anchoring, Scaling, CanvasScaler, etc:

Usually you need to choose a suitable ScaleMode and MatchMode in the Canvas Scaler and stick with it 100%. Generally if you change those settings you will often need to redo your UI entirely.

I also use this CanvasScalerOrientationDriver utility to make sharing UI for Landscape / Portrait easier. Read what it does carefully.

1 Like