Changeset 7959 in orxonox.OLD for branches/cr/src/lib/collision_reaction/collision.h
- Timestamp:
- May 29, 2006, 5:43:10 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/cr/src/lib/collision_reaction/collision.h
r7940 r7959 1 1 /*! 2 2 * @file collision.h 3 * Definition of a collision event3 * Definition of a collision as a two WE hit each other 4 4 */ 5 5 … … 11 11 class WorldEntity; 12 12 class BoundingVolume; 13 13 class CollisionEvent; 14 14 15 15 //! A class representing a simple collision … … 21 21 22 22 /** collides two WorldEntities @param entityA world entity A, @param entityB world entity B, @param bvA volume A @param bvB volumeB */ 23 inline void collide(WorldEntity* entityA, WorldEntity* entityB, BoundingVolume* bvA, BoundingVolume* bvB) 24 { this->entityA = entityA; this->entityB = entityB; this->bvA = bvA; this->bvB = bvB; } 23 inline void collide(WorldEntity* entityA, WorldEntity* entityB) { this->entityA = entityA; this->entityB = entityB; } 25 24 26 25 … … 29 28 /** @return Collision WorldEntity B */ 30 29 inline const WorldEntity* getEntityB() const { return this->entityB; } 31 /** @return Bounding Volume from EntityA */ 32 inline const BoundingVolume* getBVA() const { return this->bvA; } 33 /** @return Bounding Volume from EntityB */ 34 inline const BoundingVolume* getBVB() const { return this->bvB; } 30 31 /** registers a @param event CollisionEvent to take place */ 32 inline void registerCollisionEvent(CollisionEvent* event) { this->collisionList.push_back(event); } 35 33 36 34 37 35 private: 38 WorldEntity* entityA; //!< the collision body A39 WorldEntity* entityB; //!< the collision body B36 WorldEntity* entityA; //!< the collision body A 37 WorldEntity* entityB; //!< the collision body B 40 38 41 BoundingVolume* bvA; //!< reference to the bounding volume A 42 BoundingVolume* bvB; //!< reference to the bounding volume B 39 std::vector<CollisionEvent*> collisionList; //!< the collision event list 43 40 }; 44 41
Note: See TracChangeset
for help on using the changeset viewer.