Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How to check if text is lower than 110 seconds?

I have a text label that displays a timer and I would like to check whether the timer has reached below 110 seconds this is my script to play a tween if the timer is below 110.

if TimerLabel.Text < "110" then
tween:Play()
else
print("timer is not under 110 seconds")
end

1 answer

✓ Accepted answer
if typeof(tonumber(TimerLabel.Text)) == 'Number' then
	if tonumber(TimerLabel.Text) < 110 then
		tween:Play()
	else
		print('timer is not under 110 seconds')
	end
end

2 comments

0

thanks for the help

0

yk you can just do if tonumber(TimerLabel.Text) then instead of if typeof(tonumber(TimerLabel.Text)) == 'Number' then

This discussion is preserved as it was. New answers, comments, and votes are closed.