When an AdGui exists anywhere in the game that a client can access (eg. workspace, replicated storage) it causes TouchTap and TouchSwipe functions to never get triggered on UI elements, they do get triggered for UserInputService however the ‘GameProcessedEvent’ value is always true so for most people the code will return early to prevent clicks on the UI to be registered. (TouchTap is used in the ‘Tap to Move’ movement mode, so this will also be unusable for any games with AdGuis in)
This happens because when an AdGui is initiated on the client side it creates game:GetService(“CoreGui”).AdGuiInteractivityControls.AdsInteractivityControls.InteractiveArea, which is a TextButton that covers the whole screen. AdsInteractivityControls is a SurfaceGui so in theory this shouldn’t block the ‘Touch’ inputs, but it does.
This was first seen on the 7th of August, where it had made one of our building games unusable for mobile users as it used UserInputService.TouchTap for building (Solved by removing AdGuis)
SUB TITLE: Reproduction
Use these steps in a game with the following script, or in the place file attached
- Use the device emulator and set it to a mobile
- Play test and click around, wait 5s for the AdGui to be made, click around
- The output should have warnings when you click once the AdGui is created
game:GetService("UserInputService").TouchTap:Connect(function(input, gpe)
if not gpe then
print("TOUCH TAP wasn't consumed by game")
else
warn("TOUCH TAP was consumed by game")
end
end)
game:GetService("UserInputService").TouchSwipe:Connect(function(input, val,gpe)
if not gpe then
print("TOUCH SWIPE wasn't consumed by game")
else
warn("TOUCH SWIPE was consumed by game")
end
end)
task.wait(5)
local adGui = Instance.new("AdGui")
adGui.Parent = game.Workspace
print("\n\nAD GUI CREATED\n\n")
Posted on behalf of @silcon_Aamir, he will respond to any comments
TouchTapBreakingByAdGui.rbxl (53.0 KB)