+ case GameSession::ES_GAME_OVER:
+ {
+ level_finished = false;
+ /* draw an end screen */
+ /* in the future, this should make a dialog a la SuperMario, asking
+ if the player wants to restart the world map with no score and from
+ level 1 */
+ char str[80];
+
+ DrawingContext context;
+ context.draw_gradient(Color (200,240,220), Color(200,200,220),
+ LAYER_BACKGROUND0);
+
+ context.draw_text_center(blue_text, _("GAMEOVER"),
+ Vector(0, 200), LAYER_FOREGROUND1);
+
+ sprintf(str, _("SCORE: %d"), player_status.score);
+ context.draw_text_center(gold_text, str,
+ Vector(0, 230), LAYER_FOREGROUND1);
+
+ sprintf(str, _("COINS: %d"), player_status.distros);
+ context.draw_text_center(gold_text, str,
+ Vector(0, screen->w - 32), LAYER_FOREGROUND1);
+
+ context.do_drawing();
+
+ SDL_Event event;
+ wait_for_event(event,2000,5000,true);
+