Right Corner UI Positioning/Scaling Help!

So my friend and I are working on a game, and we have run into another UI problem that we tried multiple things to fix, but it won’t work. It is positioning a frame in the bottom right corner of the screen and keeping it scaled correctly. We have done stuff on the left side of the screen and it works perfectly fine, but the right side isn’t working! Here are some screen shots.

Screen Shot 2020-02-10 at 9.35.03 PM Screen Shot 2020-02-10 at 9.35.12 PM

If someone could help us find a solution that would really be helpful, as I have looked it up multiple times but cannot find anything either. Thank you!

1 Like

Offset it from UDim2(1,0,1,0). That point is the very point at the bottom right corner. In order to do this, you can either set the position with an offset, or change the anchor point. With an offset, say hypothetically if the frame is {(0.3,0),(0.2,0)}, then set the position to UDim2.new(0.7,0,0.8,0). Notice these values sum up to 1 on the scale part. I assume you want an offset from the corner, so you can also add -5 or -10 in the offset part of both x and y. This is fully up to your design and you to choose. The second way of doing this is to set the anchor point. It is one of the properties of a frame. Setting it to 1,1 will make it so the position is bound from the bottom right corner rather than the top left. In doing so, you can set the position to UDim2(1,0,1,0) and add an offset of -5 or -10 depending on what looks best. For example, with an anchor point of 1,1 you could set the position at UDim2.new(1,-10,1,-10). This would put it in the bottom right corner and add a 10 pixel offset gap in between the edges of the frame and edges of the screen. I hope this helps! If you don’t fully understand let me know, as I will try to rephrase it. Best of luck!

2 Likes

Thank you very much! I will tell my partner and we will try this.