Break lines more tastefully.
This commit is contained in:
parent
fcc0162188
commit
5b4b3a13cb
40 changed files with 220 additions and 229 deletions
|
@ -137,8 +137,8 @@ add(void)
|
|||
snxtitem_all(&ni, EF_LAND);
|
||||
while (nxtitem(&ni, &land)) {
|
||||
if (land.lnd_own == coun) {
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_own = 0;
|
||||
pr("Land unit %d wiped\n", land.lnd_uid);
|
||||
putland(land.lnd_uid, &land);
|
||||
|
|
|
@ -146,10 +146,10 @@ anti(void)
|
|||
sect.sct_item[I_MILIT] = ache;
|
||||
if (sect.sct_own == sect.sct_oldown)
|
||||
sect.sct_oldown = 0;
|
||||
makelost(EF_SECTOR, sect.sct_own, 0, sect.sct_x,
|
||||
sect.sct_y);
|
||||
makenotlost(EF_SECTOR, sect.sct_oldown, 0, sect.sct_x,
|
||||
sect.sct_y);
|
||||
makelost(EF_SECTOR, sect.sct_own, 0,
|
||||
sect.sct_x, sect.sct_y);
|
||||
makenotlost(EF_SECTOR, sect.sct_oldown, 0,
|
||||
sect.sct_x, sect.sct_y);
|
||||
sect.sct_own = sect.sct_oldown;
|
||||
sect.sct_off = 1; /* Turn the sector off */
|
||||
putsect(§);
|
||||
|
|
|
@ -545,8 +545,8 @@ ship_bomb(struct emp_qelem *list, struct sctstr *target)
|
|||
if (gun > 0) {
|
||||
shell = ship.shp_item[I_SHELL];
|
||||
if (shell <= 0)
|
||||
shell = supply_commod(ship.shp_own, ship.shp_x,
|
||||
ship.shp_y, I_SHELL, 1);
|
||||
shell = supply_commod(ship.shp_own,
|
||||
ship.shp_x, ship.shp_y, I_SHELL, 1);
|
||||
}
|
||||
mcp = &mchr[(int)ship.shp_type];
|
||||
if (gun > 0 && shell > 0 && !(mcp->m_flags & M_SUB)) {
|
||||
|
@ -694,8 +694,8 @@ plane_bomb(struct emp_qelem *list, struct sctstr *target)
|
|||
own = plane.pln_own;
|
||||
if (dam > plane.pln_effic) {
|
||||
plane.pln_effic = 0;
|
||||
makelost(EF_PLANE, plane.pln_own, plane.pln_uid, plane.pln_x,
|
||||
plane.pln_y);
|
||||
makelost(EF_PLANE, plane.pln_own, plane.pln_uid,
|
||||
plane.pln_x, plane.pln_y);
|
||||
plane.pln_own = 0;
|
||||
} else
|
||||
plane.pln_effic -= dam;
|
||||
|
|
|
@ -390,8 +390,8 @@ build_ship(struct sctstr *sp, struct mchrstr *mp, short *vec, int tlev)
|
|||
|
||||
if (sp->sct_pstage == PLG_INFECT)
|
||||
ship.shp_pstage = PLG_EXPOSED;
|
||||
makenotlost(EF_SHIP, ship.shp_own, ship.shp_uid, ship.shp_x,
|
||||
ship.shp_y);
|
||||
makenotlost(EF_SHIP, ship.shp_own, ship.shp_uid,
|
||||
ship.shp_x, ship.shp_y);
|
||||
putship(ship.shp_uid, &ship);
|
||||
pr("%s", prship(&ship));
|
||||
pr(" built in sector %s\n", xyas(sp->sct_x, sp->sct_y, player->cnum));
|
||||
|
@ -516,8 +516,8 @@ build_land(struct sctstr *sp, struct lchrstr *lp, short *vec, int tlev)
|
|||
if (sp->sct_pstage == PLG_INFECT)
|
||||
land.lnd_pstage = PLG_EXPOSED;
|
||||
putland(nstr.cur, &land);
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
pr("%s", prland(&land));
|
||||
pr(" built in sector %s\n", xyas(sp->sct_x, sp->sct_y, player->cnum));
|
||||
return 1;
|
||||
|
@ -807,8 +807,8 @@ build_plane(struct sctstr *sp, struct plchrstr *pp, short *vec, int tlev)
|
|||
vec[I_HCM] -= hcm;
|
||||
vec[I_MILIT] -= mil;
|
||||
|
||||
makenotlost(EF_PLANE, plane.pln_own, plane.pln_uid, plane.pln_x,
|
||||
plane.pln_y);
|
||||
makenotlost(EF_PLANE, plane.pln_own, plane.pln_uid,
|
||||
plane.pln_x, plane.pln_y);
|
||||
putplane(plane.pln_uid, &plane);
|
||||
pr("%s built in sector %s\n", prplane(&plane),
|
||||
xyas(sp->sct_x, sp->sct_y, player->cnum));
|
||||
|
|
|
@ -218,8 +218,8 @@ grab_sect(struct sctstr *sp, natid to)
|
|||
prplane(pp), cname(player->cnum));
|
||||
makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x, pp->pln_y);
|
||||
pp->pln_own = to;
|
||||
makenotlost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
|
||||
pp->pln_y);
|
||||
makenotlost(EF_PLANE, pp->pln_own, pp->pln_uid,
|
||||
pp->pln_x, pp->pln_y);
|
||||
pp->pln_mobil = 0;
|
||||
pp->pln_mission = 0;
|
||||
putplane(pp->pln_uid, pp);
|
||||
|
@ -235,8 +235,8 @@ grab_sect(struct sctstr *sp, natid to)
|
|||
prnuke(np), cname(player->cnum));
|
||||
makelost(EF_NUKE, np->nuk_own, np->nuk_uid, np->nuk_x, np->nuk_y);
|
||||
np->nuk_own = to;
|
||||
makenotlost(EF_NUKE, np->nuk_own, np->nuk_uid, np->nuk_x,
|
||||
np->nuk_y);
|
||||
makenotlost(EF_NUKE, np->nuk_own, np->nuk_uid,
|
||||
np->nuk_x, np->nuk_y);
|
||||
putnuke(ni.cur, np);
|
||||
}
|
||||
|
||||
|
@ -347,8 +347,8 @@ grab_ship(struct shpstr *sp, natid to)
|
|||
prplane(pp), cname(player->cnum));
|
||||
makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x, pp->pln_y);
|
||||
pp->pln_own = to;
|
||||
makenotlost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
|
||||
pp->pln_y);
|
||||
makenotlost(EF_PLANE, pp->pln_own, pp->pln_uid,
|
||||
pp->pln_x, pp->pln_y);
|
||||
pp->pln_mobil = 0;
|
||||
pp->pln_mission = 0;
|
||||
putplane(pp->pln_uid, pp);
|
||||
|
|
|
@ -483,13 +483,11 @@ doland(char op, int arg, char *p, struct sctstr *sect)
|
|||
xyas(sect->sct_x, sect->sct_y, player->cnum),
|
||||
cname(sect->sct_own), sect->sct_own, cname(newown), newown);
|
||||
if (sect->sct_own) {
|
||||
makelost(EF_SECTOR, sect->sct_own, 0, sect->sct_x,
|
||||
sect->sct_y);
|
||||
makelost(EF_SECTOR, sect->sct_own, 0,
|
||||
sect->sct_x, sect->sct_y);
|
||||
wu(player->cnum, sect->sct_own,
|
||||
"Sector %s lost to deity intervention\n", xyas(sect->sct_x,
|
||||
sect->sct_y,
|
||||
sect->
|
||||
sct_own));
|
||||
"Sector %s lost to deity intervention\n",
|
||||
xyas(sect->sct_x, sect->sct_y, sect->sct_own));
|
||||
}
|
||||
benefit(sect->sct_own, 0);
|
||||
sect->sct_own = newown;
|
||||
|
@ -808,15 +806,15 @@ doship(char op, int arg, char *p, struct shpstr *ship)
|
|||
if (arg && arg < MAXNOC) {
|
||||
wu(player->cnum, (natid)arg,
|
||||
"%s given to you by deity intervention!\n", prship(ship));
|
||||
makelost(EF_SHIP, ship->shp_own, ship->shp_uid, ship->shp_x,
|
||||
ship->shp_y);
|
||||
makelost(EF_SHIP, ship->shp_own, ship->shp_uid,
|
||||
ship->shp_x, ship->shp_y);
|
||||
ship->shp_own = (natid)arg;
|
||||
makenotlost(EF_SHIP, ship->shp_own, ship->shp_uid, ship->shp_x,
|
||||
ship->shp_y);
|
||||
makenotlost(EF_SHIP, ship->shp_own, ship->shp_uid,
|
||||
ship->shp_x, ship->shp_y);
|
||||
} else if (!arg) {
|
||||
ship->shp_effic = 0;
|
||||
makelost(EF_SHIP, ship->shp_own, ship->shp_uid, ship->shp_x,
|
||||
ship->shp_y);
|
||||
makelost(EF_SHIP, ship->shp_own, ship->shp_uid,
|
||||
ship->shp_x, ship->shp_y);
|
||||
ship->shp_own = (natid)0;
|
||||
}
|
||||
break;
|
||||
|
@ -925,14 +923,14 @@ dounit(char op, int arg, char *p, struct lndstr *land)
|
|||
if (arg && arg < MAXNOC) {
|
||||
wu(player->cnum, (natid)arg,
|
||||
"%s given to you by deity intervention!\n", prland(land));
|
||||
makelost(EF_LAND, land->lnd_own, land->lnd_uid, land->lnd_x,
|
||||
land->lnd_y);
|
||||
makelost(EF_LAND, land->lnd_own, land->lnd_uid,
|
||||
land->lnd_x, land->lnd_y);
|
||||
land->lnd_own = (natid)arg;
|
||||
makenotlost(EF_LAND, land->lnd_own, land->lnd_uid, land->lnd_x,
|
||||
land->lnd_y);
|
||||
makenotlost(EF_LAND, land->lnd_own, land->lnd_uid,
|
||||
land->lnd_x, land->lnd_y);
|
||||
} else if (!arg) {
|
||||
makelost(EF_LAND, land->lnd_own, land->lnd_uid, land->lnd_x,
|
||||
land->lnd_y);
|
||||
makelost(EF_LAND, land->lnd_own, land->lnd_uid,
|
||||
land->lnd_x, land->lnd_y);
|
||||
land->lnd_effic = 0;
|
||||
land->lnd_own = (natid)0;
|
||||
}
|
||||
|
|
|
@ -139,8 +139,8 @@ fuel(void)
|
|||
|
||||
if (sect.sct_effic < 2) {
|
||||
pr("The harbor at %s is not 2%% efficient yet.\n",
|
||||
xyas(item.ship.shp_x,
|
||||
item.ship.shp_y, player->cnum));
|
||||
xyas(item.ship.shp_x, item.ship.shp_y,
|
||||
player->cnum));
|
||||
harbor = 0;
|
||||
}
|
||||
if ((sect.sct_own != player->cnum) && sect.sct_own)
|
||||
|
|
|
@ -159,8 +159,8 @@ laun(void)
|
|||
if (retval != RET_OK)
|
||||
return retval;
|
||||
if (gone) {
|
||||
makelost(EF_PLANE, plane.pln_own, plane.pln_uid, plane.pln_x,
|
||||
plane.pln_y);
|
||||
makelost(EF_PLANE, plane.pln_own, plane.pln_uid,
|
||||
plane.pln_x, plane.pln_y);
|
||||
plane.pln_own = 0;
|
||||
putplane(plane.pln_uid, &plane);
|
||||
}
|
||||
|
|
|
@ -460,11 +460,11 @@ load_plane_ship(struct sctstr *sectp, struct shpstr *sp, int noisy,
|
|||
sprintf(buf, "loaded on your %s at %s",
|
||||
prship(sp), xyas(sp->shp_x, sp->shp_y, sp->shp_own));
|
||||
gift(sp->shp_own, player->cnum, &pln, EF_PLANE, buf);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
pln.pln_own = sp->shp_own;
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
pln.pln_mission = 0;
|
||||
putplane(pln.pln_uid, &pln);
|
||||
} else {
|
||||
|
@ -478,11 +478,11 @@ load_plane_ship(struct sctstr *sectp, struct shpstr *sp, int noisy,
|
|||
dchr[sectp->sct_type].d_name,
|
||||
xyas(sectp->sct_x, sectp->sct_y, sectp->sct_own));
|
||||
gift(sectp->sct_own, player->cnum, &pln, EF_PLANE, buf);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
pln.pln_own = sectp->sct_own;
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
putplane(pln.pln_uid, &pln);
|
||||
}
|
||||
pr("%s %s %s at %s.\n",
|
||||
|
@ -631,11 +631,11 @@ load_land_ship(struct sctstr *sectp, struct shpstr *sp, int noisy,
|
|||
sprintf(buf, "loaded on your %s at %s",
|
||||
prship(sp), xyas(sp->shp_x, sp->shp_y, sp->shp_own));
|
||||
gift(sp->shp_own, player->cnum, &land, EF_LAND, buf);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_own = sp->shp_own;
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_ship = sp->shp_uid;
|
||||
land.lnd_harden = 0;
|
||||
land.lnd_mission = 0;
|
||||
|
@ -875,11 +875,11 @@ load_plane_land(struct sctstr *sectp, struct lndstr *lp, int noisy,
|
|||
sprintf(buf, "loaded on %s at %s",
|
||||
prland(lp), xyas(lp->lnd_x, lp->lnd_y, lp->lnd_own));
|
||||
gift(lp->lnd_own, player->cnum, &pln, EF_PLANE, buf);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
pln.pln_own = lp->lnd_own;
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
putplane(pln.pln_uid, &pln);
|
||||
} else {
|
||||
if (!take_plane_off_land(&pln, lp)) {
|
||||
|
@ -891,11 +891,11 @@ load_plane_land(struct sctstr *sectp, struct lndstr *lp, int noisy,
|
|||
sprintf(buf, "unloaded at your sector at %s",
|
||||
xyas(sectp->sct_x, sectp->sct_y, sectp->sct_own));
|
||||
gift(sectp->sct_own, player->cnum, &pln, EF_PLANE, buf);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makelost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
pln.pln_own = sectp->sct_own;
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid, pln.pln_x,
|
||||
pln.pln_y);
|
||||
makenotlost(EF_PLANE, pln.pln_own, pln.pln_uid,
|
||||
pln.pln_x, pln.pln_y);
|
||||
putplane(pln.pln_uid, &pln);
|
||||
}
|
||||
pr("%s %s %s at %s.\n",
|
||||
|
@ -1090,11 +1090,11 @@ load_land_land(struct sctstr *sectp, struct lndstr *lp, int noisy,
|
|||
sprintf(buf, "loaded on your %s at %s",
|
||||
prland(lp), xyas(lp->lnd_x, lp->lnd_y, lp->lnd_own));
|
||||
gift(lp->lnd_own, player->cnum, &land, EF_LAND, buf);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_own = lp->lnd_own;
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_land = lp->lnd_uid;
|
||||
land.lnd_harden = 0;
|
||||
land.lnd_mission = 0;
|
||||
|
@ -1125,11 +1125,11 @@ load_land_land(struct sctstr *sectp, struct lndstr *lp, int noisy,
|
|||
dchr[sectp->sct_type].d_name,
|
||||
xyas(sectp->sct_x, sectp->sct_y, sectp->sct_own));
|
||||
gift(sectp->sct_own, player->cnum, &land, EF_LAND, buf);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_own = sectp->sct_own;
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_land = -1;
|
||||
lp->lnd_nland--;
|
||||
putland(land.lnd_uid, &land);
|
||||
|
|
|
@ -334,8 +334,9 @@ multifire(void)
|
|||
}
|
||||
shell = fship.shp_item[I_SHELL];
|
||||
if (shell < 2)
|
||||
shell += supply_commod(fship.shp_own, fship.shp_x,
|
||||
fship.shp_y, I_SHELL, 2 - shell);
|
||||
shell += supply_commod(fship.shp_own,
|
||||
fship.shp_x, fship.shp_y,
|
||||
I_SHELL, 2 - shell);
|
||||
if (shell <= 0) {
|
||||
pr("Klick! ...\n");
|
||||
continue;
|
||||
|
@ -426,8 +427,8 @@ multifire(void)
|
|||
fy = fsect.sct_y;
|
||||
if (fsect.sct_own != player->cnum ||
|
||||
fsect.sct_type != SCT_FORTR) {
|
||||
pr("No fortress at %s\n", xyas(fsect.sct_x,
|
||||
fsect.sct_y, player->cnum));
|
||||
pr("No fortress at %s\n",
|
||||
xyas(fsect.sct_x, fsect.sct_y, player->cnum));
|
||||
continue;
|
||||
}
|
||||
if (target == targ_land) {
|
||||
|
@ -444,8 +445,9 @@ multifire(void)
|
|||
}
|
||||
shell = fsect.sct_item[I_SHELL];
|
||||
if (shell <= 0)
|
||||
shell += supply_commod(fsect.sct_own, fsect.sct_x,
|
||||
fsect.sct_y, I_SHELL, 1);
|
||||
shell += supply_commod(fsect.sct_own,
|
||||
fsect.sct_x, fsect.sct_y,
|
||||
I_SHELL, 1);
|
||||
if (shell <= 0) {
|
||||
pr("Klick! ...\n");
|
||||
continue;
|
||||
|
@ -793,7 +795,8 @@ quiet_bigdef(int attacker, struct emp_qelem *list, natid own, natid aown,
|
|||
|
||||
if (mchr[(int)ship.shp_type].m_flags & M_SUB) {
|
||||
if (shell < SHP_TORP_SHELLS)
|
||||
shell += supply_commod(ship.shp_own, ship.shp_x, ship.shp_y,
|
||||
shell += supply_commod(ship.shp_own,
|
||||
ship.shp_x, ship.shp_y,
|
||||
I_SHELL, SHP_TORP_SHELLS - shell);
|
||||
if (shell < SHP_TORP_SHELLS)
|
||||
continue;
|
||||
|
@ -834,8 +837,8 @@ quiet_bigdef(int attacker, struct emp_qelem *list, natid own, natid aown,
|
|||
continue;
|
||||
/* must have gun, shell, and milit to fire */
|
||||
if (shell < 1)
|
||||
shell += supply_commod(ship.shp_own, ship.shp_x, ship.shp_y,
|
||||
I_SHELL, 1);
|
||||
shell += supply_commod(ship.shp_own,
|
||||
ship.shp_x, ship.shp_y, I_SHELL, 1);
|
||||
/* only need 1 shell, so don't check that */
|
||||
if (shell < 1)
|
||||
continue;
|
||||
|
|
|
@ -50,20 +50,19 @@
|
|||
#include "optlist.h"
|
||||
|
||||
/*
|
||||
** Command syntax:
|
||||
**
|
||||
** ORDER <ship> Show orders
|
||||
** ORDER <ship> c[ancel] Cancel orders
|
||||
** ORDER <ship> s[top] Suspend orders
|
||||
** ORDER <ship> r[esume] Resume orders
|
||||
** ORDER <ship> d[eclare] <dest1> Set destination
|
||||
** d[eclare] <dest1> <dest2>
|
||||
** ORDER <ship> l[evel] <field> <start/end> <comm> <level>
|
||||
**
|
||||
**
|
||||
** New syntax:
|
||||
** qorder <ship> display cargo levels
|
||||
** sorder <ship> display statistical info
|
||||
* Command syntax:
|
||||
*
|
||||
* ORDER <ship> Show orders
|
||||
* ORDER <ship> c[ancel] Cancel orders
|
||||
* ORDER <ship> s[top] Suspend orders
|
||||
* ORDER <ship> r[esume] Resume orders
|
||||
* ORDER <ship> d[eclare] <dest1> Set destination
|
||||
* d[eclare] <dest1> <dest2>
|
||||
* ORDER <ship> l[evel] <field> <start/end> <comm> <level>
|
||||
*
|
||||
* New syntax:
|
||||
* qorder <ship> display cargo levels
|
||||
* sorder <ship> display statistical info
|
||||
*/
|
||||
|
||||
int
|
||||
|
@ -471,9 +470,9 @@ sorde(void)
|
|||
else {
|
||||
/* ETA calculation */
|
||||
|
||||
c = BestShipPath(buf, ship.shp_x,
|
||||
ship.shp_y, ship.shp_destx[0],
|
||||
ship.shp_desty[0], ship.shp_own);
|
||||
c = BestShipPath(buf, ship.shp_x, ship.shp_y,
|
||||
ship.shp_destx[0], ship.shp_desty[0],
|
||||
ship.shp_own);
|
||||
if (!c)
|
||||
pr(" no route possible");
|
||||
else if (*c == 'h')
|
||||
|
|
|
@ -157,10 +157,9 @@ setsector(void)
|
|||
wu(player->cnum, amt,
|
||||
"Sector %s gained from deity intervention\n",
|
||||
xyas(sect.sct_x, sect.sct_y, amt));
|
||||
makelost(EF_SECTOR, sect.sct_own, 0, sect.sct_x,
|
||||
sect.sct_y);
|
||||
makelost(EF_SECTOR, sect.sct_own, 0,
|
||||
sect.sct_x, sect.sct_y);
|
||||
makenotlost(EF_SECTOR, amt, 0, sect.sct_x, sect.sct_y);
|
||||
|
||||
sect.sct_own = (natid)amt;
|
||||
putsect(§);
|
||||
}
|
||||
|
|
|
@ -261,8 +261,8 @@ plane_sona(struct emp_qelem *plane_list, int x, int y,
|
|||
tmcp = &mchr[(int)targ->shp_type];
|
||||
if (!(tmcp->m_flags & M_SUB))
|
||||
continue;
|
||||
if (roll(100) >
|
||||
pln_identchance(pp, shp_hardtarget(targ), EF_SHIP))
|
||||
if (roll(100) > pln_identchance(pp, shp_hardtarget(targ),
|
||||
EF_SHIP))
|
||||
continue;
|
||||
pingrange = MAX(targ->shp_visib, 10) * range / 10;
|
||||
vrange = pingrange * (pp->pln_effic / 200.0);
|
||||
|
@ -289,8 +289,8 @@ plane_sona(struct emp_qelem *plane_list, int x, int y,
|
|||
if (getrel(getnatp(targ->shp_own), pp->pln_own) < FRIENDLY &&
|
||||
roll(100) > pln_identchance(pp, shp_hardtarget(targ),
|
||||
EF_SHIP))
|
||||
if (roll(100) >
|
||||
pln_identchance(pp, shp_hardtarget(targ), EF_SHIP))
|
||||
if (roll(100) > pln_identchance(pp, shp_hardtarget(targ),
|
||||
EF_SHIP))
|
||||
mpr(pp->pln_own, "sub #%d %s\n", targ->shp_uid,
|
||||
xyas(targ->shp_x, targ->shp_y, pp->pln_own));
|
||||
else
|
||||
|
|
|
@ -180,8 +180,7 @@ spy(void)
|
|||
} else {
|
||||
insert(table, &t_len, nx, ny);
|
||||
spyline(&dsect);
|
||||
changed += map_set(player->cnum, dsect.sct_x,
|
||||
dsect.sct_y,
|
||||
changed += map_set(player->cnum, dsect.sct_x, dsect.sct_y,
|
||||
dchr[dsect.sct_type].d_mnem, 0);
|
||||
prunits(dsect.sct_x, dsect.sct_y);
|
||||
prplanes(dsect.sct_x, dsect.sct_y);
|
||||
|
@ -195,8 +194,7 @@ spy(void)
|
|||
if (nrecon && caught) {
|
||||
insert(table, &t_len, nx, ny);
|
||||
spyline(&dsect);
|
||||
changed += map_set(player->cnum, dsect.sct_x,
|
||||
dsect.sct_y,
|
||||
changed += map_set(player->cnum, dsect.sct_x, dsect.sct_y,
|
||||
dchr[dsect.sct_type].d_mnem, 0);
|
||||
prunits(dsect.sct_x, dsect.sct_y);
|
||||
prplanes(dsect.sct_x, dsect.sct_y);
|
||||
|
|
|
@ -272,11 +272,11 @@ tend_land(struct shpstr *tenderp, char *units)
|
|||
prship(&target), xyas(target.shp_x, target.shp_y,
|
||||
target.shp_own));
|
||||
gift(target.shp_own, player->cnum, &land, EF_LAND, buf);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makelost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_own = target.shp_own;
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid, land.lnd_x,
|
||||
land.lnd_y);
|
||||
makenotlost(EF_LAND, land.lnd_own, land.lnd_uid,
|
||||
land.lnd_x, land.lnd_y);
|
||||
land.lnd_ship = target.shp_uid;
|
||||
land.lnd_harden = 0;
|
||||
land.lnd_mission = 0;
|
||||
|
|
|
@ -352,9 +352,8 @@ fire_dchrg(struct shpstr *sp, struct shpstr *targ, int ntargets)
|
|||
gun = MIN(gun, sp->shp_glim);
|
||||
gun = MIN(gun, sp->shp_item[I_MILIT] / 2);
|
||||
|
||||
shells +=
|
||||
supply_commod(sp->shp_own, sp->shp_x, sp->shp_y, I_SHELL,
|
||||
(gun + 1) / 2 - shells);
|
||||
shells += supply_commod(sp->shp_own, sp->shp_x, sp->shp_y,
|
||||
I_SHELL, (gun + 1) / 2 - shells);
|
||||
|
||||
gun = MIN(gun, shells * 2);
|
||||
if (gun == 0)
|
||||
|
@ -403,8 +402,8 @@ fire_torp(struct shpstr *sp, struct shpstr *targ, int range, int ntargets)
|
|||
shells = sp->shp_item[I_SHELL];
|
||||
|
||||
if (shells < SHP_TORP_SHELLS)
|
||||
shells += supply_commod(sp->shp_own, sp->shp_x, sp->shp_y, I_SHELL,
|
||||
SHP_TORP_SHELLS - shells);
|
||||
shells += supply_commod(sp->shp_own, sp->shp_x, sp->shp_y,
|
||||
I_SHELL, SHP_TORP_SHELLS - shells);
|
||||
|
||||
if (sp->shp_item[I_GUN] == 0 || shells < SHP_TORP_SHELLS)
|
||||
return 0;
|
||||
|
|
|
@ -389,8 +389,8 @@ check_trade(void)
|
|||
case EF_NUKE:
|
||||
tg.nuk.nuk_x = trade.trd_x;
|
||||
tg.nuk.nuk_y = trade.trd_y;
|
||||
makelost(EF_NUKE, tg.nuk.nuk_own, tg.nuk.nuk_uid, tg.nuk.nuk_x,
|
||||
tg.nuk.nuk_y);
|
||||
makelost(EF_NUKE, tg.nuk.nuk_own, tg.nuk.nuk_uid,
|
||||
tg.nuk.nuk_x, tg.nuk.nuk_y);
|
||||
tg.nuk.nuk_own = trade.trd_maxbidder;
|
||||
makenotlost(EF_NUKE, tg.nuk.nuk_own, tg.nuk.nuk_uid,
|
||||
tg.nuk.nuk_x, tg.nuk.nuk_y);
|
||||
|
@ -430,8 +430,8 @@ check_trade(void)
|
|||
ship.shp_nland--;
|
||||
putship(ship.shp_uid, &ship);
|
||||
}
|
||||
makelost(EF_LAND, tg.lnd.lnd_own, tg.lnd.lnd_uid, tg.lnd.lnd_x,
|
||||
tg.lnd.lnd_y);
|
||||
makelost(EF_LAND, tg.lnd.lnd_own, tg.lnd.lnd_uid,
|
||||
tg.lnd.lnd_x, tg.lnd.lnd_y);
|
||||
tg.lnd.lnd_own = trade.trd_maxbidder;
|
||||
makenotlost(EF_LAND, tg.lnd.lnd_own, tg.lnd.lnd_uid,
|
||||
tg.lnd.lnd_x, tg.lnd.lnd_y);
|
||||
|
|
|
@ -133,8 +133,8 @@ vers(void)
|
|||
}
|
||||
pr("\n");
|
||||
pr("\t\t\t\tSectors\tShips\tPlanes\tUnits\n");
|
||||
pr("Maximum mobility\t\t%d\t%d\t%d\t%d\n", sect_mob_max,
|
||||
ship_mob_max, plane_mob_max, land_mob_max);
|
||||
pr("Maximum mobility\t\t%d\t%d\t%d\t%d\n",
|
||||
sect_mob_max, ship_mob_max, plane_mob_max, land_mob_max);
|
||||
pr("Max mob gain per update\t\t%d\t%d\t%d\t%d\n",
|
||||
(int)(sect_mob_scale * (float)etu_per_update),
|
||||
(int)(ship_mob_scale * (float)etu_per_update),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue