25.06.2018, 10:19
Alright, let me sort this out for you..
First, You need to set a specific ID for the car, just like what a person gave you before, like..
And then check if the player's vehicle is the same as this..
First, You need to set a specific ID for the car, just like what a person gave you before, like..
PHP код:
arrMissionVeh[0]=CreateVehicle(522, 0.0, 0.0, 0.0,0.0, -1, -1, 60);
PHP код:
cmd:startjob(playerid, params[])
{
new vehicle = GetPlayerVehicleID(playerid);
if(vehicle != arrMissionVeh[0] && vehicle != arrMissionVeh[1] && vehicle != arrMissionVeh[3]) return SendClientMessage(playerid, COLOR_RED, "You are not in job's vehicle!");
//Add your job code here..
}