projects
/
tabakrolletjie.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
hooked up night button and moved cursor reset next to other tools
[tabakrolletjie.git]
/
tabakrolletjie
/
scenes
/
day.py
diff --git
a/tabakrolletjie/scenes/day.py
b/tabakrolletjie/scenes/day.py
index cb65569e3da70207fbeb33794e87c75a2a33d77a..57eeedb51f3d440e0af7a40da7841a3c590d205b 100644
(file)
--- a/
tabakrolletjie/scenes/day.py
+++ b/
tabakrolletjie/scenes/day.py
@@
-60,7
+60,11
@@
class DayScene(BaseScene):
def create_tools(self, gamestate):
tools = []
def create_tools(self, gamestate):
tools = []
- x, y, step = 50, SCREEN_SIZE[1] - 40, 50
+ x, y, step = 0, SCREEN_SIZE[1] - 40, 50
+
+ tools.append(ImageButton(
+ '32', 'default_cursor.png', name='reset tool', pos=(x, y)))
+ x += step
tools.append(ImageButton('32', 'seed.png', name='seed', pos=(x, y)))
x += step
tools.append(ImageButton('32', 'seed.png', name='seed', pos=(x, y)))
x += step
@@
-72,8
+76,9
@@
class DayScene(BaseScene):
tools.append(tool)
x += step
tools.append(tool)
x += step
+ # TODO: will also add back to menu button
tools.append(ImageButton(
tools.append(ImageButton(
- '32', '
default_cursor.png', name='reset tool', pos=(x
, y)))
+ '32', '
night.png', name='start night', pos=(SCREEN_SIZE[0] - 50
, y)))
return tools
def exit(self, gamestate):
return tools
def exit(self, gamestate):
@@
-179,6
+184,9
@@
class DayScene(BaseScene):
self._unset_cursor()
self._tool = None
self._clear_light_toolbar()
self._unset_cursor()
self._tool = None
self._clear_light_toolbar()
+ elif tool.name == 'start night':
+ from .night import NightScene
+ SceneChangeEvent.post(scene=NightScene())
else:
self._tool = tool
if self._tool.name == 'seed':
else:
self._tool = tool
if self._tool.name == 'seed':