I want to make a game with things like xbox support and mobile, but I want to make some GUIs appear only if I were on something like an xbox.
✓ ANSWER ACCEPTED
How can I make a gui appear if someone were on a different device?
2 answers
✓ Accepted answer
I made a simple script that detects if a player is on a mobile device using userInputService.TouchEnabled:
local userInputService = game:GetService("UserInputService")
if userInputService.TouchEnabled then
--user using a mobile device
Instance.new("Message", workspace) -- I think they removed it not sure
Message.text = "A Mobile Player Has Joined!"
else
--they are on a different device
end
you would actually have to check the properties of UserInputService..
such as UserInputService.KeyboardEnabled to check if a player has a keyboard(is on computer), and TouchEnabled to check if they are on a mobile device/touch screen device..
1 comment
0
Thank you very much!
This discussion is preserved as it was. New answers, comments, and votes are closed.

3 comments
good for u
https://developer.roblox.com/en-us/api-reference/enum/Platform
oo nice