I’m trying to scale a UI frame for my game but it isn’t working correctly. Whenever I add an aspect ratio constraint it makes the frame not fit the full screen for different devices. I’m using scale not offset, but when I add an aspect ratio constraint it makes the frame not go down all the way. When I don’t add an aspect ratio constraint, it makes all of the UI stretched out so I can’t figure out how to add a constraint and make the frame fit the whole screen on all screens.
What if you set the UDim2 of the frame’s size you want to fill the whole screen with to {1,0},{1,0} (and position to just all 0 so that it starts in the top left)? The scale option usually goes from 0 to 1, 1 being the complete length of that screen’s side length.
That’s simply the way it works, UIAspectRatio will look different on other screens because they have different aspect ratios.
In this case you could set the frame size to {1, 0}, {1, 0} and instead add the UIAspectRatio constraints to the icons inside the frame, not the frame itself.
I’ll do this for the buttons and stuff but I have a panel on the side that goes up the full height of the screen and when I use a UIAspectRatio it doesn’t go all the way up and when I don’t the image gets stretched out and not in the correct location.