15.04.2009, 00:24
Try something like:
//Global:
//This should be in the part where the race starts;
//Global:
Code:
new RacePositions[3];
Code:
RacePositions[0] = -1; RacePositions[1] = -1; RacePositions[2] = -1;
Code:
public OnPlayerEnterRaceCheckpoint(playerid) { ... case finish: { if(RacePositions[0] == -1) { RacePositions[0] = playerid; position = 1; } else if(RacePositions[1] == -1) { RacePositions[1] = playerid; position = 2; } else if(RacePositions[2] == -1) { RacePositions[2] = playerid; position = 3; } //Rest of that callback.... } }