SA-MP Forums Archive
CP not appearing. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: CP not appearing. (/showthread.php?tid=412995)



CP not appearing. - Black Axe - 03.02.2013

PHP код:
        if(CP[playerid] == 2348)
    {
        if(
GetPlayerVehicleID(playerid) >= FedexC[0] && GetPlayerVehicleID(playerid) <= FedexC[12])
        {
            
SendClientMessage(playerid COLOR_WHITE,"< Radio : You have reached the loading-Bay , Please transfer the Goods to the CP on your radar");
            new 
rand random(sizeof(FedexPoints));
            
SetPlayerCheckpoint(playeridFedexPoints[rand][0], FedexPoints[rand][1], FedexPoints[rand][2], 3.0);
            
CP[playerid] = 2349;
            
PlayerInfo[playerid][pvLoaded] = 1;
        }
        else
        {
            
SendClientMessage(playeridCOLOR_GRAD2,    "You're not in a Fedex Truck !");
        }
        
DisablePlayerCheckpoint(playerid);
        
CP[playerid] = 0;
    } 
Well - Once the player enter that CP , another random once should appear on the radar - The message appear tho , But the CP never appears :/


PHP код:
new Float:FedexPoints[5][3] = {
{
1298.6033,-1856.7441,12.9526},
{
1293.3746,-1650.4768,12.9565},
{
1195.2435,-1324.1394,12.9615},
{
1315.7272,-920.2856,37.5370},
{
1009.0753,-932.6588,41.7536}
}; 
Help would really be appreciated.


Re: CP not appearing. - LarzI - 03.02.2013

You're disabling the checkpoint at the end of the command.
pawn Код:
DisablePlayerCheckpoint(playerid);
        CP[playerid] = 0;
Removing or moving those will fix it.


Re: CP not appearing. - Black Axe - 03.02.2013

Thank you very much - Didn't notice , Repped+