startTimer()
Purpose
Start a timer
Description
Start a timer that has been stopped with stopTimer
Syntax
startTimer( handle )
Arguments
handle handle of the timer from settimer
Example
count = 10
handle = setTimer( 1, 11, showCount() )
stoptimer( handle )
loop
c = controls( 0 )
printAt( 0, 0, "Press A to start timer" )
if c.a then
startTimer( handle )
endIf
printAt( 0, 1, "Press B to stop timer" )
if c.b then
stopTimer( handle )
endIf
update()
repeat
function showCount()
clear()
textSize( 500 )
printAt( tWidth() / 2, tHeight() / 2, count )
textSize( 29 )
count -= 1
return void
Associated Commands