GUI Buttons not responding to TouchEnabled devices

Hi there,

Most of the buttons have not been working for anyone with TouchEnabled devices. I haven’t been able to reproduce this issue on all but one of my mobile devices, so it seems like a model-specific issue.

The animations I have in place for the button work fine, however, it does not prompt the user to purchase the product.

PC and Console users have had no issues so far, but I’d like any input on how to get this fixed.

Here’s a sample of the code used for the animating portion

for _, Btn in next, Buttons:GetDescendants() do
    if Btn:IsA("ImageButton") then
        Btn.MouseEnter:Connect(function()
            -- insert code here
        end
        Btn.MouseLeave:Connect(function()
            -- insert code here
        end
        Btn.MouseButton1Down:Connect(function()
            -- insert code here
        end
        Btn.MouseButton1Up:Connect(function()
            -- insert code here
        end
    end
end

Here’s a sample of the code used for handling the purchase portion

GUIButton.InputEnded:Connect(function(Input)
	if Input.UserInputType == Enum.UserInputType.MouseButton1 and Input.UserInputState == Enum.UserInputState.End then
        -- insert code here
	elseif Input.UserInputType == Enum.UserInputType.Touch and Input.UserInputState == Enum.UserInputState.End then
        -- insert code here
	elseif Input.KeyCode == Enum.KeyCode.ButtonA and Input.UserInputState == Enum.UserInputState.End then
        -- insert code here
	end
end)

Figured it out, it was an issue with my ZIndex :sweat_smile:

I totally don’t work with UIs often enough to realize this