Hello developers! I am WEcompany currently working on mobile support in my game. I have a script that works perfectly well for phones.
local mobile = script.Parent.Parent:WaitForChild("TouchGui")
local mobileframe = mobile:WaitForChild("TouchControlFrame")
local jump = mobileframe.JumpButton
local thumbstick = mobileframe.ThumbstickFrame
jump.Position = UDim2.new(1, -140, 1, -90)
thumbstick.Position = UDim2.new(0, 100,1, -90)
jump.ImageColor3 = Color3.fromRGB(0, 255, 0)
mobileframe.ThumbstickFrame.OuterImage.ImageColor3 = Color3.fromRGB(0, 0, 0)
mobileframe.ThumbstickFrame.StickImage.ImageColor3 = Color3.fromRGB(0, 255, 0)
while wait() do
thumbstick.Position = UDim2.new(0, 100,1, -90) --This part is to make sure that it goes to this position after the player moves
end
Here is what it looks like on phone:
Perfect
Now going into the tablet emulator…
Uhh… What happened here?
If you can help me make a seprate UI for tablets, that would be great
Thanks in advance!WEcompany

