Add basic support resistances
[tabakrolletjie.git] / tabakrolletjie / scenes / night.py
index 3f58d921e64ad450d7339390dfefc1c74247c9e0..7d028d58f1688ac984a512e190cdd7b8e71ce2b3 100644 (file)
@@ -141,6 +141,7 @@ class NightScene(BaseScene):
                 self._mould.tick(gamestate, self._space, self._lights)
                 self._lights.tick()
                 print "Power usage: ", self._lights.total_power_usage()
+                self._total_ticks += 1
             else:
                 self._end_night()
             if not self._mould.alive():
@@ -149,4 +150,6 @@ class NightScene(BaseScene):
     def exit(self, gamestate):
         turnip_data = [turnip.serialize() for turnip in self._turnips]
         gamestate.turnips = turnip_data
+        # TODO: Move this into the end_night function
         gamestate.days += 1
+        self._mould.update_resistances(gamestate)