Garry's Mod Wiki

timer.Remove

  timer.Remove( string identifier )

Description

Stops and removes a timer created by timer.Create.

The timers are removed in the next frame! Keep this in mind when storing identifiers in variables.

Arguments

1 string identifier
Identifier of the timer to remove.

Example

Creates a timer and then removes it

-- create timer timer.Create( "UniqueName1", 5, 1, function() print("inside") end ) -- remove timer timer.Remove( "UniqueName1" )