DistanceFromCharacter (Method)

DistanceFromCharacter( Vector3 point )
Returns float
Description: Returns the distance between the character's head and a given Vector3 point. Returns 0 if the player has no character.
Member of: Player, PseudoPlayer


Example

This code will print the distance of each player's character from the origin (0, 0, 0):

for _, player in pairs(game.Players:GetPlayers()) do
	print(player:DistanceFromCharacter(Vector3.new(0, 0, 0)))
end