checkpoint bugged help!! - 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: checkpoint bugged help!! (
/showthread.php?tid=548093)
checkpoint bugged help!! -
GOD0FWAR - 27.11.2014
i want to create a job, when i enter the vehicle i type /startjob, and it shows the first checkpoint but when i enter the first checkpoint the second checkpoint doesnt show up , how to fix that??
pawn Код:
CMD:startjob(playerid, params[])
{
if(PlayerInfo[playerid][pJob] == 1)
{
new vehicleid = GetPlayerVehicleID(playerid);
if(IsAjobCar(vehicleid) && GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
if(gPlayerCheckpointStatus[playerid] == CHECKPOINT_NONE)
{
SendClientMessage(playerid, COLOR_GREY, "[job]: Follow The Checkpoints and get your reward.");
SetPlayerCheckpoint(playerid, -309.0990,-1381.1797,10.7049, 10);
working[playerid] =1;
}
}
else return SendClientMessage(playerid, COLOR_GREY, "[job]: You are not at job car!!");
}
else return SendClientMessage(playerid, COLOR_GREY, "[job]: You are not a working man!");
return 1;
}
now when player enter checkpoint
pawn Код:
public OnPlayerEnterCheckpoint(playerid)
{
if(IsPlayerInRangeOfPoint(playerid, 10, -309.0990,-1381.1797,10.7049))
{
DisablePlayerCheckpoint(playerid);
SendClientMessage(playerid, COLOR_GREY, "[Job]: You got 23 More checkpoints to go.");
SetPlayerCheckpoint(playerid, -286.6838,-1366.6523,9.2448, 10);
}
if(IsPlayerInRangeOfPoint(playerid, 10, -286.6838,-1366.6523,9.2448))
{
DisablePlayerCheckpoint(playerid);
SendClientMessage(playerid, COLOR_GREY, "[Job]: You got 22 More checkpoints to go.");
SetPlayerCheckpoint(playerid, -299.1016,-1345.1233,7.8737, 10);
}
return 1;
}
Re : checkpoint bugged help!! -
MCZOFT - 27.11.2014
i had prbolem few years ago ,
this can help you to solve it ,
PHP код:
CreateDynamicCheckpoint
https://sampforum.blast.hk/showthread.php?tid=311103