Hello!
Does anyone know a script to find the nearest part from the player's character? That's all I want.
Hello!
Does anyone know a script to find the nearest part from the player's character? That's all I want.
get all the parts in workspace. create array with dictionaries that has part and magnitude between that part and character part (http://wiki.roblox.com/index.php?title=Magnitude) then loop through magnitudes and get the lowest number. part matching the lowest number in array is your desired part. this is just an idea and its kinda complicated but will probably work.
This discussion is preserved as it was. New answers, comments, and votes are closed.
3 comments
http://wiki.roblox.com/index.php?title=Magnitude
Thanks!
Np.