adds more highscore options meth yielded, pilot missions, trucked cargo, vehicles jacked

This commit is contained in:
Steven Howard 2018-10-09 10:01:05 +01:00
parent 590da61131
commit 9c48bbeebc

View File

@ -5283,7 +5283,7 @@ CMD:irresistiblecoins( playerid, params[ ] )
CMD:top( playerid, params[ ] ) return cmd_highscores( playerid, params ); CMD:top( playerid, params[ ] ) return cmd_highscores( playerid, params );
CMD:highscores( playerid, params[ ] ) CMD:highscores( playerid, params[ ] )
{ {
ShowPlayerDialog( playerid, DIALOG_HIGHSCORES, DIALOG_STYLE_LIST, "{FFFFFF}Highscores", "Seasonal Rank\nTotal Score\nTotal Kills\nTotal Arrests\nTotal Robberies\nHits Completed\nFires Extinguished\nBurglaries\nBlown Jails\nBlown Vaults", "Select", "Close" ); ShowPlayerDialog( playerid, DIALOG_HIGHSCORES, DIALOG_STYLE_LIST, "{FFFFFF}Highscores", "Seasonal Rank\nTotal Score\nTotal Kills\nTotal Arrests\nTotal Robberies\nHits Completed\nFires Extinguished\nBurglaries\nBlown Jails\nBlown Vaults\nVehicles Jacked\nMeth Yielded\nTotal Trucked Cargo\nTotal Pilot Missions\n", "Select", "Close" );
return 1; return 1;
} }
@ -11364,7 +11364,7 @@ public OnPlayerKeyStateChange( playerid, newkeys, oldkeys )
// taze mechanism // taze mechanism
else if ( PRESSED( KEY_LOOK_BEHIND ) ) else if ( PRESSED( KEY_LOOK_BEHIND ) )
{ {
if ( p_Class[ playerid ] == CLASS_POLICE && p_AntiSpawnKillEnabled{ playerid } ) if ( p_Class[ playerid ] == CLASS_POLICE && !p_AntiSpawnKillEnabled{ playerid } )
{ {
new new
closestid = GetClosestPlayer( playerid ); closestid = GetClosestPlayer( playerid );
@ -14318,10 +14318,21 @@ public OnDialogResponse( playerid, dialogid, response, listitem, inputtext[ ] )
// blown vaults // blown vaults
case 9: mysql_function_query( dbHandle, "SELECT `NAME`, `BLEW_VAULT` as `SCORE_VAL` FROM `USERS` ORDER BY `BLEW_VAULT` DESC LIMIT 25", true, "OnHighScoreCheck", "ii", playerid, 9 ); case 9: mysql_function_query( dbHandle, "SELECT `NAME`, `BLEW_VAULT` as `SCORE_VAL` FROM `USERS` ORDER BY `BLEW_VAULT` DESC LIMIT 25", true, "OnHighScoreCheck", "ii", playerid, 9 );
// vehicles jacked
case 10: mysql_function_query( dbHandle, "SELECT `NAME`, `VEHICLES_JACKED` as `SCORE_VAL` FROM `USERS` ORDER BY `VEHICLES_JACKED` DESC LIMIT 25", true, "OnHighScoreCheck", "ii", playerid, 10 );
// meth yielded
case 11: mysql_function_query( dbHandle, "SELECT `NAME`, `METH_YIELDED` as `SCORE_VAL` FROM `USERS` ORDER BY `METH_YIELDED` DESC LIMIT 25", true, "OnHighScoreCheck", "ii", playerid, 11 );
// total trucked cargo
case 12: mysql_function_query( dbHandle, "SELECT `NAME`, `TRUCKED` as `SCORE_VAL` FROM `USERS` ORDER BY `TRUCKED` DESC LIMIT 25", true, "OnHighScoreCheck", "ii", playerid, 12 );
// pilot missons
case 13: mysql_function_query( dbHandle, "SELECT `NAME`, `PILOT` as `SCORE_VAL` FROM `USERS` ORDER BY `PILOT` DESC LIMIT 25", true, "OnHighScoreCheck", "ii", playerid, 13 );
} }
} }
if ( dialogid == DIALOG_HIGHSCORES_BACK && ! response ) { if ( dialogid == DIALOG_HIGHSCORES_BACK && ! response ) {
return ShowPlayerDialog( playerid, DIALOG_HIGHSCORES, DIALOG_STYLE_LIST, "{FFFFFF}Highscores", "Seasonal Rank\nTotal Score\nTotal Kills\nTotal Arrests\nTotal Robberies\nHits Completed\nFires Extinguished\nBurglaries\nBlown Jails\nBlown Vaults", "Select", "Close" ); return ShowPlayerDialog( playerid, DIALOG_HIGHSCORES, DIALOG_STYLE_LIST, "{FFFFFF}Highscores", "Seasonal Rank\nTotal Score\nTotal Kills\nTotal Arrests\nTotal Robberies\nHits Completed\nFires Extinguished\nBurglaries\nBlown Jails\nBlown Vaults\nVehicles Jacked\nMeth Yielded\nTotal Trucked Cargo\nTotal Pilot Missions\n", "Select", "Close" );
} }
return 1; return 1;
} }
@ -14352,6 +14363,10 @@ thread OnHighScoreCheck( playerid, highscore_item )
case 7: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Burglaries\n", szSmallString = "Top 25 Burglaries"; case 7: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Burglaries\n", szSmallString = "Top 25 Burglaries";
case 8: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Jailes\n", szSmallString = "Top 25 Blown Jails"; case 8: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Jailes\n", szSmallString = "Top 25 Blown Jails";
case 9: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Vaults\n", szSmallString = "Top 25 Blown Vaults"; case 9: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Vaults\n", szSmallString = "Top 25 Blown Vaults";
case 10: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Vehicles\n", szSmallString = "Top 25 Vehicles Jacked";
case 11: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Meth\n", szSmallString = "Top 25 Meth Yielded";
case 12: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Trucked\n", szSmallString = "Top 25 Total Trucked Cargo";
case 13: szLargeString = ""COL_GOLD"Player\t"COL_GOLD"Missions\n", szSmallString = "Top 25 Total Pilot Missions";
} }
for ( new row = 0; row < rows; row ++ ) for ( new row = 0; row < rows; row ++ )