Fire up/down

This commit is contained in:
Miloslav Číž 2019-10-21 20:24:15 +02:00
parent a5cf220d5d
commit e5b662468e
2 changed files with 6 additions and 2 deletions

View File

@ -69,6 +69,6 @@
/** /**
Speed of rocket projectile, in squares per second. Speed of rocket projectile, in squares per second.
*/ */
#define SFG_ROCKET_SPEED 16 #define SFG_ROCKET_SPEED 20
#endif // guard #endif // guard

6
main.c
View File

@ -1209,7 +1209,11 @@ RCL_Vector2D dir = RCL_angleToDirection(SFG_player.camera.direction);
p.direction[0] = (dir.x * SFG_ROCKER_MOVE_UNITS_PER_FRAME) / RCL_UNITS_PER_SQUARE; p.direction[0] = (dir.x * SFG_ROCKER_MOVE_UNITS_PER_FRAME) / RCL_UNITS_PER_SQUARE;
p.direction[1] = (dir.y * SFG_ROCKER_MOVE_UNITS_PER_FRAME) / RCL_UNITS_PER_SQUARE; p.direction[1] = (dir.y * SFG_ROCKER_MOVE_UNITS_PER_FRAME) / RCL_UNITS_PER_SQUARE;
p.direction[2] = 0; p.direction[2] =
(SFG_player.camera.shear * SFG_ROCKER_MOVE_UNITS_PER_FRAME) /
SFG_CAMERA_MAX_SHEAR_PIXELS;
SFG_createProjectile(p); SFG_createProjectile(p);