Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3534 in orxonox.OLD


Ignore:
Timestamp:
Mar 13, 2005, 11:30:11 PM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: fixed another bug in list-template and added patch from bensch to the pnode to enable the different rotation modes

Location:
orxonox/trunk/src/lib
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/coord/p_node.cc

    r3531 r3534  
    396396  // printf("%s", this->objectName);
    397397
    398       if( this->mode == MOVEMENT || this->mode == ALL)
     398      if( this->mode == MOVEMENT )
    399399        {
    400400          if( this->bAbsCoorChanged /*&& this->timeStamp != DataTank::timeStamp*/)
     
    428428              this->absDirection = parent->getAbsDir() * this->relDirection;
    429429            }
    430         }   
     430        }
     431     
     432      if( this->mode == ALL)
     433        {
     434          if( this->bAbsCoorChanged /*&& this->timeStamp != DataTank::timeStamp*/)
     435            {
     436              printf("PNode::update () - this->bAbsCoorChanged = true\n");
     437              /* if you have set the absolute coordinates this overrides all other changes */
     438              this->relCoordinate = this->absCoordinate - parent->getAbsCoor ();
     439            }
     440          else if( this->bRelCoorChanged /*&& this->timeStamp != DataTank::timeStamp*/)
     441            {
     442              /*this is bad style... must be deleted later - just for testing*/
     443              if( this->parent == NULL)
     444                this->absCoordinate = this->relCoordinate;
     445              else
     446                this->absCoordinate = parent->getAbsCoor() + parent->getAbsDir().apply(this->relCoordinate);          /* update the current absCoordinate */
     447            }
     448        }
     449
     450
    431451  PNode* pn = this->children->enumerate();
    432452  while( pn != NULL)
  • orxonox/trunk/src/lib/util/list.h

    r3532 r3534  
    137137          delete this->currentEl;
    138138          this->currentEl = te;
     139          this->size--;
    139140          return;
    140141        }
Note: See TracChangeset for help on using the changeset viewer.