Get distance between player and object
#1

Hello,
How I can get the distance between an object and player
Even if the object isn't from a custom map
Like radius in RemoveBuildingForPlayer
Reply
#2

use
GetObjectPos(objectid, x, y, z)

to get pos of object

and use GetPlayerDistanceFromPoint(playerid, x, y, z)
to get distance from that coordinates
Reply
#3

and how to get id of that specified object ?
Reply
#4

Quote:
Originally Posted by YouHack
Посмотреть сообщение
and how to get id of that specified object ?
new object = CreateDynamic...

object will be the ID
Reply
#5

talking about original objects, not custom
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)