projects
/
naja.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add placeholder drawing logic
[naja.git]
/
naja
/
engine.py
diff --git
a/naja/engine.py
b/naja/engine.py
index 1c6b70ac8a7917871edae10512acfc90e11b80d2..32c139f8a56f17427b0a426bdb3b1e2fe3ec338d 100644
(file)
--- a/
naja/engine.py
+++ b/
naja/engine.py
@@
-6,13
+6,15
@@
from naja.events import SceneChangeEvent, QuitGameEvent
class Engine(object):
class Engine(object):
- def __init__(self, surface, scene):
+ def __init__(self, surface, scene
, state
):
self._surface = surface
self._scene = scene
self._surface = surface
self._scene = scene
+ self._state = state
def run(self):
clock = pygame.time.Clock()
while True:
def run(self):
clock = pygame.time.Clock()
while True:
+ self._surface.fill((0, 0, 0))
for ev in pygame.event.get():
if ev.type == pgl.QUIT or QuitGameEvent.matches(ev):
self.quit_game()
for ev in pygame.event.get():
if ev.type == pgl.QUIT or QuitGameEvent.matches(ev):
self.quit_game()