]> git.localhorst.tv Git - blobs.git/blob - src/creature/Situation.hpp
randomize creature properties a bit
[blobs.git] / src / creature / Situation.hpp
1 #ifndef BLOBS_CREATURE_SITUATION_HPP_
2 #define BLOBS_CREATURE_SITUATION_HPP_
3
4 #include "../math/glm.hpp"
5
6
7 namespace blobs {
8 namespace world {
9         class Planet;
10         class Tile;
11         class TileType;
12 }
13 namespace creature {
14
15 class Situation {
16
17 public:
18         Situation();
19         ~Situation();
20
21 public:
22         bool OnPlanet() const noexcept;
23         world::Planet &GetPlanet() const noexcept { return *planet; }
24         bool OnSurface() const noexcept;
25         int Surface() const noexcept { return surface; }
26         const glm::dvec3 &Position() const noexcept { return position; }
27         world::Tile &GetTile() const noexcept;
28         const world::TileType &GetTileType() const noexcept;
29
30         void Move(const glm::dvec3 &dp) noexcept;
31         void SetPlanetSurface(world::Planet &, int srf, const glm::dvec3 &pos) noexcept;
32
33 public:
34         world::Planet *planet;
35         glm::dvec3 position;
36         int surface;
37         enum {
38                 LOST,
39                 PLANET_SURFACE,
40         } type;
41
42 };
43
44 }
45 }
46
47 #endif