use
function playerToPoint(radius,player,x,y,z)
local px,py,pz=getElementPosition(player)
return getDistanceBetweenPoints3D(x,y,z,px,py,pz) <= radius
end
, but read the notes i posted before
might you did not understand, but x <=y returns true if y is not smaller then x, false othervise. so
return x<= y
will return given case.
same applys in that function
this is long version witch does same(dont use it, just an example for you to understand):
function playerToPoint(radius,player,x,y,z)
local playerx,playery,playerz = getElementPosition(player)
local distance = getDistanceBetweenPoints3D(x,y,z,playerx,playery,playerz)
if distance <= radius then
return true
else
return false
end
end