X-Git-Url: https://git.ctpug.org.za/?a=blobdiff_plain;f=tabakrolletjie%2Fscenes%2Fnight.py;h=aadff681400cd67a38794eba040dbe71a800d977;hb=a3f0f03d8339e7efdb35cc45212f5dd8cc236c5a;hp=6d4e2bca431f1211d30f445c71dc76962f1f57c9;hpb=2345da1ab4f1319448cb14cf077ef492767a9fd7;p=tabakrolletjie.git diff --git a/tabakrolletjie/scenes/night.py b/tabakrolletjie/scenes/night.py index 6d4e2bc..aadff68 100644 --- a/tabakrolletjie/scenes/night.py +++ b/tabakrolletjie/scenes/night.py @@ -13,7 +13,7 @@ from ..utils import debug_timer from ..loader import loader from ..transforms import Overlay from ..turnip import Turnip -from ..constants import NIGHT_LENGTH +from ..constants import NIGHT_LENGTH, DEBUG class NightScene(BaseScene): @@ -56,7 +56,7 @@ class NightScene(BaseScene): if ev.key in (pgl.K_q, pgl.K_ESCAPE): from .menu import MenuScene SceneChangeEvent.post(scene=MenuScene()) - if ev.key == pgl.K_e: + if ev.key == pgl.K_e and DEBUG: self._to_day() elif ev.type == pgl.MOUSEBUTTONDOWN: if ev.button == 1: @@ -82,3 +82,4 @@ class NightScene(BaseScene): def exit(self, gamestate): turnip_data = [turnip.serialize() for turnip in self._turnips] gamestate.turnips = turnip_data + gamestate.days += 1