[SDL] Re: Game event loop and input

Calvin Spealman calvin at ironfroggy.com
Fri Jan 31 11:00:01 PST 2003

David Olofson wrote:
> In Kobo Deluxo, I'm using a generic game state class for this. When 
> you add a state to the game, you derive from a state class, override 
> handlers for events, video frames, game logic frames etc. The state 
> manager class has methods for switching and pushing states, so you 
> can either replace the current state with another state, or "call" 
> the another state, subroutine style.

This sounds like a very useful system and much like what I was thinking 
of doing in my project. Your way seems much better tho. I'm going to 
have to take a look at the kobo-deluxe source and see what i can learn.

More information about the SDL mailing list