Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 28, 2012, 12:28:44 PM (12 years ago)
Author:
landauf
Message:

renamed RVName to radarname
cast to RadarViewable instead of SpaceShip to set the name (in PlayerInfo)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/modules/overlays/hud/HUDNavigation.cc

    r9016 r9257  
    7979    this->setTextSize ( 0.05f );
    8080    this->setNavMarkerSize ( 0.05f );
    81     this->setDetectionLimit( 10000.0f ); 
     81    this->setDetectionLimit( 10000.0f );
    8282}
    8383
     
    101101    XMLPortParam ( HUDNavigation, "textSize",      setTextSize,      getTextSize,      xmlelement, mode );
    102102    XMLPortParam ( HUDNavigation, "navMarkerSize", setNavMarkerSize, getNavMarkerSize, xmlelement, mode );
    103     XMLPortParam ( HUDNavigation, "detectionLimit", setDetectionLimit, getDetectionLimit, xmlelement, mode ); 
     103    XMLPortParam ( HUDNavigation, "detectionLimit", setDetectionLimit, getDetectionLimit, xmlelement, mode );
    104104}
    105105
     
    146146
    147147float HUDNavigation::getArrowSizeX(int dist)
    148 {   
    149     if (dist < 600) 
     148{
     149    if (dist < 600)
    150150        dist = 600;
    151151    return this->getActualSize().x * 900 * navMarkerSize_ / dist;
     
    153153
    154154float HUDNavigation::getArrowSizeY(int dist)
    155 {   
     155{
    156156    if (dist < 600)
    157         dist = 600;   
     157        dist = 600;
    158158    return this->getActualSize().y * 900 * navMarkerSize_ / dist;
    159159}
     
    184184        ObjectMap::iterator it = activeObjectList_.find ( listIt->first );
    185185        closeEnough_ = listIt->second < detectionLimit_ ;
    186         // display radarviewables on HUD if the marker limit and max-distance is not exceeded 
    187         if ( markerCount_ < markerLimit_ && (closeEnough_ ||  detectionLimit_ < 0) ) 
     186        // display radarviewables on HUD if the marker limit and max-distance is not exceeded
     187        if ( markerCount_ < markerLimit_ && (closeEnough_ ||  detectionLimit_ < 0) )
    188188        {
    189189
     
    201201            //display name next to cursor
    202202            else{
    203             it->second.text_->setCaption(it->first->getRVName());
    204             textLength = it->first->getRVName().size() * it->second.text_->getCharHeight() * 0.3f;
     203            it->second.text_->setCaption(it->first->getRadarName());
     204            textLength = it->first->getRadarName().size() * it->second.text_->getCharHeight() * 0.3f;
    205205            }
    206206
     
    311311            it->second.text_->show();
    312312        }
    313         else // do not display on HUD 
     313        else // do not display on HUD
    314314        {
    315315            it->second.panel_->hide();
Note: See TracChangeset for help on using the changeset viewer.