[HELP] Determine if a player is near a specific object
#4

Quote:
Originally Posted by N3cromancer
Посмотреть сообщение
If you use dynamic objects you can use this function to check if a player is near of an dynamic object (mine)

PHP код:
stock IsPlayerNearDynamicObject(playerid, objectid, float:radius)
{
    new 
Float:oX, Float:oY, Float:oZ;
    
    
GetDynamicObjectPos(objectid, oX, oY, oZ);
    
    return 
IsPlayerInRangeOfPoint(playerid, radius, oX, oY, oZ);
} 
Thank you for your quick response,

How do you know if that DynamicObject is a landline, not a random object?
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)