Argument!
#2

The IsPlayerInDynamicCP function is looking for a checkpointid value, not the location of the checkpoint.

pawn Код:
IsPlayerInDynamicCP(playerid, checkpointid)  { /* code */ }
Somewhere within your script, you must have created dynamic checkpoints using something like:



pawn Код:
new RobberyCheckpoints[14];

for(...) // for loop
{
   RobberyCheckpoints[i] = CreateDynamicCheckpoint(RobberyCPs[i][0], RobberyCPs[i][1], RobberyCPs[i][2]...);
}
You need to use this variable:
pawn Код:
RobberyCheckpoints[...]
So your code should look like this:
pawn Код:
stock IsPlayerInRobberyCheckpoint(playerid)
{
    for(new i=0; i < sizeof(RobberyCPS); i++)
    {
        if(IsPlayerInDynamicCP(playerid, RobberyCheckpoints[i]))
        {
            return 1;
        }
    }
    return 0;
}
Reply


Messages In This Thread
Argument! - by vassilis - 28.02.2016, 22:54
Re: Argument! - by EiresJason - 28.02.2016, 23:07
Re: Argument! - by vassilis - 28.02.2016, 23:11
Re: Argument! - by EiresJason - 28.02.2016, 23:15
Re: Argument! - by vassilis - 28.02.2016, 23:21
Re: Argument! - by SickAttack - 29.02.2016, 00:42

Forum Jump:


Users browsing this thread: 1 Guest(s)