| Line | |
|---|
| 1 | /*! |
|---|
| 2 | * @file collision.h |
|---|
| 3 | * Definition of a collision event |
|---|
| 4 | |
|---|
| 5 | */ |
|---|
| 6 | |
|---|
| 7 | #ifndef _COLLISION_H |
|---|
| 8 | #define _COLLISION_H |
|---|
| 9 | |
|---|
| 10 | #include "base_object.h" |
|---|
| 11 | #include "vector.h" |
|---|
| 12 | |
|---|
| 13 | |
|---|
| 14 | class WorldEntity; |
|---|
| 15 | class BoundingVolume; |
|---|
| 16 | |
|---|
| 17 | //! A class representing a simple collision |
|---|
| 18 | class Collision : public BaseObject { |
|---|
| 19 | |
|---|
| 20 | public: |
|---|
| 21 | Collision(); |
|---|
| 22 | virtual ~Collision(); |
|---|
| 23 | |
|---|
| 24 | public: |
|---|
| 25 | Vector pointOfImpact; //!< point of impact, approximated via bounding volumes |
|---|
| 26 | WorldEntity* body; //!< the collision body |
|---|
| 27 | BoundingVolume* boundingVolume; //!< reference to the bounding volume that fired the collision |
|---|
| 28 | }; |
|---|
| 29 | |
|---|
| 30 | #endif /* _COLLISION_H */ |
|---|
Note: See
TracBrowser
for help on using the repository browser.