/*! * @file collision_handle.h * @brief Definition of a collision handle: used for accesing per world entity collision events and reactions */ #ifndef _COLLISION_HANDLE_H #define _COLLISION_HANDLE_H #include "base_object.h" class Collision; //! A class for defining collision reactions and storing events class CollisionHandle : public BaseObject { public: CollisionHandle(); virtual ~CollisionHandle(); void registerCollision(Collision* collision); void handleCollisions(); private: WorldEntity* owner; //!< the worldenity this reaction will be applied on classID targetClass; //!< the entities triggering the handle bool bDispatched; //!< true if this handle has already been dispatched bool bStopOnFirstCollision //!< true if the cd of this object should be terminated after one match std::vector collisionList; //!< a list full of collisions std::vector targetList; //!< a list of target classes for filtering }; #endif /* _COLLISION_HANDLE_H */