Changeset 6502 for code/trunk/src/modules/overlays/hud/HUDRadar.cc
- Timestamp:
- Mar 11, 2010, 11:34:20 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/modules/overlays/hud/HUDRadar.cc
r6417 r6502 141 141 // calc position on radar... 142 142 Vector2 coord = get2DViewcoordinates(this->owner_->getPosition(), this->owner_->getOrientation() * WorldEntity::FRONT, this->owner_->getOrientation() * WorldEntity::UP, wePointer->getWorldPosition()); 143 coord *= Ogre::Math::PI / 3.5 ; // small adjustment to make it fit the texture144 panel->setPosition((1.0 + coord.x - size) * 0.5, (1.0 - coord.y - size) * 0.5);143 coord *= Ogre::Math::PI / 3.5f; // small adjustment to make it fit the texture 144 panel->setPosition((1.0f + coord.x - size) * 0.5f, (1.0f - coord.y - size) * 0.5f); 145 145 146 146 if (bIsMarked) 147 147 { 148 148 this->marker_->show(); 149 this->marker_->setDimensions(size * 1.5 , size * 1.5);150 this->marker_->setPosition((1.0 + coord.x - size * 1.5) * 0.5, (1.0 - coord.y - size * 1.5) * 0.5);149 this->marker_->setDimensions(size * 1.5f, size * 1.5f); 150 this->marker_->setPosition((1.0f + coord.x - size * 1.5f) * 0.5f, (1.0f - coord.y - size * 1.5f) * 0.5f); 151 151 } 152 152 }
Note: See TracChangeset
for help on using the changeset viewer.