how to make the car dissapear and not respawn after 2 minutes ?
#4

Ok, I have something like this:

Код HTML:
new vehicleid;
// spawning the vehicle
				case 0:
				{
		            GetPlayerFacingAngle(playerid, angle);
		            GetPlayerPos(playerid, x, y, z);
					ticau_veh1 = CreateVehicle(481, x, y, z, angle, 144, 145, 125, 0);
					PutPlayerInVehicle(playerid,ticau_veh1,0);
					vehicleid = GetPlayerVehicleID(playerid);
					i[playerid] = 1;
					reset1(playerid);
					destroy1(playerid, vehicleid);
					return 1;
				}



public destroy1(playerid, vehicleid)
{
    SetTimerEx("destroy2",1000,true,"d",playerid);
	return 1;
}


forward destroy2(playerid, vehicleid);
public destroy2(playerid, vehicleid)
{

	if (IsPlayerInVehicle(playerid, vehicleid) == 0)
	{
 		DestroyVehicle(vehicleid);

	} else {
	destroy1(playerid, vehicleid);
	}
	
	return 1;
}
But it's not working . ( i can compile it BUT the vehicle is not dissapearing)
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)