First, there's a bit of terminology to get down. The term "game engine" is used in two different contexts in this game. In one sense, it comprises all of the source modules that you've seen in other summaries. In a narrower sense, we use game engine to refer to the event queue that controls the pace and progress of the game. This summary focuses completely on the event queue and how it controls the game.
The engine uses a priority queue as its core. By now, you should have learned about priority queues and several possible implementations. The priority queue is part of the game library, thus we don't know the implementation. We do however know enough information that we can extend the priority queue structure to do more things. This is exactly what we do.
The events module defines a subclass of <keyed-object> that also holds a thunk in addition to the key. Using these together, the game engine holds a group of events which are just a time, which we use as a key, and the thunk which executes an event. You are reminded that a thunk is simply an argumentless function.
So, along with the event queue, the engine has a timer. The engine repeatedly checks the queue, comparing the key to the current time. If the next event in the queue is set to execute after the current time, the event is left in the queue and we wait a little longer. If the next event matches the current time, then we remove it from the queue and execute the thunk. The thunk may have anything it it, and it will usually be part of some loop.
So, the game engine has two functions that interface with it. These are insert-event and insert-immediate-event. Look at the engine interface for details on their arguments. The first function takes a number and a thunk, and creates an event out of it such that the event will come up at the current time plus the number passed in.
As you may recall, in a side-effect free world, we just call the function from within the body of the function. We have to use a little variation on that concept by using insert-event rather than just calling the function again. There is one general event loop in the source code that covers the animate's event loop. This is a valuable example, and useful for the weather problem you will be solving.