Changeset 6307 in orxonox.OLD for trunk/src/lib
- Timestamp:
- Dec 27, 2005, 12:20:32 AM (19 years ago)
- Location:
- trunk/src/lib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/coord/p_node.cc
r6299 r6307 628 628 void PNode::setParentMode(PARENT_MODE parentMode) 629 629 { 630 this->parentMode &= (0xfff0| parentMode);630 this->parentMode = ((this->parentMode & 0xfff0) | parentMode); 631 631 } 632 632 … … 745 745 746 746 747 if( this->parentMode & PNODE_LOCAL_ROTATE && this->bRelDirChanged)747 if(this->bRelDirChanged && this->parentMode & PNODE_LOCAL_ROTATE ) 748 748 { 749 749 /* update the current absDirection - remember * means rotation around sth.*/ … … 752 752 } 753 753 754 if(likely(this-> parentMode & PNODE_MOVEMENT && this->bRelCoorChanged))754 if(likely(this->bRelCoorChanged && this->parentMode & PNODE_MOVEMENT)) 755 755 { 756 756 /* update the current absCoordinate */ 757 this->prevRelCoordinate = this->relCoordinate;758 this->absCoordinate = this->parent->getAbsCoor() + this->relCoordinate;757 this->prevRelCoordinate = this->relCoordinate; 758 this->absCoordinate = this->parent->getAbsCoor() + this->relCoordinate; 759 759 } 760 760 else if( this->parentMode & PNODE_ROTATE_MOVEMENT && this->bRelCoorChanged) 761 761 { 762 762 /* update the current absCoordinate */ 763 this->prevRelCoordinate = this->relCoordinate;764 this->absCoordinate = this->parent->getAbsCoor() + parent->getAbsDir().apply(this->relCoordinate);763 this->prevRelCoordinate = this->relCoordinate; 764 this->absCoordinate = this->parent->getAbsCoor() + parent->getAbsDir().apply(this->relCoordinate); 765 765 } 766 766 ///////////////////////////////////////////////// -
trunk/src/lib/graphics/render2D/element_2d.cc
r6299 r6307 704 704 void Element2D::setParentMode2D(E2D_PARENT_MODE parentMode) 705 705 { 706 this->parentMode &= (0xfff0| parentMode);706 this->parentMode = ((this->parentMode & 0xfff0) | parentMode); 707 707 } 708 708
Note: See TracChangeset
for help on using the changeset viewer.