diff options
author | Aki <please@ignore.pl> | 2022-04-18 11:05:24 +0200 |
---|---|---|
committer | Aki <please@ignore.pl> | 2022-04-18 11:05:24 +0200 |
commit | 2773854a3e749512826fa8b71b77e754be79836f (patch) | |
tree | df3771aae7025eae7505c53eebb36d5b3ff56f01 /ConstantVelocity.h | |
parent | f0891205710c2d5c9b78a9d275de88a77c2ccda3 (diff) | |
download | bullethell2022-2773854a3e749512826fa8b71b77e754be79836f.zip bullethell2022-2773854a3e749512826fa8b71b77e754be79836f.tar.gz bullethell2022-2773854a3e749512826fa8b71b77e754be79836f.tar.bz2 |
Renamed bullets header to simply ConstantVelocity
Diffstat (limited to 'ConstantVelocity.h')
-rw-r--r-- | ConstantVelocity.h | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/ConstantVelocity.h b/ConstantVelocity.h new file mode 100644 index 0000000..3970aff --- /dev/null +++ b/ConstantVelocity.h @@ -0,0 +1,31 @@ +#pragma once + +#include <vector> + +#include <raylib.h> + + +static constexpr float MARGIN {40}; + + +struct ConstantVelocityBullet; + + +struct ConstantVelocitySystem +{ + ConstantVelocitySystem(); + explicit ConstantVelocitySystem(int reserved); + void update(float dt); + void draw(); + std::vector<ConstantVelocityBullet> m_bullets; +}; + + +struct ConstantVelocityBullet +{ + using Vector = std::vector<ConstantVelocityBullet>; + Vector2 position; + Vector2 velocity; + float radius; + Color color; +}; |