diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2018-04-20 13:08:58 +0200 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2018-04-20 13:08:58 +0200 |
commit | e8b487b0d2c1dc622256b89642ac291632f101fc (patch) | |
tree | 02df8baf050da52e22d9eb8ab55b45b0e242d87c /src/game/game.hpp | |
parent | f4fe2c7f10a8d2e253de27f1a540ca68184d5d29 (diff) |
More improvements to shooting.
Diffstat (limited to 'src/game/game.hpp')
-rw-r--r-- | src/game/game.hpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/game/game.hpp b/src/game/game.hpp index 61ea146..1a28413 100644 --- a/src/game/game.hpp +++ b/src/game/game.hpp @@ -86,8 +86,8 @@ namespace game { } repl_assets_t; typedef struct { - render::animated_texture_t blood, flash, explosion, ricochet; - audio::sound_t explosion_sound, ricochet_sound; + render::animated_texture_t blood, flash, explosion, ricochet, water_splash; + audio::sound_t explosion_sound, ricochet_sound, water_splash_sound; } fx_assets_t; typedef struct { @@ -249,7 +249,8 @@ namespace game { bool rocket_fired = false; void check_area(void); - void shoot(v2f_t aim); + void shoot(v2f_t from, v2f_t at, int damage); + void fire_shotgun(v2f_t aim); void target_and_attack(void); unit_soldier_t(game::state_t *game_); @@ -390,12 +391,13 @@ namespace game { void render_to(render::state_t *render); }; - class fx_ricochet_t : public effect_t { + class fx_bullet_miss_t : public effect_t { v2f_t x; + bool water; public: - fx_ricochet_t(game::state_t *game_, v2f_t x_); - ~fx_ricochet_t(void) {}; + fx_bullet_miss_t(game::state_t *game_, v2f_t x_, bool water_); + ~fx_bullet_miss_t(void) {}; void render_to(render::state_t *render); }; |