local Enter = script.Parent.Union.Enter local Rs = game.ReplicatedStorage local Gg = Rs.GameGuis local UIS = game:GetService("UserInputService") local GuiService = game:GetService("GuiService") Enter.Touched:Connect(function(plr) if (not plr.PlayerGui) then return end if (not plr.PlayerGui:FindFirstChild("Foods")) then if UIS.TouchEnabled and not UIS.KeyboardEnabled and not UIS.MouseEnabled and not GuiService:IsTenFootInterface() then local x = Gg.Drinks:Clone() x.Parent = plr.PlayerGui elseif UIS.KeyboardEnabled and UIS.MouseEnabled and GuiService:IsTenFootInterface() then local y = Gg.Foods:Clone() y.Parent = plr.PlayerGui end end end)
Is my code so far, However it isn't working. I need some help here..
Im trying to make it so, If someone has a touchscreen, BUT no keyboard / mouse input it selects one gui, However if it has a keyboard and mouse and no touchscreen then I want it to show another. (The gui names are just for testing).