summaryrefslogtreecommitdiffhomepage
path: root/src/bullet.c
diff options
context:
space:
mode:
authorrealtradam <[email protected]>2024-05-12 18:06:59 -0400
committerrealtradam <[email protected]>2024-05-12 18:06:59 -0400
commitb3de05173338e83f2473976e4ad6f8331202c485 (patch)
treebc88c331f3ae8cceb6f163830b3b1b948acea8e0 /src/bullet.c
parent9f0296d34c948b11619887185b01f2928fbb33a5 (diff)
downloadtojam2024-b3de05173338e83f2473976e4ad6f8331202c485.tar.gz
tojam2024-b3de05173338e83f2473976e4ad6f8331202c485.zip
.
Diffstat (limited to 'src/bullet.c')
-rw-r--r--src/bullet.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/bullet.c b/src/bullet.c
index 6fca87e..7bd16c5 100644
--- a/src/bullet.c
+++ b/src/bullet.c
@@ -12,6 +12,8 @@ struct
}
Bullet;
+float bullet_speed = 0.5;
+
Bullet bullets[100];
void
@@ -69,9 +71,9 @@ bullet_collision_check(void)
{
bullets[i].team = 0;
}
- bullets[i].position.x += bullets[i].direction.x * 0.25;
- bullets[i].position.y += bullets[i].direction.y * 0.25;
- bullets[i].position.z += bullets[i].direction.z * 0.25;
+ bullets[i].position.x += bullets[i].direction.x * bullet_speed;
+ bullets[i].position.y += bullets[i].direction.y * bullet_speed;
+ bullets[i].position.z += bullets[i].direction.z * bullet_speed;
Vector3 enemypos = { 0 };
if (bullets[i].team == 1)
{