Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How can I make sure my gui is locked and stays in place on other res screens?

Asked by 7 years ago

I have been working on a game with a gui that has a button, above and under the button shows weather for the game etc. The weather and the button both move while playing on a different device/screen. Or simply resizing my window moves it. can someone help? thanks!

0
Use scale instead of offset for size/position and use text scaled in GUI objects that have text. Ultimate_Piccolo 201 — 7y

1 answer

Log in to vote
0
Answered by
Eqicness 255 Moderation Voter
7 years ago

In a GUI object, there are two values in the X and Y positions: Scale and Offset. The Offset is the position or size in Pixels of the GUI object, and the Scale is the Ratio of how much of the screen the position or size takes up. The Scale is relative to screen size and it should almost always be used if you want your game to look good on all computers. The Scale of a UDim2 value can be anything, but 1 is the size of the screen, so anything above 1 will be bigger than the screen.

For more information:

ROBLOX Wiki: UDim2

Ad

Answer this question