Many programmers try to avoid multi-threaded code, since it is highly bug-prone in imperative programming.
If you want to a scheduled task in a single-threaded environment, then you probably need some kind of "Reactor". You may want to use a ready-made one like Twisted's.
Then it would be a basic function provided by your reactor, for example (with pygame):
pygame.time.set_timer - repeatedly create an event on the event queue