Is there any event for UIbutton double-click detection on mobile?

Hi there.
I am making a game playable on both PC and mobile and met a fault(maybe bug) when scripting for button activated event.
The event works with printing 0 at first and then more than 0 while clicking rapidly on PC.
However unfortunately, clickcount seems no work properly as shown on moblie no matter how fast I click in the studio simulate env, or touch it on a real moblie.
image
on PC:
image
on mobile:
image

Though the requirement can be achieved by detecting the diff of time, I am still wondering if there is any other events or solutions for detecting double-click on moblie.
I have no found any other topic related to it yet.
I am grateful if there is any suggestion.

There isn’t an event for detecting double clicks but you can use timing to detect when a button is clicked twice in quick succession.

local Script = script
local Button = Script.Parent

local Time = 0

local function OnActivated()
	local ClickTime = os.clock()
	if ClickTime - Time < 0.1 then --Change '0.1' here.
		print("Button was double clicked.")
	end
	Time = ClickTime
end

Button.Activated:Connect(OnActivated)
1 Like

Sure that`s the way I have mentioned as per detecting the diff of time. What I request is that if there is any other ways or events that activating for double click checkable, cause it is actually weird if the event works for moblie but with ‘false’ param.
By the way, I am appreciated for you kindness help.