Changeset 7545
- Timestamp:
- Oct 15, 2010, 8:35:20 AM (14 years ago)
- Location:
- code/trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/libraries/tools/Timer.h
r7401 r7545 133 133 inline void unpauseTimer() 134 134 { this->bActive_ = true; } 135 /// Returns true if the Timer is active (neither stop ed nor paused).135 /// Returns true if the Timer is active (neither stopped nor paused). 136 136 inline bool isActive() const 137 137 { return this->bActive_; } -
code/trunk/src/modules/pickup/items/InvisiblePickup.cc
r7544 r7545 99 99 100 100 this->initializeIdentifier(); 101 this->setDurationType(Pickup::durationTypeOnce_s); // The duration type is always once.102 101 } 103 102 … … 135 134 this->setInvisible(false); 136 135 137 if( this->isContinuous() || !this->durationTimer_.isActive() && this->durationTimer_.getRemainingTime() == this->getDuration())136 if((!this->isContinuous() && this->isImmediate()) || (!this->durationTimer_.isActive() && this->durationTimer_.getRemainingTime() == this->getDuration())) 138 137 { 139 138 this->Pickupable::destroy(); 140 139 } 141 else 140 else if(this->durationTimer_.isActive()) 142 141 { 143 142 this->durationTimer_.pauseTimer(); -
code/trunk/src/modules/pickup/items/InvisiblePickup.h
r7544 r7545 54 54 - The <b>duration</b> Specifies how long (in seconds) the invisibility lasts. 55 55 56 An examle of a XML implementation of a InvisiblePickup would be: 57 @code 58 <HealthPickup 59 activationType = "immediate" 60 durationType = "continuous" 61 duration = 30.0 62 /> 63 @endcode 64 56 65 @author 57 66 Benedict Simlinger
Note: See TracChangeset
for help on using the changeset viewer.