projects
/
python-bulletml.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2877552
)
Bullet: Track previous X/Y.
author
Joe Wreschnig
<joe.wreschnig@gmail.com>
Tue, 16 Mar 2010 09:30:09 +0000
(
02:30
-0700)
committer
Joe Wreschnig
<joe.wreschnig@gmail.com>
Tue, 16 Mar 2010 09:30:09 +0000
(
02:30
-0700)
bulletml/impl.py
patch
|
blob
|
history
diff --git
a/bulletml/impl.py
b/bulletml/impl.py
index 6fe1641c2134fe1f231c09bba9654e8711027dae..4dde9fb4b608115ad2dec45a6426a89255282faf 100644
(file)
--- a/
bulletml/impl.py
+++ b/
bulletml/impl.py
@@
-287,6
+287,8
@@
class Bullet(object):
created.extend(action.step())
direction = math.radians(self.direction)
+ self.px = self.x
+ self.py = self.y
self.x += self.mx + math.sin(direction) * self.speed
self.y += self.my - math.cos(direction) * self.speed