# _std/macros/dist.dm

GET_DIST | Returns distance of two objects in tiles like get_dist but being inside another object doesn't break it and being on a different z-level returns INFINITY |
---|---|

IN_RANGE | Returns if A is in range of B given range |

GET_MANHATTAN_DIST | Returns the manhattan distance between two turfs or movable objects |

GET_SQUARED_EUCLIDEAN_DIST | Returns the squared euclidean distance between two turfs or movable objects This is helpful in cases where the exact distance is not needed, so you can avoid the sqrt |

GET_EUCLIDEAN_DIST | Returns the euclidean distance between two turfs or movable objects |

## Define Details

### GET_DIST

Returns distance of two objects in tiles like get_dist but being inside another object doesn't break it and being on a different z-level returns INFINITY

### GET_EUCLIDEAN_DIST

Returns the euclidean distance between two turfs or movable objects

### GET_MANHATTAN_DIST

Returns the manhattan distance between two turfs or movable objects

### GET_SQUARED_EUCLIDEAN_DIST

Returns the squared euclidean distance between two turfs or movable objects This is helpful in cases where the exact distance is not needed, so you can avoid the sqrt

### IN_RANGE

Returns if A is in range of B given range