06.08.2015, 00:11
You need add array for ids for example
under define
then in cmd race2
and if player Y accept
if not, set
under define
pawn Код:
new RacePlayer[MAX_PLAYERS] = {INVALID_PLAYER_ID, ...};
pawn Код:
RacePlayer[target] = playerid;
//dialog here
pawn Код:
new target = RacePlayer[playerid];
if(IsPlayerConnected(target) && !g_PlayerInRace[target]) // if player is still connected and is not in race
{
// your code
}
pawn Код:
RacePlayer[playerid] = INVALID_PLAYER_ID;