Jump to content

Vehicul job


Recommended Posts

Salut, am facut o comanda /work, insa nu prea stiu cum sa setez pentru jucator atunci cand i se creaza masina doar el sa poata da F la ea nu si alti jucatori, gen pentru alti jucatori masina sa fie incuiata.

CMD:work(playerid, params[])
	if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to log in first.");
	if(PlayerInfo[playerid][pCarLic] == 0) return SendClientMessage(playerid, COLOR_GREY, "You don't have driving licence.");
	if(JobWorking[playerid] == 1) return SendClientMessage(playerid, COLOR_GREY, "You already working. Use /stopwork if you don't want to work anymore.");
		if(!AdminDuty[playerid]) {
			if(PlayerInfo[playerid][pJob] == 5) {
				if(IsPlayerInRangeOfPoint(playerid, 4, Job[5][X], Job[5][Y], Job[5][Z])) {
		            if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT) {
		                JobVehicle[playerid] = CreateVehicle(448, Pos[0], Pos[1], Pos[2], 90.0000, -1, -1, -1);
		                PutPlayerInVehicleEx(playerid, JobVehicle[playerid], 0);
		                Gas[JobVehicle[playerid]] = 100;
		                JobWorking[playerid] = 1;
					else return SCM(playerid, -1, "Nu poti folosi comanda intr-un vehicul.");
	return 1;
Edited by RedGun
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...

Important Information

By using this site, you agree to our Terms of Use. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.