Changeset 7547 for code/trunk/src/modules/pickup/PickupSpawner.h
- Timestamp:
- Oct 16, 2010, 12:37:09 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/modules/pickup/PickupSpawner.h
r7540 r7547 39 39 40 40 #include <string> 41 42 41 #include "tools/Timer.h" 43 42 … … 92 91 { return this->triggerDistance_; } 93 92 /** 94 @brief Set the distance in which to trigger.95 @param value The new distance in which to trigger.96 */97 inline void setTriggerDistance(float value)98 { this->triggerDistance_ = value; }99 100 /**101 93 @brief Get the time to respawn. 102 94 @returns Returns the time after which this gets re-actived. … … 105 97 { return this->respawnTime_; } 106 98 /** 99 @brief Get the maximum number of items that will be spawned by this PickupSpawner. 100 @return Returns the maximum number of items spawned by this PickupSpawner. 101 */ 102 inline int getMaxSpawnedItems(void) const 103 { return this->maxSpawnedItems_; } 104 105 106 protected: 107 void decrementSpawnsRemaining(void); //!< Decrements the number of remaining spawns. 108 void startRespawnTimer(void); 109 110 /** 111 @brief Set the distance in which to trigger. 112 @param value The new distance in which to trigger. 113 */ 114 inline void setTriggerDistance(float value) 115 { this->triggerDistance_ = value; } 116 /** 107 117 @brief Set the time to respawn. 108 118 @param time New time after which this gets re-actived. … … 110 120 inline void setRespawnTime(float time) 111 121 { this->respawnTime_ = time; } 112 113 /**114 @brief Get the maximum number of items that will be spawned by this PickupSpawner.115 @return Returns the maximum number of items spawned by this PickupSpawner.116 */117 inline int getMaxSpawnedItems(void)118 { return this->maxSpawnedItems_; }119 122 void setMaxSpawnedItems(int items); //!< Sets the maximum number of spawned items. 120 121 protected:122 void decrementSpawnsRemaining(void); //!< Decrements the number of remaining spawns.123 124 void startRespawnTimer(void);125 123 126 124 virtual Pickupable* getPickup(void); //!< Creates a new Pickupable. 127 125 128 126 void setPickupable(Pickupable* pickup); //!< Sets a Pickupable for the PickupSpawner to spawn. 129 const Pickupable* getPickupable(void) ; //!< Get the Pickupable that is spawned by this PickupSpawner.127 const Pickupable* getPickupable(void) const; //!< Get the Pickupable that is spawned by this PickupSpawner. 130 128 131 129 Pickupable* pickup_; //!< The pickup to be spawned.
Note: See TracChangeset
for help on using the changeset viewer.