Why don't Work?
#1

Код:
if (PRESSED(KEY_SUBMISSION ))
	{
		new vehicleid = GetPlayerVehicleID(playerid);
		new model = GetVehicleModel(vehicleid);
		new string[126];
		GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);

		if(IsPlayerInVehicle(playerid, vehicleid))
		{
			if(IsPlayerDriver(playerid))
			{
			    if(model != 509 || model != 481 || model != 510)
				{
					if(engine != 1)
					{
						engine = 1;
						SetVehicleParamsEx(vehicleid,1,lights,alarm,doors,bonnet,boot,objective);
						format(string, sizeof(string), "* %s a pornit motor-ul la %s",pName,GetVehicleName(GetPlayerVehicleID(playerid)));
  						ProxDetector(20.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
						return 1;
					}
						else
					{
						engine = 0;
 						SetVehicleParamsEx(vehicleid,0,lights,alarm,doors,bonnet,boot,objective);
						format(string, sizeof(string), "* %s a oprit motor-ul la %s",pName,GetVehicleName(GetPlayerVehicleID(playerid)));
						ProxDetector(20.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
						return 1;
					}
				}
//---------------------------------------------This don't Work
				if(model == 509 || model == 481 || model == 510)
				{
					if(engine != 1)
					{
						engine = 1;
						SetVehicleParamsEx(vehicleid,1,lights,alarm,doors,bonnet,boot,objective);
						format(string, sizeof(string), "* %s a ridicat cric-ul la %s",pName,GetVehicleName(GetPlayerVehicleID(playerid)));
  						ProxDetector(20.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
						return 1;
					}
						else
					{
						engine = 0;
 						SetVehicleParamsEx(vehicleid,0,lights,alarm,doors,bonnet,boot,objective);
						format(string, sizeof(string), "* %s a pus cric-ul la %s",pName,GetVehicleName(GetPlayerVehicleID(playerid)));
						ProxDetector(20.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
						return 1;
//-------------------------------------------------------
					}
				}
			}
			return engine;
		}
	}
	return 1;
}
If im on BMX and i press 2 server say %s a oprit motor-ul la %s <==== %s stop engine on %s



Sorry my english
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)