Hallo,
ich hab soeben ein kleines Race erstellt.
mit diesem befehl lade ich jemanden zum Race ein:
Code
if(strcmp(cmd, "/invitetorace", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Benutze: /invitetorace [SpielerID]");
return 1;
}
new para1;
para1 = ReturnUser(tmp);
if(IsPlayerConnected(para1))
{
if(para1 != INVALID_PLAYER_ID)
{
RaceCheckpoint[playerid] = 0;
SetPlayerRaceCheckpoint(playerid,0,1509.655883,-1734.555297,12.933884,1675.851806,-1734.781372,12.930230,3);
RaceCheckpoint[para1] = 0;
SetPlayerRaceCheckpoint(para1,0,1509.655883,-1734.555297,12.933884,1675.851806,-1734.781372,12.930230,3);
}
}
}
return 1;
}
Alles anzeigen
das hier ist der Anfang des Races:
Code
if(RaceCheckpoint[playerid] == 0)
{
gettime(sHour, sMinute, sSecond);
SetPlayerRaceCheckpoint(playerid,0,1509.655883,-1734.555297,12.933884,1675.851806,-1734.781372,12.930230,3); /* Commerce */
RaceCheckpoint[playerid] = 1;
}
else if(RaceCheckpoint[playerid] == 1)
{
SetPlayerRaceCheckpoint(playerid,0,1675.851806,-1734.781372,12.930230,1688.415649,-1803.238159,12.961285,3); /* Commerce */
RaceCheckpoint[playerid] = 2;
}
else if(RaceCheckpoint[playerid] == 2)
{
SetPlayerRaceCheckpoint(playerid,0,1688.415649,-1803.238159,12.961285,1809.250732,-1834.237670,12.949241,3); /* Little Mexico */
RaceCheckpoint[playerid] = 3;
}
Alles anzeigen
Es gibt natürlich keinerlei warnungs/errors.
Weiß jemand, wieso die Checkpoints nicht ablaufen, wenn ich darin stehe?
Danke