new playersracing++; new IsPlayerRacing[MAX_PLAYERS]; new maxplayers=4; new racestarted=0; public OnPlayerCommandText(playerid, cmdtext[]) { if(strcmp(cmdtext, "/race", true)==0) { playersracing++; IsPlayerRacing[playerid]=1; if(playersracing >= maxplayers) { if(racestarted==0) { for(new i=0; i < MAX_PLAYERS; i++) { if(IsPlayerRacing[i]==1) { StartRace(i); } } racestarted=1; } else if(racestared==1) { StartRace(playerid); } } return 1; } return 0; }