Why does disabling mobile touch input not work?

I want to disable the jump button and move button on mobile but it doesn’t work.
Here’s the code that I put in a LocalScript in StarterPlayerScripts:

local UIS = game:GetService("UserInputService")
repeat wait() UIS.ModalEnabled = true until UIS.ModalEnabled == true 
print(UIS.ModalEnabled)

Strangely, the script still prints true. Any solutions?

This worked for me.

local player = game.Players.LocalPlayer

local PlayerModule = require(game.Players.LocalPlayer.PlayerScripts:WaitForChild("PlayerModule"))
local Controls = PlayerModule:GetControls()
Controls:Disable()

repeat wait() until player.PlayerGui:FindFirstChild("TouchGui") and player.PlayerGui.TouchGui.TouchControlFrame:FindFirstChild("JumpButton")
player.PlayerGui.TouchGui.TouchControlFrame:FindFirstChild("JumpButton").ImageTransparency = 1

ModelEnabled is behaving differently, not quite sure why

Info on the upcoming fix (link updated):