#ifndef _RANGES_H
#define _RANGES_H

#include "empire.h"

/*typedef struct _path
{
  int leng;
  int dir[10];
}_path;*/

typedef struct _target
{
  int player;
  int unit;
}_target;

void draw_attackrange(_unit u);
void undraw_attackrange(_unit u);
void draw_range(int plyr, int unitnum);
void clear_range();
//void range(int movetype, int movex, int movey, int tx, int ty, int left, int plyr, int first);
int in_range(_unit tmpr, int tx, int ty);
int in_range(int ox, int oy, int tx, int ty, int d);
int in_range(int plyr, int unitnum, int tx, int ty);
int tile_distance(int ax, int ay, int bx, int by);
int unit_nearby(int pn, int tilex, int tiley);
int get_rangemin(int type);
int get_rangemax(int type);
_target enemy_nearby(int pnum, int tilex, int tiley);
_target enemy_nearby(int pnum, int tilex, int tiley, int li, int lj);
_target enemy_in_range(int pnum, int tilex, int tiley, int type);
_target enemy_in_range(int pnum, int tilex, int tiley, int type, int si, int sj);

#endif
