20.03.2019, 14:33
PHP Code:
new CheckCarregar_TransportadorRefC[MAX_PLAYERS];
new CheckCarregar_Transportador_Final[MAX_PLAYERS];
CheckCarregar_TransportadorRefC[playerid] = CreateDynamicCP(-1005.3510,-676.9293,32.0078, 7.0, -1, -1, playerid, STREAMER_CP_SD, -1, 0);
SetPlayerMapIcon(playerid, 0, -1005.3510,-676.9293,32.0078, 0, 0xFF0000AA, 0);
public OnPlayerEnterDynamicCP(playerid, checkpointid)
{
if(checkpointid == CheckCarregar_TransportadorRefC[playerid])
{
if(IsPlayerInVehicleJob_01(playerid))
{
if(IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid)))
{
DestroyDynamicCP(CheckCarregar_TransportadorRefC[playerid]);
RemovePlayerMapIcon(playerid, 0);
SendClientMessage(playerid, -1, "loading.");
CheckCarregar_Transportador_Final[playerid] = CreateDynamicCP(264.9304,1388.5432,10.5859, 7.0, -1, -1, playerid, STREAMER_CP_SD, -1, 0);
SetPlayerMapIcon(playerid, 0, 264.9304,1388.5432,10.5859, 0, 0xFF0000AA, 0);
}
else SendClientMessage(playerid, -1, "Vocк nгo estб com o trailer da sua profissгo engatado");
}
else return SendClientMessage(playerid, -1, "Esse nгo й seu veiculo de trabalho");
}
else if(checkpointid == CheckCarregar_Transportador_Final[playerid])
{
if(IsPlayerInVehicleJob_01(playerid))
{
if(IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid)))
{
DestroyDynamicCP(CheckCarregar_Transportador_Final[playerid]);
Player[playerid][pTrabalhando] = false;
SendClientMessage(playerid, -1, "finished.");
RemovePlayerMapIcon(playerid, 0);
}
else SendClientMessage(playerid, -1, "Vocк nгo estб com o trailer da sua profissгo engatado");
}
else return SendClientMessage(playerid, -1, "Esse nгo й seu veiculo de trabalho");
}
return 1;
}