For my game, I created a custom hotbar to display the player’s tools. It centres the tools to the along the middle of the “hotBar” frame.
My personal cell phone is a Samsung Galaxy S20 FE (2400px, 1080px), so to test how the menu would appear on mobile, I inserted those dimensions into studio & tested the UI, it rendered normally as it should:
I’ve already tried setting “IgnoreGuiInset” to True in the properties of the Parent ScreenGui yet the problem persisted.
That being said, what is the solution to fix this bug? I believe it may be unique to phones as when I played it on my desktop PC using the non-Windows app I didn’t face this issue. Same for on my Lenovo Yoga in tablet mode, despite loading in with touch controls, I didn’t face the same problem either. That being said, what about physical cell phones makes the UI center itself bizarrely & what can I do to resolve this issue?
It could maybe be the anchor point. Try changing the anchor point to 0.5, 1 on your main frame and reposition it. Unless you’ve already done stuff with the anchor point, this might fix it.
It could also be that you are using offset instead of scale on your gui elements.
If you are already doing that and it doesn’t work, also try to set the ScreenInsets property of your ScreenGui to None. (Not sure if this will work, or cause other problems, so this is just a guess)
If none of this works, and all the other ideas that people had doesn’t work, it would help if we had some more details, like the properties and stuff which is what @hellie_jellie was saying.
As another update, I made a temporary change to show the absolute position of the items in the number so I can “print” it on my phone. This is what I got:
I replaced the UIGridLayout with a UIListLayout, using the same statistics & it worked, I believe it may have had something to do with the way I setup the sizing of the Frame that was being copied. The Frames that were being used as a template to be copied & hold items were of Size = {0, 55, 0, 55}, relying on the UIGridLayout to resize instead. The bug has been patched though & elements are now being centered properly as they are supposed to.