This is what I have tried, but this finds the Global distance:
distanceX = part1.CFrame.X - part2.CFrame.X
I have experimented with CFrame.lookVector, but I couldn't get that working either. Does anyone know how I can accomplish this?
This is what I have tried, but this finds the Global distance:
distanceX = part1.CFrame.X - part2.CFrame.X
I have experimented with CFrame.lookVector, but I couldn't get that working either. Does anyone know how I can accomplish this?
Vector.magnitude
print((part1.Position - part2.Position).magnitude)
This worked! Thankyou!
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
http://wiki.roblox.com/index.php?title=Magnitude <- Is this what you’re looking for?