From a4d6c97f61e01e005b2f4571346578feed597f48 Mon Sep 17 00:00:00 2001 From: Neil Date: Sat, 10 Sep 2016 14:24:09 +0200 Subject: [PATCH] Add days to gamestate and day screen display --- tabakrolletjie/gamestate.py | 1 + tabakrolletjie/scenes/day.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/tabakrolletjie/gamestate.py b/tabakrolletjie/gamestate.py index 714a047..4ce92e8 100644 --- a/tabakrolletjie/gamestate.py +++ b/tabakrolletjie/gamestate.py @@ -9,6 +9,7 @@ class GameState(object): } self.harvested = 0 self.eaten = 0 + self.days = 0 @property def station(self): diff --git a/tabakrolletjie/scenes/day.py b/tabakrolletjie/scenes/day.py index ec94bc6..e54e2f1 100644 --- a/tabakrolletjie/scenes/day.py +++ b/tabakrolletjie/scenes/day.py @@ -244,8 +244,8 @@ class DayScene(BaseScene): self._lights.tick() def _update_toolbar(self, gamestate): - text = ("Turnip Stocks: Seeds: %d. Planted: %d. " + text = ("Day: %d: Turnip Stocks: Seeds: %d. Planted: %d. " "Harvested: %d. Destroyed: %d" % - (self._seeds, len(self._turnips), + (gamestate.days, self._seeds, len(self._turnips), self._harvested, gamestate.eaten)) self._toolbar = self._toolbar_font.render(text, True, (255, 255, 255)) -- 2.34.1