how to do some processing at set time intervals

BlitzMax Forums/BlitzMax Programming/how to do some processing at set time intervals

if your function doesn't need to be called at exact to the millisecond precision, you could just check the millisecs() timer in your main loop and call the routine from there.
Local Time:int = Millisecs() + 1000 ' one second later

While Not KeyHit(KEY_ESCAPE)
   If Millisecs() >= Time 'Check if second is up
      Time :+ 1000 'add another second to time
      DoFunction()
   End If
Wend