28.02.2016, 23:07
The IsPlayerInDynamicCP function is looking for a checkpointid value, not the location of the checkpoint.
Somewhere within your script, you must have created dynamic checkpoints using something like:
You need to use this variable:
So your code should look like this:
pawn Код:
IsPlayerInDynamicCP(playerid, checkpointid) { /* code */ }
pawn Код:
new RobberyCheckpoints[14];
for(...) // for loop
{
RobberyCheckpoints[i] = CreateDynamicCheckpoint(RobberyCPs[i][0], RobberyCPs[i][1], RobberyCPs[i][2]...);
}
pawn Код:
RobberyCheckpoints[...]
pawn Код:
stock IsPlayerInRobberyCheckpoint(playerid)
{
for(new i=0; i < sizeof(RobberyCPS); i++)
{
if(IsPlayerInDynamicCP(playerid, RobberyCheckpoints[i]))
{
return 1;
}
}
return 0;
}

