Changeset 6711 for code/trunk/src/modules/pickup/PickupManager.h
- Timestamp:
- Apr 13, 2010, 10:16:10 AM (14 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
/code/branches/pickup4 (added) merged: 6632,6669,6675,6679,6700-6701,6707
- Property svn:mergeinfo changed
-
code/trunk/src/modules/pickup/PickupManager.h
r6540 r6711 44 44 #include "core/OrxonoxClass.h" 45 45 46 namespace orxonox 47 { 46 namespace orxonox // tolua_export 47 { // tolua_export 48 48 49 49 /** 50 50 @brief 51 51 Manages Pickupables. 52 In essence has two tasks to fulfill. Firstly it must link Pickupables (through their PickupIdentifiers) and their PickupRepresentations. Secondly it manages the Pickup GUI.52 In essence has two tasks to fulfill. Firstly it must link Pickupables (through their PickupIdentifiers) and their PickupRepresentations. Secondly it manages the PickupInventory. 53 53 //TODO: Manage Pickup GUI. 54 54 @author 55 55 Damian 'Mozork' Frick 56 56 */ 57 class _PickupExport PickupManager : public Singleton<PickupManager>, public OrxonoxClass 58 { 57 class _PickupExport PickupManager // tolua_export 58 : public Singleton<PickupManager>, public OrxonoxClass 59 { // tolua_export 59 60 friend class Singleton<PickupManager>; 60 61 … … 63 64 virtual ~PickupManager(); 64 65 65 static PickupManager& getInstance() { return Singleton<PickupManager>::getInstance(); } 66 static PickupManager& getInstance() { return Singleton<PickupManager>::getInstance(); } // tolua_export 66 67 67 68 bool registerRepresentation(const PickupIdentifier* identifier, PickupRepresentation* representation); //!< Registers a PickupRepresentation together with the PickupIdentifier of the Pickupable the PickupRepresentation represents. 68 69 PickupRepresentation* getRepresentation(const PickupIdentifier* identifier); //!< Get the PickupRepresentation representing the Pickupable with the input PickupIdentifier. 69 70 71 // tolua_begin 72 orxonox::PickupCarrier* getPawn(void); 73 74 int getNumCarrierChildren(orxonox::PickupCarrier* carrier); 75 orxonox::PickupCarrier* getCarrierChild(int index, orxonox::PickupCarrier* carrier); 76 77 const std::string& getCarrierName(orxonox::PickupCarrier* carrier); 78 79 int getNumPickups(orxonox::PickupCarrier* carrier); 80 PickupRepresentation* getPickupRepresentation(int index, orxonox::PickupCarrier* carrier); 81 void dropPickup(int index, orxonox::PickupCarrier* carrier); 82 void usePickup(int index, orxonox::PickupCarrier* carrier, bool use); 83 // tolua_end 84 70 85 private: 71 86 static PickupManager* singletonPtr_s; 87 static const std::string guiName_s; 72 88 73 89 PickupRepresentation* defaultRepresentation_; //!< The default PickupRepresentation. 74 90 std::map<const PickupIdentifier*, PickupRepresentation*, PickupIdentifierCompare> representations_; //!< Map linking PickupIdentifiers (representing types if Pickupables) and PickupRepresentations. 75 91 76 }; 92 }; // tolua_export 77 93 78 } 94 } // tolua_export 79 95 80 96 #endif // _PickupManager_H__
Note: See TracChangeset
for help on using the changeset viewer.