Jump to content

[DELETED]Ajutor


MaRr
 Share

Recommended Posts

Salut! La TTC cand duc vehiculul in checkpoint nu imi dispare attach vehicle si nici macar nu primesc banii! Doar atunci cand ma dau jos din vehiculul TowTruck si ma duc in CK  imi da banii, dar masina nu dispare.. Ma puteti ajuta?

stock TTCFunction(playerid) {
	if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER) {
		if(strlen(PlayerInfo[playerid][pPin]) != 0 && PlayerInfo[playerid][pPinLogged] == 0) {
			 SendClientMessage(playerid, COLOR_GREY, "Nu poti folosi aceasta comanda deoarece nu te-ai autentificat cu codul de securitate.");
			 SendClientMessage(playerid, COLOR_GREY, "Pentru a te autentifica, foloseste comanda '/loginpin'!");
			 return 1;
		}		
		new m = GetVehicleModel(GetPlayerVehicleID(playerid));
		if(m == 525) {
			if(GetPlayerState(playerid)==2) {
				new idd, vid;
				vid = GetClosestVehicle2(playerid);
				idd = FindSpawnID(vid);	
				
				if(vid == 0) return 1;
				if(IsABike2(vid) || IsAPlane(vid) || GetVehicleModel(vid) == 448 || GetVehicleModel(vid) == 461 || GetVehicleModel(vid) == 462 || GetVehicleModel(vid) == 463 || GetVehicleModel(vid) == 468 || GetVehicleModel(vid) == 471 || GetVehicleModel(vid) == 521 || GetVehicleModel(vid) == 522 || GetVehicleModel(vid) == 523)
					return SendClientMessage(playerid,-1, "Nu poti tracta acest vehicul!");
					
				if(IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid))) {
					DetachTrailerFromVehicle(GetPlayerVehicleID(playerid));
					DisablePlayerCheckpointEx(playerid);
					gPlayerCheckpointStatus[playerid] = CHECKPOINT_NONE;
				}
				else {
					if(CP[playerid] != 0 || targetfind[playerid] != -1) return ShowPlayerDialog(playerid, DIALOG_CHECKPOINT, DIALOG_STYLE_MSGBOX, "Checkpoint", "Ai deja un checkpoint activ.\nDoresti sa-l anulezi? Daca da, apasa pe 'Ok'.", "Ok", "Anuleaza");
					new Float: hp;
					GetVehicleHealth(vid, hp);
					if(hp >= 900) return SCM(playerid, COLOR_LGREEN, "Eroare: Vehiculul pe care vrei sa-l tractezi are peste 900.0 HP!");
					SetPVarFloat(playerid, "VehHP", hp);
					AttachTrailerToVehicle(vid,GetPlayerVehicleID(playerid));
					new rand;
					rand = random(sizeof(TowCarCk));
					SetPlayerCheckpointEx(playerid, TowCarCk[rand][0],TowCarCk[rand][1],TowCarCk[rand][2], 6);
					CP[playerid] = 34;
					if(idd != 0) {
						new string[180];
						format(string, 256, "Ai tractat vehiculul lui %s.", CarInfo[idd][cOwner]);
						SCM(playerid, -1, string);	
					}
				}
			}
		}
	}
	return 1;
}

 

Edited by Barrio
Link to comment
Share on other sites

  • Hall of Flame🔥

Topic-ul a fost șters deoarece nu ai respectat modelul de postare. Te rugăm sa revii cu alt topic in care să respecți modelul.

Topic șters!

ezgif-com-gif-maker-1-00000.png

Not So Zen SRL

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...