#include "gamestate.h" GameState::GameState(stack* state_stack, SDL_Surface* display) { this->state_stack = state_stack; this->display = display; init_done = false; } void GameState::execute() throw(StateExit) { SDL_Event event; while(SDL_PollEvent(&event)) handle_event(&event); iterate(); render(); } void GameState::on_exit() { throw StateExit(); }