Trailer
#1

Hi,

How to check if trailer attached to any vehicle or not? i know that there is function IsTrailerAttachedToVehicle, but need check any vehicle
Reply
#2

Use
pawn Код:
if(IsTrailerAttachedToVehicle(vehicleid))
{
   //do something here
}
This gets the ID of the trailer attached to the vehicle
pawn Код:
new trailerid = GetVehicleTrailer(vehicleid);
Reply
#3

I'm certain you can use a simple vehicle loop for this..

Код:
for(new carid=0; carid < MAX_VEHICLES; carid++)
{
	if(IsTrailerAttachedToVehicle(carid))
	{
	    printf("Vehicle %i has a trailer attached", carid);
	}
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)