Voxellancer  0.3
A game about voxels in space
 All Classes Functions Pages
impulse.h
1 #pragma once
2 
3 #include <glm/glm.hpp>
4 
5 
6 class Voxel;
7 class WorldObject;
8 
9 class Impulse
10 {
11 public:
12  Impulse(WorldObject* worldObject, Voxel* voxel, const glm::vec3& speed, float mass, const glm::vec3& normal);
13 
14  WorldObject* worldObject();
15  const WorldObject* worldObject() const;
16 
17  Voxel* voxel();
18  const Voxel* voxel() const;
19 
20  const glm::vec3& speed() const;
21 
22  float mass() const;
23 
24  const glm::vec3& normal() const;
25 
26 
27  void add(const Impulse& impulse);
28 
29 
30 protected:
31  WorldObject* m_worldObject;
32  Voxel* m_voxel;
33  glm::vec3 m_speed;
34  float m_mass;
35  glm::vec3 m_normal;
36 };
37 
Definition: worldobject.h:43
Definition: voxel.h:15
Definition: impulse.h:9