clock()
Note: The timer is reset to zero when pygame_functions is imported.
This can be used to ensure that a certain event happens at set intervals. eg.
targetTime = 0 while True: theTime = clock() if theTime>targetTime: targetTime = theTime + 2000 #this code should only happen every 2000 milliseconds
There was an error while loading. Please reload this page.