So, I created gun gui for the ROBLOX gun system but I encountered an error when running in studio and in game. There seems to be a scaling issue where it completely doesn’t align with the frame at the expected position.
I’m trying to make it scaled properly on all screens.
In Studio
In Game
I scaled them correctly so I have no idea what the problem is.
Are you sure all of those UI elements are using the scale and not the offset? Just making the frame scale will not do the trick, each element has to use scaling position and scaling size to be automatically scaled properly.
Offset is purely just to offset from the scaling number in the math and will not scale.
My message popup as seen below uses scaling position and size on the frame and all 3 labels which allow it to be in the same place on any device.
Click here to see the scaling examples
In Studio (no emulation, viewport smaller due to properties window, etc)
If you have used the scaling property, make sure SizeConstraint is set to what you desire. Your scaling could be determined by both the width and height or either one due to this property.
Lastly make sure AutomaticSize is none UNLESS you want to use this scaling. What this property does is force UI objects to stretch to fit any excess text.
If your problem persists after this, please send screenshots of the UI values and (if you have made) any scripts that affect size and position.