diff options
author | salaaad2 <arthurdurant263@gmail.com> | 2022-01-06 23:44:19 +0100 |
---|---|---|
committer | salaaad2 <arthurdurant263@gmail.com> | 2022-01-06 23:44:19 +0100 |
commit | a67d57e85601c6ebf69c1c6828125470035af393 (patch) | |
tree | 0d7b5d60b339e516d11fad7c38f98680724b8fc3 /src/weapon.hpp | |
parent | amazing textures. v0.0.4 (diff) | |
download | threshold-a67d57e85601c6ebf69c1c6828125470035af393.tar.gz threshold-a67d57e85601c6ebf69c1c6828125470035af393.tar.bz2 threshold-a67d57e85601c6ebf69c1c6828125470035af393.tar.xz threshold-a67d57e85601c6ebf69c1c6828125470035af393.tar.zst threshold-a67d57e85601c6ebf69c1c6828125470035af393.zip |
weapon as an abstract class. now make more weapons
Diffstat (limited to 'src/weapon.hpp')
-rw-r--r-- | src/weapon.hpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/weapon.hpp b/src/weapon.hpp index 1f4393d..e43b7da 100644 --- a/src/weapon.hpp +++ b/src/weapon.hpp @@ -11,7 +11,8 @@ #include "raylib.h" -class Weapon { +class AWeapon { +protected: Sound shot; Sound reload; @@ -22,10 +23,10 @@ class Weapon { unsigned int const &damage; public: - Weapon(float const &rg, unsigned int const &dmg, unsigned int const & mag, const char *s, const char *r); - ~Weapon(); + AWeapon(float const &rg, unsigned int const &dmg, unsigned int const & mag, const char *s, const char *r); + ~AWeapon(); - int bang(); + virtual int bang() = 0; void refill(); bool empty; |