[Package Index | Mudlib Index | Effect Index]

File /obj/handlers/inherit/distance_handler.c

This file handles the distance checking stuff for figuring out how far apart two rooms or co-ordinates are.

Written by Rodion

Started Wed Jul 25 15:22:24 PDT 2001

Method index

Public Functions

These are functions that everyone can access.

query_distance_from_coords
int query_distance_from_coords(int * co_ord_one,
                               int * co_ord_two)

This method figures out the distance between two co-ordinates.

Parameters:
co_ord_one - the first co-ordinate
co_ord_two - the second co-ordinate

Returns:
the distance


query_distance_from_rooms
int query_distance_from_rooms(mixed one,
                              mixed two)

This method figures out the distance between two rooms and returns the result. The result will be in co-ordinate units.

Parameters:
one - the first room
two - the second room

Returns:
the distance between them