diff --git a/src/lib/commands/land.c b/src/lib/commands/land.c index bfdcbed4..bb70f452 100644 --- a/src/lib/commands/land.c +++ b/src/lib/commands/land.c @@ -45,14 +45,14 @@ int land(void) { - int nunits; + int nunits, noff; struct nstr_item ni; struct lndstr land; if (!snxtitem(&ni, EF_LAND, player->argp[1])) return RET_SYN; - nunits = 0; + nunits = noff = 0; while (nxtitem(&ni, &land)) { if (land.lnd_own == 0) continue; @@ -69,13 +69,15 @@ land(void) pr(" fl"); pr(" tch retr rd xl ln carry\n"); } + if (land.lnd_off) + noff++; if (player->god) pr("%3d ", land.lnd_own); pr("%4d ", ni.cur); pr("%-15.15s", lchr[(int)land.lnd_type].l_name); prxy(" %4d,%-4d", land.lnd_x, land.lnd_y, player->cnum); pr("%1.1s", &land.lnd_army); - pr(" %c%3d%%", land.lnd_off ? '=' : ' ', land.lnd_effic); + pr(" %c%3d%%", land.lnd_off ? '!' : ' ', land.lnd_effic); pr("%4d", land.lnd_item[I_MILIT]); pr("%4d", land.lnd_harden); pr("%4d", land.lnd_mobil); @@ -99,7 +101,11 @@ land(void) else pr("%s: No unit(s)\n", ""); return RET_FAIL; - } else - pr("%d unit%s\n", nunits, splur(nunits)); + } else { + pr("%d unit%s", nunits, splur(nunits)); + if (noff) + pr(", %d stopped (eff marked with !)", noff); + pr("\n"); + } return RET_OK; } diff --git a/src/lib/commands/nuke.c b/src/lib/commands/nuke.c index bd106f61..6c51498a 100644 --- a/src/lib/commands/nuke.c +++ b/src/lib/commands/nuke.c @@ -47,14 +47,14 @@ int nuke(void) { - int nnukes; + int nnukes, noff; struct nstr_item nstr; struct nukstr nuk; struct plnstr plane; if (!snxtitem(&nstr, EF_NUKE, player->argp[1])) return RET_SYN; - nnukes = 0; + nnukes = noff = 0; while (nxtitem(&nstr, &nuk)) { if (!player->owner || nuk.nuk_own == 0) continue; @@ -63,12 +63,14 @@ nuke(void) pr("own "); pr(" # nuke type x,y s eff tech carry burst\n"); } + if (nuk.nuk_off) + noff++; if (player->god) pr("%-3d ", nuk.nuk_own); pr("%4d %-19.19s ", nstr.cur, nchr[(int)nuk.nuk_type].n_name); prxy("%4d,%-4d", nuk.nuk_x, nuk.nuk_y, player->cnum); pr(" %1.1s %c%3d%% %4d", - &nuk.nuk_stockpile, nuk.nuk_off ? '=' : ' ', nuk.nuk_effic, + &nuk.nuk_stockpile, nuk.nuk_off ? '!' : ' ', nuk.nuk_effic, nuk.nuk_tech); if (nuk.nuk_plane >= 0) { getplane(nuk.nuk_plane, &plane); @@ -85,8 +87,12 @@ nuke(void) else pr("%s: No nuke(s)\n", ""); return RET_FAIL; - } else - pr("%d nuke%s\n", nnukes, splur(nnukes)); + } else { + pr("%d nuke%s", nnukes, splur(nnukes)); + if (noff) + pr(", %d stopped (eff marked with !)", noff); + pr("\n"); + } return RET_OK; } diff --git a/src/lib/commands/plan.c b/src/lib/commands/plan.c index 285080bd..69c883a8 100644 --- a/src/lib/commands/plan.c +++ b/src/lib/commands/plan.c @@ -47,13 +47,13 @@ int plan(void) { - int nplanes; + int nplanes, noff; struct nstr_item np; struct plnstr plane; if (!snxtitem(&np, EF_PLANE, player->argp[1])) return RET_SYN; - nplanes = 0; + nplanes = noff = 0; while (nxtitem(&np, &plane)) { if (!player->owner || plane.pln_own == 0) continue; @@ -62,12 +62,14 @@ plan(void) pr("own "); pr(" # type x,y w eff mu def tech ran hard carry special\n"); } + if (plane.pln_off) + noff++; if (player->god) pr("%3d ", plane.pln_own); pr("%4d %-19.19s ", np.cur, plchr[(int)plane.pln_type].pl_name); prxy("%4d,%-4d", plane.pln_x, plane.pln_y, player->cnum); pr(" %1.1s %c%3d%% %3d %3d %4d %3d %3d", - &plane.pln_wing, plane.pln_off ? '=' : ' ', plane.pln_effic, + &plane.pln_wing, plane.pln_off ? '!' : ' ', plane.pln_effic, plane.pln_mobil, plane.pln_def, plane.pln_tech, plane.pln_range, plane.pln_harden); if (plane.pln_ship >= 0) @@ -93,8 +95,12 @@ plan(void) else pr("%s: No plane(s)\n", ""); return RET_FAIL; - } else - pr("%d plane%s\n", nplanes, splur(nplanes)); + } else { + pr("%d plane%s", nplanes, splur(nplanes)); + if (noff) + pr(", %d stopped (eff marked with !)", noff); + pr("\n"); + } return RET_OK; } diff --git a/src/lib/commands/shi.c b/src/lib/commands/shi.c index 6371edd5..434011e6 100644 --- a/src/lib/commands/shi.c +++ b/src/lib/commands/shi.c @@ -45,14 +45,14 @@ int shi(void) { - int nships; + int nships, noff; struct nstr_item ni; struct shpstr ship; if (!snxtitem(&ni, EF_SHIP, player->argp[1])) return RET_SYN; - nships = 0; + nships = noff = 0; while (nxtitem(&ni, &ship)) { if (!player->owner || ship.shp_own == 0) continue; @@ -67,13 +67,15 @@ shi(void) pr(" fuel"); pr(" tech\n"); } + if (ship.shp_off) + noff++; if (player->god) pr("%3d ", ship.shp_own); pr("%4d ", ni.cur); pr("%-16.16s ", mchr[(int)ship.shp_type].m_name); prxy("%4d,%-4d ", ship.shp_x, ship.shp_y, player->cnum); pr("%1.1s", &ship.shp_fleet); - pr(" %c%3d%%", ship.shp_off ? '=' : ' ', ship.shp_effic); + pr(" %c%3d%%", ship.shp_off ? '!' : ' ', ship.shp_effic); pr("%4d", ship.shp_item[I_CIVIL]); pr("%4d", ship.shp_item[I_MILIT]); @@ -100,7 +102,11 @@ shi(void) else pr("%s: No ship(s)\n", ""); return RET_FAIL; - } else - pr("%d ship%s\n", nships, splur(nships)); + } else { + pr("%d ship%s", nships, splur(nships)); + if (noff) + pr(", %d stopped (eff marked with !)", noff); + pr("\n"); + } return RET_OK; }