Race control point count
#4

Yeah.
pawn Код:
#define MAX_RACES 5
//change '5' to whatever you want.
#define RACE0CPs 50
#define RACE1CPs 25
//make more '#define RACE[number]CPs [number of checkpoints]' when you need them.
new RaceCPsLeft[MAX_RACES][MAX_PLAYERS];
When they start the race.
pawn Код:
/*make sure the number inside RaceCPsLeft[HERE][playerid] is always the proper Race id
and also 'variable' is always the one assoicated with the race id - Make sure the RaceCPsLeft[RACEID][playerid]='variable'.
EG: RaceCPsLeft[3][playerid] SHOULD equal = RACE3CPs.

*/

RaceCPsLeft[0][playerid] = RACE0CPs;
//or
RaceCPsLeft[1][playerid] = RACE1CPs;
When a player enters a race checkpoint.
pawn Код:
new string[25];
RaceCPsLeft[0][playerid]--;
format(string,sizeof(string),"Checkpoints left: %i.",RaceCPsLeft[0][playerid]);
GameTextForPlayer(playerid,string,3000,3);
Reply


Messages In This Thread
Race control point count - by RK-2fast4u - 08.10.2013, 12:34
Re: Race control point count - by EiresJason - 08.10.2013, 12:50
Re: Race control point count - by RK-2fast4u - 08.10.2013, 13:05
Re: Race control point count - by EiresJason - 08.10.2013, 13:12
Re: Race control point count - by RK-2fast4u - 08.10.2013, 13:20
Re: Race control point count - by EiresJason - 08.10.2013, 13:23

Forum Jump:


Users browsing this thread: 2 Guest(s)