What Function Can I Use To...
#1

what function or code can i use to check if a player with an object attached to him/herself is within a certain range of a vehicle ?

example: player goes to object picks it up, walks over to car and when they get within a certain distance of the car the object gets dettached or destroyed as if it has been put into the car.
Reply
#2

pawn Код:
if(IsPlayerInRangeOfPoint(playerid_with_attached_object, range, car_x, car_y, car_z))
{
    // The player is near the vehicle
}
More info: https://sampwiki.blast.hk/wiki/IsPlayerInRangeOfPoint
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)