projects
/
koperkapel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f1d14f1
)
Pass through extra arguments to AnimatedSurfActor.
author
Simon Cross
<hodgestar@gmail.com>
Sat, 5 Mar 2016 15:34:54 +0000
(17:34 +0200)
committer
Simon Cross
<hodgestar@gmail.com>
Sat, 5 Mar 2016 15:34:54 +0000
(17:34 +0200)
koperkapel/actors/animsurf.py
patch
|
blob
|
history
diff --git
a/koperkapel/actors/animsurf.py
b/koperkapel/actors/animsurf.py
index fb9e73ae588fee161f5ba5ad411be6d3d7301cb9..24567b8335eceb95e158c4eb79026f58f982ca5a 100644
(file)
--- a/
koperkapel/actors/animsurf.py
+++ b/
koperkapel/actors/animsurf.py
@@
-6,13
+6,13
@@
from .orientatedsurf import OrientatedSurfActor
class AnimatedSurfActor(OrientatedSurfActor):
- def __init__(self, frames, cycle_dt=0.2):
+ def __init__(self, frames, cycle_dt=0.2
, **kw
):
self._frames = frames
self._frame = random.randint(0, len(frames) - 1)
self._dt = 0
self._cycle_dt = cycle_dt
each_tick(self.update)
- super().__init__(surf=frames[self._frame],
angle=0
)
+ super().__init__(surf=frames[self._frame],
**kw
)
def update(self, dt):
self._dt += dt