changeset 616:25f3adbff00a pyntnclick

Note albow callbacks in GameScreen
author Stefano Rivera <stefano@rivera.za.net>
date Sat, 11 Feb 2012 21:33:17 +0200
parents cb01c3a09ee1
children ecde1d6bdda0
files pyntnclick/gamescreen.py
diffstat 1 files changed, 3 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/pyntnclick/gamescreen.py	Sat Feb 11 21:23:48 2012 +0200
+++ b/pyntnclick/gamescreen.py	Sat Feb 11 21:33:17 2012 +0200
@@ -71,6 +71,7 @@
         self.detail = DetailWindow(screen)
 
     def draw(self, surface):
+        self.animate()
         if self.game.previous_scene and self.game.do_check == LEAVE:
             # We still need to handle leave events, so still display the scene
             self.game.previous_scene.draw(surface, self)
@@ -243,26 +244,17 @@
     def leave_screen(self):
         CursorWidget.leave_screen(self)
 
-    # Albow uses magic method names (command + '_cmd'). Yay.
-    # Albow's search order means they need to be defined here, not in
-    # PopMenu, which is annoying.
-    def hide_cmd(self):
-        # This option does nothing, but the method needs to exist for albow
-        return
-
+    # albow callback:
     def main_menu_cmd(self):
         self.shell.show_screen(self.shell.menu_screen)
 
+    # albow callback:
     def quit_cmd(self):
         self.shell.quit()
 
     def hand_pressed(self):
         self.inventory.unselect()
 
-    def begin_frame(self):
-        if self.running:
-            self.state_widget.animate()
-
 
 class DefEndScreen(Screen):
     """A placeholder 'Game Over' screen so people can get started easily"""