Fix Vector3D.getMagnitude, improve getDistance