Changeset 729


Ignore:
Timestamp:
07/15/10 17:55:27 (7 weeks ago)
Author:
Xynth
Message:

Ticket #104 This patch grays out minimap He3 info when there is no eye in the sector detecting He3 changes. Also changes He3 asteroid label to gray or white instead of white or green.

Location:
branch/FAZR6/src/WinTrek
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branch/FAZR6/src/WinTrek/radarimage.cpp

    r692 r729  
    996996                                        fill = 1.0f; 
    997997 
     998                                                                        //Xynth #104 Color asteroids white/gray to match minimap 
    998999                                                                        if (((IasteroidIGC*)pmodel)->GetAsteroidCurrentEye(psideMine)) 
    999                                                                                 color = Color::Green(); 
     1000                                                                                color = Color::White(); 
     1001                                                                        else 
     1002                                                                                color = Color::Gray(); 
    10001003 
    10011004                                } 
  • branch/FAZR6/src/WinTrek/sectormap.cpp

    r692 r729  
    352352        return fOre; 
    353353    } 
     354 
     355        //Xynth #104 7/2010  Returns true if at least one He3 is eyed 
     356        bool HeliumAsteroidVisibileInCluster(IclusterIGC* pcluster) 
     357        { 
     358                bool HeSpotted = false; 
     359                IsideIGC*   psideMine = trekClient.GetShip()->GetSide(); 
     360        for (AsteroidLinkIGC* asteriodLink = pcluster->GetAsteroids()->first(); 
     361            asteriodLink != NULL; asteriodLink = asteriodLink->next()) 
     362        { 
     363            AsteroidAbilityBitMask aabm = asteriodLink->data()->GetCapabilities(); 
     364 
     365            // if we can mine helium at this asteroid 
     366            if ((aabm & c_aabmMineHe3) != 0) 
     367            { 
     368                if (asteriodLink->data()->GetAsteroidCurrentEye(psideMine)) 
     369                                        HeSpotted = true; 
     370            } 
     371        } 
     372                return HeSpotted; 
     373        }  //End #104 function 
    354374 
    355375    void Render(Context* pcontext) 
     
    458478                Point ptAsteroids(xSecondColumn, yTop - 45); 
    459479 
     480                                //Xynth #104 7/2010 
     481                                Color color; 
     482                                if (HeliumAsteroidVisibileInCluster(m_pClusterSel)) 
     483                                        color = Color::White(); 
     484                                else 
     485                                        color = Color::Gray(); 
     486 
    460487                // draw the helium count 
    461488                pcontext->DrawString( 
    462489                    pfont, 
    463                     Color::White(), 
     490                    color, //Xynth #104 7/2010 Color::White(), 
    464491                    ptHelium, 
    465492                    "He3: " + ZString(int(GetHeliumInCluster(m_pClusterSel))) 
Note: See TracChangeset for help on using the changeset viewer.