]> git.pond.sub.org Git - empserver/commitdiff
Break lines more tastefully.
authorMarkus Armbruster <armbru@pond.sub.org>
Sun, 14 May 2006 07:52:20 +0000 (07:52 +0000)
committerMarkus Armbruster <armbru@pond.sub.org>
Sun, 14 May 2006 07:52:20 +0000 (07:52 +0000)
40 files changed:
src/lib/as/as.h
src/lib/commands/add.c
src/lib/commands/anti.c
src/lib/commands/bomb.c
src/lib/commands/buil.c
src/lib/commands/cede.c
src/lib/commands/edit.c
src/lib/commands/fuel.c
src/lib/commands/laun.c
src/lib/commands/load.c
src/lib/commands/mfir.c
src/lib/commands/orde.c
src/lib/commands/setsect.c
src/lib/commands/sona.c
src/lib/commands/spy.c
src/lib/commands/tend.c
src/lib/commands/torp.c
src/lib/commands/trad.c
src/lib/commands/vers.c
src/lib/common/bridgefall.c
src/lib/subs/aircombat.c
src/lib/subs/attsub.c
src/lib/subs/detonate.c
src/lib/subs/fortdef.c
src/lib/subs/land.c
src/lib/subs/lndsub.c
src/lib/subs/mission.c
src/lib/subs/plane.c
src/lib/subs/plnsub.c
src/lib/subs/ship.c
src/lib/subs/shpsub.c
src/lib/subs/supply.c
src/lib/subs/takeover.c
src/lib/update/finish.c
src/lib/update/human.c
src/lib/update/land.c
src/lib/update/mobility.c
src/lib/update/nav_util.c
src/lib/update/plane.c
src/lib/update/ship.c

index 74bbc83c86e831522de1bd5f659262bf08673a1f..98be3e30d5a2e9f13a475b42a98d88d51cef9b0e 100644 (file)
@@ -167,8 +167,8 @@ extern int as_search(struct as_data *adp);
 extern void as_delete(struct as_data *adp);
 extern void as_reset(struct as_data *adp);
 extern void as_stats(struct as_data *adp, FILE * fp);
-extern struct as_path *as_find_cachepath(coord fx,
-                                        coord fy, coord tx, coord ty);
+extern struct as_path *as_find_cachepath(coord fx, coord fy,
+                                        coord tx, coord ty);
 
 /* Functions that are "private" to algorithm */
 
index b3e6e45bf69e751405dc0517f20ea0c97d3f2adf..c6066a6d18e632eb8fa5c79bb7d42a2e09ae46fe 100644 (file)
@@ -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);
index 7ed7c415ecbf39f53483f4a129867f491870de02..7954ddbba7f12469fb88baaba286e15e841842f7 100644 (file)
@@ -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(&sect);
index 8a0306cdc4ba0449b956529bee314f4bea9324a5..5c0c18e99c04aa28dc5ecc6ef1a0fe772887947b 100644 (file)
@@ -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;
index 2262d913eaca70965cf85f09c09e3bd12fcaa9d9..a46d4ee7796b47124df0cca3baeb0d5d81bbdc0c 100644 (file)
@@ -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));
index 08817061a81161d1b0b34499f31fa36c222726c4..670e5af3bd4baf193d372cfa795aa5f1b5a2342d 100644 (file)
@@ -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);
index d8e94ee8dbe6edbf6bc702e6a19fdb87227f608d..10bb62e7f3641e36d7e7c217a15aa1e579e0d8a3 100644 (file)
@@ -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;
        }
index 210027cb56e10bfde5794ccae517bfd13e23f3da..a1cdaf85595ce1e4c1f9aeb0d29e766a14202a29 100644 (file)
@@ -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)
index 3bba721b2eaad2299d4fa844d039d5b5fa02641c..cb89198083ef7a855a185993b0c6b03160726757 100644 (file)
@@ -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);
        }
index 22b5b3745af18d8ab7c446d6293c54f67ee015ed..b3607b16c7eb57fcaf49f6241854a303e72c3dd6 100644 (file)
@@ -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);
index 5cf362a6e4abc7a0c55a6a2f7f9639e2cbd61d9b..03388d466e227339e31964c23a09d0b445b7d981 100644 (file)
@@ -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;
index 9bf9ce0895dca79cdd297ffb16f1cd5a71f66ec1..f087ea6af35b3b46f4c30850a6e39f27e09653c4 100644 (file)
 #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')
index 33935a457a70c3643f09dac58c660f4bc0e81567..8e9b373ac8ea8e19244dedbdf79136e23e6db6a1 100644 (file)
@@ -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(&sect);
            }
index 8691ad5b866b99795d1d0f46a5259cfdeae6156a..7600556f496123d1fda902c08c7b5d4d8a8f1831 100644 (file)
@@ -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
index a2c57457c033ecc030b64ced6382b034f7452af3..640fd94af9aa9a2a5d2f29ee40ec283c51be2a73 100644 (file)
@@ -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);
index 5f80bf81189a7a68494fd7207a1984d5ba33ba4e..203458e9461ad101e1ae348661860de8ccb2c6e4 100644 (file)
@@ -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;
index 80236c60cfd2fc38cfb8fe2d358b49eb50adeca7..bd742bcf48a28099854c99e40a81153c37b5885c 100644 (file)
@@ -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;
index e88082da3630e472b4c05d82eada25b58157eb11..f942d4b6c6c28f2ee093d4b0003682242fb134ea 100644 (file)
@@ -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);
index dbd554525ce478cfc823b1813f19fd604dfa60d4..cc1c72c1dd5d2158bff9155282b22575bfef94ac 100644 (file)
@@ -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),
index 8dcce78501482fbce083e87a4a51f3ddbce34ac6..6d6acc2897810a881e16d031f7e0894c0e1dadae 100644 (file)
@@ -126,8 +126,8 @@ knockdown(struct sctstr *sp, struct emp_qelem *list)
            mpr(land.lnd_own, "\07");
        mpr(land.lnd_own, "     AARGH! %s tumbles to its doom!\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 = 0;
        land.lnd_effic = 0;
        putland(land.lnd_uid, &land);
@@ -149,8 +149,8 @@ knockdown(struct sctstr *sp, struct emp_qelem *list)
            mpr(plane.pln_own, "\07");
        mpr(plane.pln_own, "     AARGH! %s tumbles to its doom!\n",
            prplane(&plane));
-       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;
        plane.pln_effic = 0;
        putplane(plane.pln_uid, &plane);
@@ -167,8 +167,8 @@ knockdown(struct sctstr *sp, struct emp_qelem *list)
            mpr(nuke.nuk_own, "\07");
        mpr(nuke.nuk_own, "     %s sinks to the bottom of the sea!\n",
            prnuke(&nuke));
-       makelost(EF_NUKE, nuke.nuk_own, nuke.nuk_uid, nuke.nuk_x,
-                nuke.nuk_y);
+       makelost(EF_NUKE, nuke.nuk_own, nuke.nuk_uid,
+                nuke.nuk_x, nuke.nuk_y);
        nuke.nuk_own = 0;
        nuke.nuk_effic = 0;
        putnuke(nuke.nuk_uid, &nuke);
index 8b3f8e2e616debf91e1018c2fb129d9e5b02e149..7d062b8a58e0eb40a2d0ff601ebf586fe4a33b11 100644 (file)
@@ -183,8 +183,8 @@ ac_encounter(struct emp_qelem *bomb_list, struct emp_qelem *esc_list,
        } else {
            PR(plane_owner, "flying over %s at %s\n",
               dchr[sect.sct_type].d_name, xyas(x, y, plane_owner));
-           changed += map_set(plane_owner, sect.sct_x,
-                              sect.sct_y, dchr[sect.sct_type].d_mnem, 0);
+           changed += map_set(plane_owner, sect.sct_x, sect.sct_y,
+                              dchr[sect.sct_type].d_mnem, 0);
        }
        if ((rel = getrel(over, plane_owner)) == ALLIED)
            continue;
@@ -310,8 +310,8 @@ ac_encounter(struct emp_qelem *bomb_list, struct emp_qelem *esc_list,
                    /* Flag that we intercepted */
                    intown = 1;
                    /* And now intercept again */
-                   ac_intercept(bomb_list, esc_list, &ilist[cn], cn, x,
-                                y);
+                   ac_intercept(bomb_list, esc_list, &ilist[cn],
+                                cn, x, y);
                }
            }
        }
@@ -336,8 +336,8 @@ ac_encounter(struct emp_qelem *bomb_list, struct emp_qelem *esc_list,
                if (!evaded) {
                    if (intown == -1) {
                        /* We haven't intercepted yet, so intercept */
-                       ac_intercept(bomb_list, esc_list, &ilist[cn], cn,
-                                    x, y);
+                       ac_intercept(bomb_list, esc_list, &ilist[cn],
+                                    cn, x, y);
                    }
                }
            }
@@ -837,8 +837,8 @@ ac_shipflak(struct emp_qelem *list, coord x, coord y)
        if (gun) {
            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);
                ship.shp_item[I_SHELL] = shell;
                putship(ship.shp_uid, &ship);
            }
index 5432c4291b0f6c44b1820235416ee52414424994..a214372db1b5b6e7bd5651be6e183995e137c6e7 100644 (file)
@@ -384,11 +384,11 @@ put_combat(struct combat *com)
            else
                land.lnd_mobil = (signed char)(com->mob - com->mobcost);
        }
-       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 = com->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);
        if (com->plague) {
            if (land.lnd_pstage == PLG_HEALTHY)
                land.lnd_pstage = PLG_EXPOSED;
@@ -412,11 +412,11 @@ put_combat(struct combat *com)
            else
                ship.shp_mobil = (signed char)(com->mob - com->mobcost);
        }
-       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 = com->own;
-       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);
        if (com->plague) {
            if (ship.shp_pstage == PLG_HEALTHY)
                ship.shp_pstage = PLG_EXPOSED;
index d3ddd791b19c83baa9ecc1daa069ce430b3d2614..75e7858c823ce69e039f294b11f010b950bd81c5 100644 (file)
@@ -301,8 +301,8 @@ detonate(struct nukstr *np, coord x, coord y, int airburst)
            continue;
        if (roll(100) >= damage)
            continue;
-       makelost(EF_NUKE, nuke.nuk_own, nuke.nuk_uid, nuke.nuk_x,
-                nuke.nuk_y);
+       makelost(EF_NUKE, nuke.nuk_own, nuke.nuk_uid,
+                nuke.nuk_x, nuke.nuk_y);
        nuke.nuk_own = 0;
        if (own == bombown) {
            mpr(bombown, "%s at %s destroyed\n",
index 23b785043159fc897092b48f707eeaba3c09cec7..6621376b7d5a6cdcd6e07a7c0cc56c0b86e6c5d4 100644 (file)
@@ -137,10 +137,8 @@ sd(natid att, natid own, coord x, coord y, int noisy, int defending,
                else
                    wu(0, ship.shp_own,
                       "%s supported %s attacks against %s at %s, doing %d damage.\n",
-                      prship(&ship), cname(own), cname(att), xyas(x, y,
-                                                                  ship.
-                                                                  shp_own),
-                      dam);
+                      prship(&ship), cname(own), cname(att),
+                      xyas(x, y, ship.shp_own), dam);
            }
        }
     }
@@ -233,8 +231,8 @@ sb(natid att, natid def, struct sctstr *sp, coord tx, coord ty, int noisy,
        return 0;
     shell = sp->sct_item[I_SHELL];
     if (shell <= 0)
-       shell += supply_commod(sp->sct_own, sp->sct_x, sp->sct_y, I_SHELL,
-                              1);
+       shell += supply_commod(sp->sct_own, sp->sct_x, sp->sct_y,
+                              I_SHELL, 1);
     if (shell <= 0)
        return 0;
     sp->sct_item[I_SHELL] = shell - 1;
@@ -243,11 +241,8 @@ sb(natid att, natid def, struct sctstr *sp, coord tx, coord ty, int noisy,
     if (sp->sct_own != def)
        wu(0, sp->sct_own,
           "%s fired on %s in %s in defense of %s, doing %d damage!\n",
-          xyas(sp->sct_x, sp->sct_y, sp->sct_own), cname(att), xyas(tx,
-                                                                    ty,
-                                                                    sp->
-                                                                    sct_own),
-          cname(def), damage);
+          xyas(sp->sct_x, sp->sct_y, sp->sct_own), cname(att),
+          xyas(tx, ty, sp->sct_own), cname(def), damage);
     if (defending)
        nreport(sp->sct_own, N_FIRE_BACK, att, 1);
     else
index 078a8d82cc9fadac4ddac8d101f459cec76f423d..688a19051ffc086886e5cbe41a96931e7bdcdb22 100644 (file)
@@ -123,8 +123,8 @@ lnd_prewrite(int n, void *ptr)
     time(&llp->lnd_timestamp);
 
     if (llp->lnd_own && llp->lnd_effic < LAND_MINEFF) {
-       makelost(EF_LAND, llp->lnd_own, llp->lnd_uid, llp->lnd_x,
-                llp->lnd_y);
+       makelost(EF_LAND, llp->lnd_own, llp->lnd_uid,
+                llp->lnd_x, llp->lnd_y);
        llp->lnd_own = 0;
 
        getland(n, &land);
@@ -132,8 +132,8 @@ lnd_prewrite(int n, void *ptr)
        for (i = 0; NULL != (lp = getlandp(i)); i++) {
            if (lp->lnd_own && lp->lnd_land == n) {
                mpr(lp->lnd_own, "%s MIA!\n", prland(lp));
-               makelost(EF_LAND, lp->lnd_own, lp->lnd_uid, lp->lnd_x,
-                        lp->lnd_y);
+               makelost(EF_LAND, lp->lnd_own, lp->lnd_uid,
+                        lp->lnd_x, lp->lnd_y);
                lp->lnd_own = 0;
                lp->lnd_effic = 0;
                lp->lnd_ship = -1;
@@ -144,8 +144,8 @@ lnd_prewrite(int n, void *ptr)
        for (i = 0; NULL != (pp = getplanep(i)); i++) {
            if (pp->pln_own && pp->pln_land == n) {
                mpr(pp->pln_own, "%s MIA!\n", prplane(pp));
-               makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
-                        pp->pln_y);
+               makelost(EF_PLANE, pp->pln_own, pp->pln_uid,
+                        pp->pln_x, pp->pln_y);
                pp->pln_own = 0;
                pp->pln_effic = 0;
                pp->pln_ship = -1;
index c55943ce9d5be45eec8d9be0e175b4d343e692bc..9136ba2a7f3a633e28971c68658edcbf6c99480b 100644 (file)
@@ -951,8 +951,8 @@ lnd_fort_interdiction(struct emp_qelem *list,
            continue;
        shell = fsect.sct_item[I_SHELL];
        if (shell < 1)
-           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 < 1)
            continue;
        shell--;
index b73d0cc926940f5927bb3028a501a4f32d860bd3..800f7e35127015ad5aa94bcb949f8c825ed94fa3 100644 (file)
@@ -1459,8 +1459,8 @@ air_damage(struct emp_qelem *bombers, coord x, coord y, int mission,
 
        /* use up missiles */
        if (plp->pcp->pl_flags & P_M) {
-           makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
-                    pp->pln_y);
+           makelost(EF_PLANE, pp->pln_own, pp->pln_uid,
+                    pp->pln_x, pp->pln_y);
            pp->pln_own = 0;
        }
     }
index 89506a85cad610ab447307c875bf921b9ad7da3d..add542da3b543c44f6fc968c32000eafc146efd5 100644 (file)
@@ -116,8 +116,8 @@ pln_prewrite(int n, void *ptr)
 
     if (pp->pln_effic < PLANE_MINEFF) {
        if (pp->pln_own)
-           makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
-                    pp->pln_y);
+           makelost(EF_PLANE, pp->pln_own, pp->pln_uid,
+                    pp->pln_x, pp->pln_y);
        pp->pln_own = 0;
        pp->pln_effic = 0;
        for (i = 0; NULL != (np = getnukep(i)); i++) {
index 241aa055a8cd300dc1917a9a518cc38b5b3057d2..a76403dc46c9472b88cac8272e5f8278d70b8931 100644 (file)
@@ -727,9 +727,8 @@ pln_equip(struct plist *plp, struct ichrstr *ip, int flags, char mission)
     } else {
        if (pp->pln_own != sect.sct_own) {
            wu(0, sect.sct_own, "%s %s prepares for takeoff from %s\n",
-              cname(pp->pln_own), prplane(pp), xyas(sect.sct_x,
-                                                    sect.sct_y,
-                                                    sect.sct_own));
+              cname(pp->pln_own), prplane(pp),
+              xyas(sect.sct_x, sect.sct_y, sect.sct_own));
        }
        putsect(&sect);
     }
index 4bbe3f39d593d508eb78c9866fb738e5c374d6cf..a34cb83f8c5d0ae10fc230528a070c18e204846f 100644 (file)
@@ -85,8 +85,8 @@ shp_prewrite(int n, void *ptr)
        for (i = 0; NULL != (lp = getlandp(i)); i++) {
            if (lp->lnd_own && lp->lnd_ship == n) {
                mpr(lp->lnd_own, "%s sunk!\n", prland(lp));
-               makelost(EF_LAND, lp->lnd_own, lp->lnd_uid, lp->lnd_x,
-                        lp->lnd_y);
+               makelost(EF_LAND, lp->lnd_own, lp->lnd_uid,
+                        lp->lnd_x, lp->lnd_y);
                lp->lnd_own = 0;
                lp->lnd_effic = 0;
                lp->lnd_ship = -1;
@@ -97,8 +97,8 @@ shp_prewrite(int n, void *ptr)
        for (i = 0; NULL != (pp = getplanep(i)); i++) {
            if (pp->pln_own && pp->pln_ship == n) {
                mpr(pp->pln_own, "%s sunk!\n", prplane(pp));
-               makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
-                        pp->pln_y);
+               makelost(EF_PLANE, pp->pln_own, pp->pln_uid,
+                        pp->pln_x, pp->pln_y);
                pp->pln_own = 0;
                pp->pln_effic = 0;
                pp->pln_ship = -1;
index 5e00cf45211eee8a1416e18efd12c5e24b91b7e4..98ee8b0a9f37b93ccc14564b71f7e5545aa32dd8 100644 (file)
@@ -404,8 +404,8 @@ sect_has_dock(struct sctstr *sect)
 }
 
 static int
-shp_count(struct emp_qelem *list, int wantflags, int nowantflags, int x,
-         int y)
+shp_count(struct emp_qelem *list, int wantflags, int nowantflags,
+         int x, int y)
 {
     struct emp_qelem *qp;
     struct emp_qelem *next;
@@ -686,8 +686,8 @@ shp_fort_interdiction(struct emp_qelem *list, coord newx, coord newy,
            continue;
        shell = fsect.sct_item[I_SHELL];
        if (shell < 1)
-           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 < 1)
            continue;
        shell--;
index c1285d45f0e4672564990477798a5b8e7a966b10..04b0814e0a8054a4b66abcdfd0fbc3d093c8aab1 100644 (file)
@@ -90,7 +90,8 @@ resupply_commod(struct lndstr *lp, i_type type)
     /* Ok, do we now have enough? */
     amt = get_minimum(lp, type) - lp->lnd_item[type];
     if (amt > 0) {
-       lp->lnd_item[type] += supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y,
+       lp->lnd_item[type] += supply_commod(lp->lnd_own,
+                                           lp->lnd_x, lp->lnd_y,
                                            type, amt);
        amt = get_minimum(lp, type) - lp->lnd_item[type];
     }
@@ -550,8 +551,8 @@ use_supply(struct lndstr *lp)
     if (shells < shells_needed) {
        lp->lnd_item[I_SHELL] = 0;
        putland(lp->lnd_uid, lp);
-       shells += supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y, I_SHELL,
-                               (shells_needed - shells));
+       shells += supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y,
+                               I_SHELL, shells_needed - shells);
        lp->lnd_item[I_SHELL] = shells;
     }
 
@@ -566,8 +567,8 @@ use_supply(struct lndstr *lp)
     if (food < food_needed) {
        lp->lnd_item[I_FOOD] = 0;
        putland(lp->lnd_uid, lp);
-       food += supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y, I_FOOD,
-                             (food_needed - food));
+       food += supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y,
+                             I_FOOD, food_needed - food);
        lp->lnd_item[I_FOOD] = food;
     }
 
@@ -588,9 +589,8 @@ use_supply(struct lndstr *lp)
        if (petrol < petrol_needed) {
            lp->lnd_item[I_PETROL] = 0;
            putland(lp->lnd_uid, lp);
-           petrol += supply_commod(lp->lnd_own,
-                                   lp->lnd_x, lp->lnd_y,
-                                   I_PETROL, (petrol_needed - petrol));
+           petrol += supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y,
+                                   I_PETROL, petrol_needed - petrol);
            lp->lnd_item[I_PETROL] = petrol;
        }
 
index 88fde63812f94876c87925c9a3e430c4d4cde433..89b2734e0268930eaeaa995bcf3d83a6c82ed871 100644 (file)
@@ -250,8 +250,8 @@ takeover_ship(struct shpstr *sp, natid newown, int hostile)
        pp->pln_mission = 0;
        makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x, pp->pln_y);
        pp->pln_own = newown;
-       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);
        putplane(pp->pln_uid, pp);
     }
     /* Take over land units */
@@ -287,11 +287,11 @@ takeover_land(struct lndstr *landp, natid newown, int hostile)
     if (opt_MARKET)
        trdswitchown(EF_LAND, landp, newown);
     landp->lnd_mission = 0;
-    makelost(EF_LAND, landp->lnd_own, landp->lnd_uid, landp->lnd_x,
-            landp->lnd_y);
+    makelost(EF_LAND, landp->lnd_own, landp->lnd_uid,
+            landp->lnd_x, landp->lnd_y);
     landp->lnd_own = newown;
-    makenotlost(EF_LAND, landp->lnd_own, landp->lnd_uid, landp->lnd_x,
-               landp->lnd_y);
+    makenotlost(EF_LAND, landp->lnd_own, landp->lnd_uid,
+               landp->lnd_x, landp->lnd_y);
     pp = &p;
     lp = &llp;
     /* Take over planes */
@@ -313,8 +313,8 @@ takeover_land(struct lndstr *landp, natid newown, int hostile)
        pp->pln_mission = 0;
        makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x, pp->pln_y);
        pp->pln_own = newown;
-       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);
        putplane(pp->pln_uid, pp);
     }
     /* Take over land units */
index 672295d48b92505b5384996c80d77a61cccff466..a13935ccd6a3182dc2301a16807000f199993e8c 100644 (file)
@@ -192,8 +192,9 @@ assemble_dist_paths(struct distinfo *distptrs)
        /* now, get the dist sector */
        dist = getsectp(sp->sct_dist_x, sp->sct_dist_y);
        if (dist == NULL) {
-           logerror("Bad dist sect %d,%d for %d,%d !\n", sp->sct_dist_x,
-                    sp->sct_dist_y, sp->sct_x, sp->sct_y);
+           logerror("Bad dist sect %d,%d for %d,%d !\n",
+                    sp->sct_dist_x, sp->sct_dist_y,
+                    sp->sct_x, sp->sct_y);
            continue;
        }
        /* Now, get the best distribution path over roads */
index bdf7041453918df58bc9ff951cbe630640c2b850..27a6c21fc4c09610e751397686d6f985aad03413 100644 (file)
@@ -102,9 +102,9 @@ do_feed(struct sctstr *sp, struct natstr *np, short *vec,
                needed = ldround((double)(1 + etu * people * eatrate), 1);
 
                /* Now, find some food */
-               vec[I_FOOD] = supply_commod(sp->sct_own, sp->sct_x,
-                                           sp->sct_y, I_FOOD, needed);
-
+               vec[I_FOOD] = supply_commod(sp->sct_own,
+                                           sp->sct_x, sp->sct_y,
+                                           I_FOOD, needed);
            }
        }
        starved = feed_people(vec, etu, &needed);
index 194e7462fe0f7b8914ac757a0ae2937eafd74026..ec1677e617e067dcc4f5d109ecccd33b54e14001 100644 (file)
@@ -129,8 +129,8 @@ upd_land(struct lndstr *lp, int etus,
        if (np->nat_priorities[PRI_LBUILD] == 0 || np->nat_money < 0)
            return;
        if (lp->lnd_effic < LAND_MINEFF || !landrepair(lp, np, bp, etus)) {
-           makelost(EF_LAND, lp->lnd_own, lp->lnd_uid, lp->lnd_x,
-                    lp->lnd_y);
+           makelost(EF_LAND, lp->lnd_own, lp->lnd_uid,
+                    lp->lnd_x, lp->lnd_y);
            lp->lnd_own = 0;
            return;
        }
@@ -147,8 +147,8 @@ upd_land(struct lndstr *lp, int etus,
            if ((eff = lp->lnd_effic - etus / 5) < LAND_MINEFF) {
                wu(0, lp->lnd_own,
                   "%s lost to lack of maintenance\n", prland(lp));
-               makelost(EF_LAND, lp->lnd_own, lp->lnd_uid, lp->lnd_x,
-                        lp->lnd_y);
+               makelost(EF_LAND, lp->lnd_own, lp->lnd_uid,
+                        lp->lnd_x, lp->lnd_y);
                lp->lnd_own = 0;
                return;
            }
index 360a24c55d296c97b0075d6a8827030030903f56..cce9bb9106f7782db4175f037efb958b8dab5895 100644 (file)
@@ -328,8 +328,8 @@ do_mob_ship(struct shpstr *sp, int etus)
            if ((d - (int)d) > 0.0)
                d++;
            need = (int)d;
-           newfuel = supply_commod(sp->shp_own, sp->shp_x,
-                                   sp->shp_y, I_PETROL, need);
+           newfuel = supply_commod(sp->shp_own, sp->shp_x, sp->shp_y,
+                                   I_PETROL, need);
            sp->shp_fuel += newfuel * 5;
        }
 
@@ -347,8 +347,8 @@ do_mob_ship(struct shpstr *sp, int etus)
            if ((d - (int)d) > 0.0)
                d++;
            need = (int)d;
-           newfuel = supply_commod(sp->shp_own, sp->shp_x,
-                                   sp->shp_y, I_OIL, need);
+           newfuel = supply_commod(sp->shp_own, sp->shp_x, sp->shp_y,
+                                   I_OIL, need);
            sp->shp_fuel += newfuel * 50;
        }
 
@@ -444,8 +444,8 @@ do_mob_land(struct lndstr *lp, int etus)
            if ((d - (int)d) > 0.0)
                d++;
            need = (int)d;
-           newfuel = supply_commod(lp->lnd_own, lp->lnd_x,
-                                   lp->lnd_y, I_PETROL, need);
+           newfuel = supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y,
+                                   I_PETROL, need);
            lp->lnd_fuel += newfuel * 5;
        }
 
@@ -461,8 +461,8 @@ do_mob_land(struct lndstr *lp, int etus)
            if ((d - (int)d) > 0.0)
                d++;
            need = (int)d;
-           newfuel = supply_commod(lp->lnd_own, lp->lnd_x,
-                                   lp->lnd_y, I_OIL, need);
+           newfuel = supply_commod(lp->lnd_own, lp->lnd_x, lp->lnd_y,
+                                   I_OIL, need);
            lp->lnd_fuel += newfuel * 50;
        }
 
index 9c1ea533e0ec7483da44a462fe38ec936ce1a7bd..8c3933ffc4fea803c41bafa6d614e355b3709441 100644 (file)
@@ -219,8 +219,8 @@ auto_fuel_ship(struct shpstr *sp)
        d++;
     need = (int)d;
 
-    newfuel = supply_commod(sp->shp_own, sp->shp_x,
-                           sp->shp_y, I_PETROL, need);
+    newfuel = supply_commod(sp->shp_own, sp->shp_x, sp->shp_y,
+                           I_PETROL, need);
     add_fuel += newfuel * 5;
     if (add_fuel > maxfuel)
        add_fuel = maxfuel;
@@ -238,8 +238,8 @@ auto_fuel_ship(struct shpstr *sp)
        d++;
     need = (int)d;
 
-    newfuel = supply_commod(sp->shp_own, sp->shp_x,
-                           sp->shp_y, I_OIL, need);
+    newfuel = supply_commod(sp->shp_own, sp->shp_x, sp->shp_y,
+                           I_OIL, need);
     add_fuel = newfuel * 50;
     if (add_fuel > maxfuel)
        add_fuel = maxfuel;
index 3b9360032d5db5ef7c39a2f2b86beb806bc5593a..9553953ddb8da85d0aeebf99e5f967c115df4811 100644 (file)
@@ -113,8 +113,8 @@ prod_plane(int etus, int natnum, int *bp, int buildem)
                /* nplane is unsigned... */
                if (shp->shp_nplane > 0)
                    shp->shp_nplane--;
-               makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
-                        pp->pln_y);
+               makelost(EF_PLANE, pp->pln_own, pp->pln_uid,
+                        pp->pln_x, pp->pln_y);
                pp->pln_own = 0;
                continue;
            }
@@ -135,8 +135,8 @@ prod_plane(int etus, int natnum, int *bp, int buildem)
                if ((eff = pp->pln_effic - etus / 5) < PLANE_MINEFF) {
                    wu(0, pp->pln_own,
                       "%s lost to lack of maintenance\n", prplane(pp));
-                   makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x,
-                            pp->pln_y);
+                   makelost(EF_PLANE, pp->pln_own, pp->pln_uid,
+                            pp->pln_x, pp->pln_y);
                    pp->pln_own = 0;
                    continue;
                }
index 7de8ed8acb5a7f95ab89c59f40fb811df0792928..2c251f838492bca1962b3cecf535523e2f6c306d 100644 (file)
@@ -132,8 +132,8 @@ upd_ship(struct shpstr *sp, int etus,
        if (np->nat_priorities[PRI_SBUILD] == 0 || np->nat_money < 0)
            return;
        if (sp->shp_effic < SHIP_MINEFF || !shiprepair(sp, np, bp, etus)) {
-           makelost(EF_SHIP, sp->shp_own, sp->shp_uid, sp->shp_x,
-                    sp->shp_y);
+           makelost(EF_SHIP, sp->shp_own, sp->shp_uid,
+                    sp->shp_x, sp->shp_y);
            sp->shp_own = 0;
            return;
        }
@@ -147,8 +147,8 @@ upd_ship(struct shpstr *sp, int etus,
            if ((eff = sp->shp_effic - etus / 5) < SHIP_MINEFF) {
                wu(0, sp->shp_own,
                   "%s lost to lack of maintenance\n", prship(sp));
-               makelost(EF_SHIP, sp->shp_own, sp->shp_uid, sp->shp_x,
-                        sp->shp_y);
+               makelost(EF_SHIP, sp->shp_own, sp->shp_uid,
+                        sp->shp_x, sp->shp_y);
                sp->shp_own = 0;
                return;
            }