Get rid of s_char. Callers changed.
extern s_char dirch[];
/* src/lib/subs/paths.c */
-extern s_char *getpath(s_char *, s_char *, coord, coord, int, int,
- int, int);
+extern char *getpath(char *, char *, coord, coord, int, int, int);
extern double fcost(struct sctstr *, natid);
extern double ncost(struct sctstr *, natid);
extern double pathtoxy(s_char *, coord *, coord *,
}
ax = x;
ay = y;
- if (getpath(flightpath, player->argp[5], ax, ay, 0, 0, 0, P_FLYING) == 0
+ if (getpath(flightpath, player->argp[5], ax, ay, 0, 0, P_FLYING) == 0
|| *flightpath == 0)
return RET_SYN;
tx = ax;
}
ax = x;
ay = y;
- if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, 0, P_FLYING) == 0
+ if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, P_FLYING) == 0
|| *flightpath == 0)
return RET_SYN;
tx = ax;
}
ax = x;
ay = y;
- if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, 0, P_FLYING) == 0
+ if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, P_FLYING) == 0
|| *flightpath == 0)
return RET_SYN;
tx = ax;
}
ax = x;
ay = y;
- if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, 0, P_FLYING) == 0
+ if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, P_FLYING) == 0
|| *flightpath == 0)
return RET_SYN;
tx = ax;
}
ax = x;
ay = y;
- if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, 0, P_FLYING) == 0
+ if (getpath(flightpath, player->argp[4], ax, ay, 0, 0, P_FLYING) == 0
|| *flightpath == 0)
return RET_SYN;
tx = ax;
pr("Ship #%d at %s\n", ship.shp_uid,
xyas(ship.shp_x, ship.shp_y, ship.shp_own));
cp = getpath(navpath, player->argp[2],
- ship.shp_x, ship.shp_y, 0, 0, 0, P_SAILING);
+ ship.shp_x, ship.shp_y, 0, 0, P_SAILING);
if (!check_ship_ok(&ship))
continue;
if (!player->aborted) {
* move commands, and isn't valid for those commands
* which do not accept partial moves.
*/
-s_char *
-getpath(s_char *buf, s_char *arg, coord x, coord y, int onlyown,
- int showdes, int showxy, int destinations)
+char *
+getpath(char *buf, char *arg, coord x, coord y, int onlyown,
+ int showdes, int destinations)
{
- s_char *p = buf;
- s_char *bp;
- s_char prompt[128];
+ char *p = buf;
+ char *bp;
+ char prompt[128];
coord dx, dy;
struct sctstr sect, dsect;
coord nx, ny;
int dir;
- s_char *execute;
double mv_cost;
if (arg) {
*p = 0;
}
- if (showxy)
- execute = " & '%c' to execute\n";
- else
- execute = "\n";
-
getsect(x, y, §);
nx = x;
ny = y;
dir = chkdir(*p, DIR_STOP, DIR_LAST);
if (dir < 0) {
pr("\"%c\" is not legal...", *p);
- direrr("'%c' to stop", (s_char *)0, execute);
+ direrr("'%c' to stop\n", NULL, NULL);
*p = 0;
break;
}