Voxellancer  0.3
A game about voxels in space
 All Classes Functions Pages
damageforwarder.h
1 #pragma once
2 
3 #include <list>
4 
5 
6 #include "world/helper/damageimpact.h"
7 #include "world/helper/voxelaccumulator.h"
8 
9 
11 {
12 public:
13  void forwardDamageImpacts(std::list<DamageImpact> &dampedDeadlyDamageImpacts);
14  void dontForwardTo(std::list<Voxel*> &deadVoxels);
15 
16  std::list<DamageImpact> forwardedDamageImpacts();
17 
18 
19 protected:
20  WorldObject *m_currentWorldObject;
21  std::list<Voxel*> *m_currentNeighbours;
22  glm::ivec3 m_currentGridCell;
23 
24  VoxelAccumulator<DamageImpact> m_damageImpactAccumulator;
25 
26  float forwardFactor(float dotProduct, float fieldOfDamage, int neighbours);
27 };
28 
Definition: worldobject.h:43
Definition: damageforwarder.h:10