/*! * @file aiming_system.h * Definition of */ #ifndef _AIMING_SYSTEM_H #define _AIMING_SYSTEM_H #include "world_entity.h" // FORWARD DECLARATION class TiXmlElement; class BVTree; class Model; class OBBTree; class AimingSystem : public WorldEntity { ObjectListDeclaration(AimingSystem); public: AimingSystem(WorldEntity* owner = NULL); virtual ~AimingSystem(); void init(); WorldEntity* getNearestTarget(); void flushList() { this->selectionList.clear(); } void setRange(float range){this->range = range;}; virtual void hit(float damage, WorldEntity* killer); virtual void destroy(WorldEntity* entity) {} virtual void tick(float dt); virtual void draw() const; private: float range; //!< float sideLength; std::vector selectionList; //!< the selections WorldEntity* owner; //!< the owner of the targeting system OBBTree* obbTree; }; #endif /* _AIMING_SYSTEM_H */