Replace pln_onewaymission() by pln_where_to_land()

New function reads and returns target sector/ship.  Avoids reading the
target sector unnecessarily.  Callers receive the target ship, not
just its number.  Next commit will put it to use.
This commit is contained in:
Markus Armbruster 2012-06-23 20:36:48 +02:00
parent 41b2fa433f
commit d9a915a05b
4 changed files with 41 additions and 40 deletions

View file

@ -504,7 +504,7 @@ extern void pln_prewrite(int, void *, void *);
extern int get_planes(struct nstr_item *, struct nstr_item *,
char *, char *);
extern struct sctstr *get_assembly_point(char *, struct sctstr *, char *);
extern int pln_onewaymission(struct sctstr *, int *, int *);
extern int pln_where_to_land(coord, coord, union empobj_storage *, int *);
extern int pln_oneway_to_carrier_ok(struct emp_qelem *,
struct emp_qelem *, int);
extern void pln_newlanding(struct emp_qelem *, coord, coord, int);