Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How to set a gui to fit on all screens?

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

✓ Accepted answer

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.

2 comments

0

I can calibrate it from there is it?

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?

With UI's, in the .Size and .Position properties, you'll see them structured as a Udim2 value, 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.

4 comments

0
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

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!

This discussion is preserved as it was. New answers, comments, and votes are closed.