See this plugin for an example:
http://forums.alliedmods.net/showpos...3&postcount=13
Here's a little example that may be easier than looking through the source above. I would add a RANK item to your enum so you can store his current rank in the existing global array. I don't know if you want to have a separate rank for each type of jump or just one based on all jumps. This is an example just for JUMP count.
PHP Code:
enum _:CountTypes
{
JUMP,
DUCK,
DUCKJUMP,
JUMPRANK
};
new const JumpLevels[][] =
{
{ 0 , 300 },
{ 301 , 600 }
};
new const JumpLevelDesc[][] =
{
"Noob",
"Chief"
};
Then to assign a level.
PHP Code:
for ( new i = 0 ; i < sizeof( JumpLevels ) ; i++ )
{
if ( JumpLevels[ i ][ 0 ] <= g_iCounter[ iClient ][ JUMP ] <= JumpLevels[ i ][ 1 ] )
{
g_iCounter[ iClient ][ JUMPRANK ] = i;
break;
}
}
client_print( 0 , print_chat , "My rank is %s" , JumpLevelDesc[ g_iCounter[ iClient ][ JUMPRANK ] ] );
__________________