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

How to set a gui to fit on all screens?

Asked by
manith513 121
4 years ago

So this isn't really a coding problem but a User-Interface issue. I have a frame with anchor points at 0.5, 0.5, and have a lot of buttons to make a GUI for a button to claim something. I test the GUI out on multiple devices and when I try it on the smallest device possible (iPhone 4) it is cut off on the screen. I thought I was doing something wrong but I looked at somebody else on youtube making a game and did the exact thing I did with the frame and anchor point just with different text labels and buttons and his scaled-down when he switched devices. He wasn't using any plugins and it scaled to devices fine. Please help!

2 answers

Log in to vote
-1
Answered by 4 years ago

On The Frame Set The Size Type This 1,0,1,0 And It Should Set The Size Of The Frame To Fit The Whole Screen On All Platforms.

0
I can calibrate it from there is it? manith513 121 — 4y
0
Also, Something is wrong it works when ever I use a frame and make it the size with no offset and see it on other devices, but when I insert a text label or button and only use size settings, it goes somewhere out of the screen somewhere how do I calibrate it for other things like labels or text buttons? manith513 121 — 4y
Ad
Log in to vote
0
Answered by 4 years ago

With UI's, in the .Size and .Position properties, you'll see them structured as a Udim2value, being {xScale, xOffset, yScale, yOffset}

If you wanted to scale it to all screens, you'd use xScale and yScale. Setting a xScale/yScale value to 1 will size it to the whole screen. I wouldn't mess with offsets too much, exception being sizes in some cases.

Hope I helped you! For more information, check out this devforum post.

0
Here is how it looks on phone https://gyazo.com/e5719cf7ec7a5923cab820d2f0cc7645 manith513 121 — 4y
1
make sure your not using offset at all; this includes position and size. this is a good plugin: https://www.roblox.com/library/1496745047/AutoScale-GUI Hydrogyn 155 — 4y
0
I've used that plugin before I have it actually but the installation process is glitchy when I press download it doesn't install it jsut keeps the button on install and also I used to have it and it didn't really work because I really don't know how to use it. But Thanks for your Time! manith513 121 — 4y

Answer this question