added pausing to night and moved reset tool after other tools
[tabakrolletjie.git] / tabakrolletjie / scenes / day.py
index 4cc42f893d8dc1203a330fb401a25fd01ad18e1a..17690e254da011e93429cf9c213291a3f83bdf3b 100644 (file)
@@ -79,11 +79,9 @@ class DayScene(BaseScene):
 
     def create_tools(self, gamestate):
         tools = []
-        x, y, step = 0, SCREEN_SIZE[1] - 40, 50
 
-        tools.append(ImageButton(
-            '32', 'default_cursor.png', name='reset tool', pos=(x, y)))
-        x += step
+        x, y, step = 50, SCREEN_SIZE[1] - 40, 50
+        
         tools.append(ImageButton('32', 'seed.png', name='seed', pos=(x, y)))
         x += step
 
@@ -95,6 +93,9 @@ class DayScene(BaseScene):
             tools.append(tool)
             x += step
 
+        tools.append(ImageButton(
+            '32', 'default_cursor.png', name='reset tool', pos=(x, y)))
+
         tools.append(ImageButton(
             '32', 'night.png', name='start night', pos=(SCREEN_SIZE[0] - 100, y)))
         tools.append(ImageButton(
@@ -204,7 +205,7 @@ class DayScene(BaseScene):
             elif ev.key == pgl.K_e:
                 from .night import NightScene
                 SceneChangeEvent.post(scene=NightScene())
-            elif ev.key == pgl.K_SPACE:
+            elif ev.key == pgl.K_SPACE and DEBUG:
                 self._paused = not self._paused
         elif ev.type == pgl.MOUSEBUTTONDOWN:
             if ev.button == 1:
@@ -263,6 +264,7 @@ class DayScene(BaseScene):
                 elif self._tool:
                     # Unset tool
                     self._tool = None
+                    self._clear_light_toolbar()
                     self._unset_cursor()
         elif ev.type == pgl.MOUSEMOTION:
             if self._dragging: