/* -*- ObjC -*- */
#ifndef __included_unit_seeking_h
#define __included_unit_seeking_h

#include "unit.h"

#define FIND_CLOSEST_ALLY(x,y)		find_closest_unit(x, y, ALLY_LIST)
#define ANGLE_TO_CLOSEST_ALLY(x,y)	angle_towards_unit(x, y, FIND_CLOSEST_ALLY(x, y))

double angle_towards_unit(double x1, double y1, Unit *unit);
Unit *find_closest_unit_with_some_genius(double x, double y, double theta, double r, int lists);
Unit *find_closest_unit(double x, double y, int lists);
Unit *find_closest_ally_according_to_rotation(double x, double y, double theta);
BOOL unit_exists(Unit *unit, int lists);

#endif
