The ModalEnabled property toggles whether Roblox’s mobile controls are hidden on a player’s mobile device. The default value of this property is false. The controls are hidden when set to true, and not hidden when set to false. See the images below for examples.
This property can be used when you want to hide or display Roblox’s mobile controls for a player.
Even if mobile controls are hidden for a player on a mobile device, other UserInputService events such as
UserInputService/TouchSwipe can still be used to process other forms of user input on mobile devices with an enabled touch screen (see the main UserInputService class page for a full list).
UserInputService only runs client-side, this property will only work when used in a
The tutorial on disabling parts of the game interface, found here, provides excellent documentation on using this property.
This example toggles between hiding and showing the user’s Roblox mobile controls every 5 seconds.
local UserInputService = game:GetService("UserInputService") while true do UserInputService.ModalEnabled = not UserInputService.ModalEnabled wait(5) end