Changeset 1968 for code/branches/objecthierarchy/src/orxonox/tools/Timer.cc
- Timestamp:
- Oct 20, 2008, 1:47:41 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/objecthierarchy/src/orxonox/tools/Timer.cc
r1755 r1968 92 92 this->bLoop_ = false; 93 93 this->bActive_ = false; 94 this->bKillAfterCall_ = false; 94 95 95 96 this->time_ = 0; … … 112 113 { 113 114 (*this->executor_)(); 115 116 if (this->bKillAfterCall_) 117 delete this; 114 118 } 115 119 … … 136 140 { 137 141 // It's time to call the function 138 if (this->bLoop_ )142 if (this->bLoop_ && !this->bKillAfterCall_) 139 143 { 140 144 this->time_ += this->interval_; // Q: Why '+=' and not '='? A: Think about it. It's more accurate like that. Seriously.
Note: See TracChangeset
for help on using the changeset viewer.