aboutsummaryrefslogtreecommitdiff
path: root/universe.c
diff options
context:
space:
mode:
authorrodri <rgl@antares-labs.eu>2023-02-23 16:31:16 +0000
committerrodri <rgl@antares-labs.eu>2023-02-23 16:31:16 +0000
commit5052a27ece26976e3bec769896bbdc65d9e5ede2 (patch)
tree173b7afa030d48c22186dee89eb26bb83b84e5b4 /universe.c
parentd40305baf8a0722cf6128520a5b792fc173c5a93 (diff)
downloadmusw-5052a27ece26976e3bec769896bbdc65d9e5ede2.tar.gz
musw-5052a27ece26976e3bec769896bbdc65d9e5ede2.tar.bz2
musw-5052a27ece26976e3bec769896bbdc65d9e5ede2.zip
(inefficiently) send bullets state and paint them.
Diffstat (limited to 'universe.c')
-rw-r--r--universe.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/universe.c b/universe.c
index be481c9..bce345c 100644
--- a/universe.c
+++ b/universe.c
@@ -48,10 +48,11 @@ ship_fire(Ship *s)
0, 0, 1,
};
- bv = mulpt2(xform(Vec2(1,0), R), 10*THRUST);
+ bv = mulpt2(xform(Vec2(1,0), R), THRUST);
for(i = 0; i < nelem(s->rounds); i++)
if(!s->rounds[i].fired){
+ s->rounds[i].p = s->p;
s->rounds[i].v = addpt2(s->v, bv);
s->rounds[i].θ = s->θ;
s->rounds[i].fired++;