changeset 93:f32332459fe1

fixed single player properly
author Rene Dudfield <renesd@gmail.com>
date Sun, 08 Jul 2012 15:18:31 +0200
parents 3a4ca250ca2e
children b7c8e0e15395
files zrpn/board.py zrpn/main.py
diffstat 2 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/zrpn/board.py	Sun Jul 08 15:13:47 2012 +0200
+++ b/zrpn/board.py	Sun Jul 08 15:18:31 2012 +0200
@@ -36,7 +36,7 @@
                         
             animations.extend(self.apply_gravity(turns))
             if not killed:
-                return animations, extra
+                return animations, extra, net_adds
 
 
     def apply_gravity(self, turn):
--- a/zrpn/main.py	Sun Jul 08 15:13:47 2012 +0200
+++ b/zrpn/main.py	Sun Jul 08 15:18:31 2012 +0200
@@ -35,6 +35,9 @@
                     ans, extra, net_adds = self.board.update()
                     animations.extend(ans)
                     self.display.do_animations(animations)
+
+            for n in net_adds:
+                self.display.add_zrpn(*n)
             self.display.frame()
 
 class MainMenu(sgc.Menu):
@@ -58,7 +61,6 @@
 
 
 def main():
-
     
     screen = display.Display()