Scale vs offset
UDim2.new(xScale, xOffset, yScale, yOffset) mixes two units. Scale is a fraction of the parent's size, so 0.5 always means half. Offset is fixed pixels, so a 480-pixel-wide frame fills most of a phone screen but only a quarter of a PC screen. Use scale for size and position, then add a UIAspectRatioConstraint so squares stay square.
Tips
- Set
AnchorPointto (0.5, 0.5) and position to (0.5, 0.5) to center anything. - Remember that phones also have the Roblox top bar and on-screen controls, so leave some space around the edges.
- Use Studio's Device Emulator (in the Test tab) to check your UI on different devices.