From bf0cca2f391ed3e49b09933325b430c33cf59daf Mon Sep 17 00:00:00 2001 From: Neil Date: Sat, 10 Sep 2016 22:24:17 +0200 Subject: [PATCH] Rename menu items --- tabakrolletjie/scenes/menu.py | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/tabakrolletjie/scenes/menu.py b/tabakrolletjie/scenes/menu.py index dcad16b..7f67102 100644 --- a/tabakrolletjie/scenes/menu.py +++ b/tabakrolletjie/scenes/menu.py @@ -6,7 +6,7 @@ from .base import BaseScene from ..events import QuitEvent, SceneChangeEvent from ..loader import loader from ..constants import FONTS -from ..widgets import TextButton +from ..widgets import TextButton, SpacerButton class MenuScene(BaseScene): @@ -18,10 +18,11 @@ class MenuScene(BaseScene): self._title = font_title.render('A Game with a title', True, (255, 255, 255)) self._menu = [ - TextButton("Load Level", (255, 255, 255), name='load level'), - TextButton("Start Game (Day)", (255, 255, 255), name='start game'), - TextButton("Load Saved Game", (255, 255, 255), name='load game'), + TextButton("New Game", (255, 255, 255), name='new game'), + TextButton("Continue / Retry", (255, 255, 255), name='continue'), TextButton("Help", (255, 255, 255), name='help'), + SpacerButton((50, 30)), + TextButton("Quit", (255, 255, 255), name='quit'), ] def render(self, surface, gamestate): @@ -71,11 +72,13 @@ class MenuScene(BaseScene): self._do_help() elif ev.type == pgl.MOUSEBUTTONDOWN: pressed = self._get_pressed(ev) - if pressed == 'load level': + if pressed == 'new game': self._do_load_level() - elif pressed == 'start game': + elif pressed == 'continue': self._do_day() elif pressed == 'help': self._do_help() + elif pressed == 'quit': + QuitEvent.post() elif pressed: print 'Pressed', pressed -- 2.34.1