Need Some Gui Animation Help!

I am trying to tween a Gui to a new position on the players screen, but on different size screens it tweens to a different spot, how do i fix this?

local Players = game:GetService("Players")
local Player = Players.LocalPlayer
local PlayerGui = Player:WaitForChild("PlayerGui")
local Main = PlayerGui:WaitForChild("MainUI")



local Open = false
Main.PhoneMain.PhoneToggle.MouseButton1Click:Connect(function()
	Open = true
	Main.PhoneMain:TweenPosition(
		UDim2.new(0, 10,1, -430),
		"Out",
		"Quad",
		.2,
		true
	)	
end)
Main.PhoneMain.OverlayContent.CloseButton.MouseButton1Click:Connect(function()
	Open = false
	Main.PhoneMain:TweenPosition(
		UDim2.new(0, 10,1, -10),
		"Out",
		"Quad",
		.2,
		true
	)	
end)
Main.PhoneMain.PhoneToggle.MouseEnter:Connect(function()
	if Open == false then
		Main.PhoneMain:TweenPosition(
			UDim2.new(0, 10,1, -20),
			"Out",
			"Quad",
			.2,
			true
		)	
	end
end)
Main.PhoneMain.PhoneToggle.MouseLeave:Connect(function()
	if Open == false then
		Main.PhoneMain:TweenPosition(
			UDim2.new(0, 10,1, -10),
			"Out",
			"Quad",
			.2,
			true
		)	
	end
end)




Try avoid using the offset values, because they move by pixels.
Screen Shot 2022-08-01 at 3.53.36 PM

One screen could have more pixels than another. Which explains why they move differently with screens with two different display sizes
Drawing-10.sketchpad

Use the scale values, its how many ‘percent’ of the screen it should move.
Screen Shot 2022-08-01 at 4.02.44 PM

Heres a plugin that may help with your issue, it converts the offsets into scale based on what the position it is on in your current studio screen :slightly_smiling_face: