I want to make my first game optimized for most resolutions and aspect ratios (at least the most used ones) but If I try to size the backgrounds and ui for each resolution either it will be small and be filled out with blue color for bigger resolutions, or if its smaller it will be zoomed in. How can I make it to look normal without no filler color and no zoom in and outs?
I recently played the game bb racing mod apk and it has feature to play it on different resolutions. It was well optimized with sleek UI. You can use the source code of the game to take the idea.
Sorry I forgot to specify that Im making a pc game
If avoiding UI zoom is really what you want, play around with the settings of the components you find by default on the canvas. You can set things like absolute pixel size there.
It’s also worth learning how the “anchors” work in RectTransform as those can be used for a dynamicly zooming UI.
As for the main background, ideally you have an image for the widest resolution you want to support (probably 21/9) and use the camera port to crop for the screen (should happen by default).
Set your canvas to “scale with screen size.”
Are we talking UI Toolkit or uGUI here?