~luke-jr/tr2norigins/tr2norigins-0.4

« back to all changes in this revision

Viewing changes to src/tron/gHud.cpp

  • Committer: Luke Dashjr
  • Date: 2010-04-20 23:21:40 UTC
  • mfrom: (690.1.1 tr2noriginsbzr)
  • Revision ID: luke+bzr@dashjr.org-20100420232140-3vd91ux0vl3i7ctc
MERGE: combine minor changes in manta's initial bazaar import (mostly whitespace)

Show diffs side-by-side

added added

removed removed

Lines of Context:
132
132
 
133
133
 
134
134
    rTextField min_t(-size-(0.1*size)+locx-e_loc,locy,.12*size,.24*size);
135
 
    rTextField max_t(+size+(0.1*size)+locx-f_loc,locy,.12*size,.24*size);
 
135
    rTextField max_t(+size+(0.1*size)+locx-f_loc,locy,.12*size,.24*size); 
136
136
  
137
137
    if ( full=="" ) 
138
138
    {
421
421
                        }
422
422
                    }
423
423
                }
424
 
 
 
424
   
425
425
                if (me!=NULL){
426
426
                    gCycle *h = dynamic_cast<gCycle *>(me->Object());
427
427
                    if (h && ( !player->netPlayer || !player->netPlayer->IsChatting()) && se_GameTime()>0){
520
520
                        }
521
521
                        // Ping FPS Time Combined
522
522
                        if(subby_ShowPing){
523
 
                            static gTextCache cacheArray[MAX_PLAYERS];
 
523
                                                     static gTextCache cacheArray[MAX_PLAYERS];
524
524
                            gTextCache & cache = cacheArray[player->ID()];
525
525
                            if ( (!cache.Call( 0, myping )) || (fps_updated == true) || (time_updated == true)  )
526
526
                            {
532
532
                                rTextField ping(.7,subby_PingLocY,.15*size,.3*size);
533
533
                                ping << "0xccaa44" << "Ping: 0xccccee" << int(myping * 1000) << "ms" << "\n" << the_fps << "\n" << the_time;
534
534
                            
535
 
                            }
 
535
                          }
536
536
                        }
537
537
                    }
538
538
                }
544
544
 
545
545
}
546
546
 
 
547
 
547
548
static void display_fps_subby()
548
549
{
549
550
    if (!(se_mainGameTimer &&
554
555
 
555
556
    static int fps       = 60;
556
557
    static REAL lastTime = 0;
557
 
 
558
558
    REAL newtime = tSysTimeFloat();
559
559
    REAL ts      = newtime - lastTime;
560
560
 
569
569
    }
570
570
    rDisplayListFiller filler( cache.list_ );
571
571
 
572
 
 
 
572
 
573
573
    if ( tRecorder::IsRunning() )
574
574
    {
575
575
    float size =.17;
591
591
        fps      = newfps;
592
592
        lastTime = newtime;
593
593
    }
594
 
 
 
594
      
595
595
    if(sr_FPSOut){
596
596
        the_fps = "";
597
597
        the_fps << "0xccaa44FPS: 0xccccee" <<fps;
603
603
    the_fps = "";
604
604
    }
605
605
    // Show the time
606
 
    if(showTime) {
 
606
        if(showTime) {
607
607
        static int lastTime=0;
608
608
        static char theTime[13];
609
609
//        float size =.14;