Changeset 3653 in orxonox.OLD for orxonox/trunk
- Timestamp:
- Mar 25, 2005, 6:14:40 PM (20 years ago)
- Location:
- orxonox/trunk/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/lib/util/list.h
r3652 r3653 70 70 71 71 template<class T> 72 tIterator<T>::tIterator (listElement<T>* startElement)72 inline tIterator<T>::tIterator (listElement<T>* startElement) 73 73 { 74 74 this->currentEl = startElement; … … 92 92 return NULL; 93 93 } 94 if( this->currentEl == this->firstEl) 95 { 96 this->currentEl = this->currentEl->next; 97 return this->firstEl->curr; 98 } 94 99 if( this->currentEl->next == NULL) 95 100 return NULL; 96 return this->currentEl->next->curr; 101 this->currentEl = this->currentEl->next; 102 return this->currentEl->curr; 97 103 } 98 104 … … 247 253 248 254 template<class T> 249 tIterator<T>* tList<T>::getIterator()255 inline tIterator<T>* tList<T>::getIterator() 250 256 { 251 257 if( this->size == 0) return NULL; -
orxonox/trunk/src/story_entities/world.cc
r3646 r3653 574 574 glLoadIdentity(); 575 575 576 entity = this->entities->enumerate(); 576 //entity = this->entities->enumerate(); 577 tIterator<WorldEntity>* iterator = this->entities->getIterator(); 578 entity = iterator->nextElement(); 577 579 while( entity != NULL ) 578 580 { 579 581 if( entity->bDraw ) entity->draw(); 580 entity = this->entities->nextElement(); 581 } 582 //entity = this->entities->nextElement(); 583 entity = iterator->nextElement(); 584 } 585 delete iterator; 582 586 583 587 glCallList (objectList);
Note: See TracChangeset
for help on using the changeset viewer.