1 #ifndef BLANK_ENTITY_HPP_
2 #define BLANK_ENTITY_HPP_
9 #include <glm/gtc/quaternion.hpp>
22 bool HasShape() const { return shape; }
23 const Shape *GetShape() const { return shape; }
24 void SetShape(const Shape *, const glm::vec3 &color);
27 const glm::vec3 &Velocity() const { return velocity; }
28 void Velocity(const glm::vec3 &);
30 const Block::Pos &Position() const { return position; }
31 void Position(const Block::Pos &);
32 void Move(const glm::vec3 &delta);
34 const Chunk::Pos ChunkCoords() const { return chunk; }
36 const glm::quat &AngularVelocity() const { return angular_velocity; }
37 void AngularVelocity(const glm::quat &);
39 const glm::mat4 &Rotation() const { return rotation; }
40 void Rotation(const glm::mat4 &);
41 void Rotate(const glm::quat &delta);
43 glm::mat4 Transform(const Chunk::Pos &chunk_offset) const;
44 Ray Aim(const Chunk::Pos &chunk_offset) const;
58 glm::quat angular_velocity;