[Pedido] Preciso de um contador de fps e ping.
#1

Alguйm tem o contador de fps e ping no textdraw.
Reply
#2

Utilize este como base e crie o seu.
Reply
#3

PHP код:
forward AttPing();
new 
Text:ping[MAX_PLAYERS];
public 
OnGameModeInit()
{
for( new 
i = 0; i < MAX_PLAYERS; i++ ) {
ping[ i ] = TextDrawCreate( 400, 25, "   " );
TextDrawFont( ping[ i ], 3);
TextDrawUseBox( ping[ i ], 0);
TextDrawSetOutline( pingping[ i ], 1);
TextDrawBackgroundColor( ping[ i ], 0xffff00ff);
TextDrawColor( ping[ i ], 0x00ff00ff);
TextDrawAlignment( ping[ i ], 1);
}
SetTimer( "AttPing", 1000, 1 );
return 
1;
}
public 
AttPing()
{
     new 
cells[ 19 ];
    for( new 
i = 0; i < MAX_PLAYERS; i++ )
    {
        if( 
IsPlayerConnected( i ) )
        {
            
format( cells, sizeof( cells ), "Ping: %d", GetPlayerPing(i) );
            
TextDrawSetString( ping[ i ], gstring);
        }
    }
    return 
1;
} 
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)