Function GridMap.worldToMap

Returns the coordinates of the grid cell containing the given point. pos should be in the GridMap's local coordinate space.

Vector3 worldToMap (
  const(Vector3) pos
) nothrow @nogc const;