Refactor missile interception code

Keep only the common part in msl_intercept(), and give it internal
linkage.  Wrap new msl_abm_intercept() and msl_asat_intercept() around
it.  They are simpler to use.
This commit is contained in:
Markus Armbruster 2009-10-10 18:26:31 -04:00
parent de2fae0ee6
commit 0060e48ea4
3 changed files with 51 additions and 51 deletions

View file

@ -492,11 +492,12 @@ extern int move_ground(struct sctstr *, struct sctstr *,
int, int *);
extern int fly_map(coord, coord);
/* mslsub.c */
extern int msl_intercept(coord, coord, natid, int, int, int, int);
extern int msl_hit(struct plnstr *, int, int, int, int, char *,
coord, coord, int);
extern void msl_sel(struct emp_qelem *, coord, coord, natid, int,
int, int);
extern int msl_abm_intercept(struct plnstr *, coord, coord, int);
extern int msl_asat_intercept(struct plnstr *, coord, coord);
/* mtch.c */
extern int comtch(char *, struct cmndstr *, int);
/* natarg.c */