]> git.localhorst.tv Git - blank.git/blob - src/ai/Chaser.hpp
43667c06d332686471f3036be79ce003dc1a017d
[blank.git] / src / ai / Chaser.hpp
1 #ifndef BLANK_AI_CHASER_HPP_
2 #define BLANK_AI_CHASER_HPP_
3
4 #include "Controller.hpp"
5
6
7 namespace blank {
8
9 class World;
10
11 class Chaser
12 : public Controller {
13
14 public:
15         Chaser(World &, Entity &ctrl, Entity &tgt) noexcept;
16         ~Chaser();
17
18         Entity &Target() noexcept { return tgt; }
19         const Entity &Target() const noexcept { return tgt; }
20
21         void Update(int dt) override;
22
23 private:
24         World &world;
25         Entity &tgt;
26         float chase_speed;
27         float flee_speed;
28         float stop_dist;
29         float flee_dist;
30
31 };
32
33 }
34
35 #endif