diff --git a/include/budg.h b/include/budg.h index 0b112bc8..82f65ed1 100644 --- a/include/budg.h +++ b/include/budg.h @@ -34,6 +34,9 @@ #ifndef BUDG_H #define BUDG_H +#include "types.h" +#include "item.h" + #define SCT_EFFIC (SCT_TYPE_MAX + 1) void fill_update_array(int *bp, struct sctstr *sp); diff --git a/include/combat.h b/include/combat.h index d390c2c5..19607b2d 100644 --- a/include/combat.h +++ b/include/combat.h @@ -34,8 +34,8 @@ #ifndef COMBAT_H #define COMBAT_H -#include "sect.h" -#include "queue.h" +#include "types.h" +#include "ship.h" struct combat { int type; /* EF_BAD, EF_SECTOR, EF_SHIP, or EF_PLANE */ @@ -56,7 +56,7 @@ struct combat { struct dchrstr *sct_dcp; struct mchrstr *shp_mcp; struct lchrstr *lnd_lcp; - char shp_name[MAXSHPNAMLEN]; + char shp_name[MAXSHPNAMLEN]; /* FIXME huh? pulls in ship.h */ int relations_checked; }; diff --git a/include/commands.h b/include/commands.h index 933a71ff..34cf7951 100644 --- a/include/commands.h +++ b/include/commands.h @@ -34,27 +34,10 @@ #ifndef COMMANDS_H #define COMMANDS_H -#include -#include -#include -#if !defined(_WIN32) -#include -#endif -#include "misc.h" -#include "plane.h" -#include "sect.h" -#include "ship.h" -#include "land.h" -#include "nsc.h" +#include "file.h" #include "nat.h" -#include "queue.h" -#include "subs.h" -#include "gen.h" -#include "common.h" -#include "lost.h" -#include "map.h" -#include "update.h" - -#include "prototypes.h" /* must come at end, after defines and typedefs */ +#include "player.h" +#include "sect.h" +#include "prototypes.h" #endif diff --git a/include/commodity.h b/include/commodity.h index 5ae2d2bf..5062f216 100644 --- a/include/commodity.h +++ b/include/commodity.h @@ -36,6 +36,9 @@ #ifndef COMMODITY_H #define COMMODITY_H +#include "types.h" +#include "item.h" + struct comstr { short ef_type; natid com_owner; diff --git a/include/common.h b/include/common.h deleted file mode 100644 index d4d42f50..00000000 --- a/include/common.h +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Empire - A multi-player, client/server Internet based war game. - * Copyright (C) 1986-2006, Dave Pare, Jeff Bailey, Thomas Ruschak, - * Ken Stevens, Steve McClure - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * --- - * - * See files README, COPYING and CREDITS in the root of the source - * tree for related information and legal notices. It is expected - * that future projects/authors will amend these files as needed. - * - * --- - * - * common.h: Includes for common stuff - * - * Known contributors to this file: - * - */ - -#ifndef COMMON_H -#define COMMON_H - -#include /* FILE */ -#include "misc.h" -#include "sect.h" /* struct sctstr */ -#include "ship.h" /* struct shpstr */ -#include "land.h" /* struct lndstr */ -#include "plane.h" /* struct plnstr */ -#include "nuke.h" /* struct nchrstr */ -#include "nsc.h" /* struct castr struct nstr_sect struct nstr_item */ -#include "xy.h" /* struct range */ -#include "prototypes.h" /* must come at end, after defines and typedefs */ - -#endif diff --git a/include/empobj.h b/include/empobj.h index cc800fd5..546ef46b 100644 --- a/include/empobj.h +++ b/include/empobj.h @@ -35,21 +35,19 @@ #ifndef EMPOBJ_H #define EMPOBJ_H -#include "config.h" -#include "file.h" -#include "nat.h" #include "commodity.h" #include "land.h" #include "loan.h" #include "lost.h" -#include "plane.h" +#include "nat.h" #include "news.h" #include "nuke.h" +#include "plane.h" #include "sect.h" #include "ship.h" #include "trade.h" #include "treaty.h" -#include "prototypes.h" +#include "types.h" struct empobj { short ef_type; /* is always valid */ diff --git a/include/empthread.h b/include/empthread.h index c86b1feb..c03091b0 100644 --- a/include/empthread.h +++ b/include/empthread.h @@ -49,6 +49,8 @@ #ifndef EMPTHREAD_H #define EMPTHREAD_H +#include + /* thread priorities */ enum { PP_MAIN = 7, diff --git a/include/file.h b/include/file.h index fa16f7cf..2e7c0cbb 100644 --- a/include/file.h +++ b/include/file.h @@ -34,7 +34,6 @@ #ifndef FILE_H #define FILE_H -#include #include struct empfile { diff --git a/include/ioqueue.h b/include/ioqueue.h index 515db71a..0e6fe15d 100644 --- a/include/ioqueue.h +++ b/include/ioqueue.h @@ -34,6 +34,11 @@ #ifndef IOQUEUE_H #define IOQUEUE_H +#ifndef _WIN32 +#include +#endif +#include "queue.h" + struct io { struct emp_qelem queue; int size; diff --git a/include/land.h b/include/land.h index 95b16104..e94fb040 100644 --- a/include/land.h +++ b/include/land.h @@ -36,11 +36,10 @@ #ifndef LAND_H #define LAND_H -#include "sect.h" -#include "ship.h" +#include "item.h" #include "queue.h" -#include "nsc.h" #include "retreat.h" +#include "types.h" #define LND_TYPE_MAX 30 #define LAND_MINEFF 10 diff --git a/include/loan.h b/include/loan.h index 79f2df5e..9788d528 100644 --- a/include/loan.h +++ b/include/loan.h @@ -34,6 +34,9 @@ #ifndef LOAN_H #define LOAN_H +#include +#include "types.h" + #define MAXLOAN 100000 #define SECS_PER_DAY (60*60*24) diff --git a/include/lost.h b/include/lost.h index 2572dce2..9f02b707 100644 --- a/include/lost.h +++ b/include/lost.h @@ -34,6 +34,9 @@ #ifndef LOST_H #define LOST_H +#include +#include "types.h" + struct loststr { /* initial part must match struct empobj */ short ef_type; diff --git a/include/lwp.h b/include/lwp.h index 630e2631..ec053be3 100644 --- a/include/lwp.h +++ b/include/lwp.h @@ -25,7 +25,6 @@ #define LWP_H #include -#include "misc.h" #define LWP_STACKCHECK 0x1 #define LWP_PRINT 0x2 diff --git a/include/map.h b/include/map.h index 0a61c64d..f8d703b3 100644 --- a/include/map.h +++ b/include/map.h @@ -34,8 +34,7 @@ #ifndef MAP_H #define MAP_H -#include "misc.h" -#include "xy.h" +#include "types.h" #define MAPWIDTH(persec) ((WORLD_X/2) * ((persec) + 1) + 1) diff --git a/include/misc.h b/include/misc.h index ecff7ea4..dc666f81 100644 --- a/include/misc.h +++ b/include/misc.h @@ -35,9 +35,7 @@ #ifndef MISC_H #define MISC_H -#include -#include -#include +#include #define MAX(a,b) ((a) > (b) ? (a) : (b)) #define MIN(a,b) ((a) < (b) ? (a) : (b)) @@ -88,10 +86,6 @@ struct mob_acc_globals { #define RESOLVE_IPADDRESS /* resolve ip addresses into hostnames */ #endif -typedef unsigned char natid; /* NSC_NATID must match this */ - -typedef short coord; - #ifndef bit #define bit(x) (1<<(x)) #endif @@ -134,7 +128,4 @@ extern char *prbuf(char *format, ...) #define AGREE_PROPOSED 1 #define AGREE_SIGNED 2 -struct empobj; -union empobj_storage; - #endif diff --git a/include/nat.h b/include/nat.h index 4edddd83..6a66131e 100644 --- a/include/nat.h +++ b/include/nat.h @@ -36,7 +36,8 @@ #ifndef NAT_H #define NAT_H -#include "sect.h" +#include +#include "types.h" #define MAXNOR 50 /* max # realms */ diff --git a/include/nsc.h b/include/nsc.h index dcecec1f..4c6b8502 100644 --- a/include/nsc.h +++ b/include/nsc.h @@ -36,6 +36,7 @@ #define NSC_H #include +#include "misc.h" #include "xy.h" #define NS_LSIZE 128 diff --git a/include/nuke.h b/include/nuke.h index a64cedae..8960471f 100644 --- a/include/nuke.h +++ b/include/nuke.h @@ -34,6 +34,9 @@ #ifndef NUKE_H #define NUKE_H +#include +#include "types.h" + #define N_MAXNUKE 20 #define MIN_DRNUKE_CONST 0.001 diff --git a/include/path.h b/include/path.h index 57db9399..48312eaa 100644 --- a/include/path.h +++ b/include/path.h @@ -34,9 +34,7 @@ #ifndef PATH_H #define PATH_H -#include "misc.h" -#include "sect.h" -#include "xy.h" +#include "types.h" /* direction indices */ #define DIR_STOP 0 diff --git a/include/plane.h b/include/plane.h index beee78d6..1beeebee 100644 --- a/include/plane.h +++ b/include/plane.h @@ -36,8 +36,9 @@ #ifndef PLANE_H #define PLANE_H +#include #include "queue.h" -#include "sect.h" +#include "types.h" #define PLN_TYPE_MAX 46 #define PLANE_MINEFF 10 diff --git a/include/player.h b/include/player.h index 6415e90f..0407169d 100644 --- a/include/player.h +++ b/include/player.h @@ -35,14 +35,11 @@ #ifndef PLAYER_H #define PLAYER_H -#include -#if !defined(_WIN32) -#include -#endif -#include "queue.h" -#include "misc.h" -#include "com.h" +#include #include "empthread.h" +#include "misc.h" +#include "queue.h" +#include "types.h" struct player { struct emp_qelem queue; diff --git a/include/power.h b/include/power.h index f369b87c..b99ff19b 100644 --- a/include/power.h +++ b/include/power.h @@ -34,6 +34,8 @@ #ifndef POWER_H #define POWER_H +#include "types.h" + struct powstr { natid p_nation; float p_sects; diff --git a/include/prototypes.h b/include/prototypes.h index a8dde780..0ff66342 100644 --- a/include/prototypes.h +++ b/include/prototypes.h @@ -36,13 +36,12 @@ #define PROTOTYPES_H #include +#include +#include +#include "item.h" +#include "nsc.h" #include "misc.h" -#include "empthread.h" -#include "player.h" -#include "commands.h" -#include "product.h" -#include "empio.h" -#include "commodity.h" +#include "types.h" /* src/server/main.c */ extern void shutdwn(int sig); diff --git a/include/sect.h b/include/sect.h index ce3c5a03..ba4078a1 100644 --- a/include/sect.h +++ b/include/sect.h @@ -38,6 +38,7 @@ #define SECT_H #include "item.h" +#include "types.h" struct sctstr { /* initial part must match struct empobj */ diff --git a/include/server.h b/include/server.h index 4b247920..7d504a05 100644 --- a/include/server.h +++ b/include/server.h @@ -34,6 +34,8 @@ #ifndef SERVER_H #define SERVER_H +#include "empthread.h" + extern int shutdown_pending; extern int update_pending; extern empth_sem_t *update_sem; diff --git a/include/ship.h b/include/ship.h index e58cd0d0..c93b3339 100644 --- a/include/ship.h +++ b/include/ship.h @@ -39,8 +39,8 @@ #include "item.h" #include "queue.h" -#include "misc.h" #include "retreat.h" +#include "types.h" #define SHP_TYPE_MAX 46 #define SHIP_MINEFF 20 diff --git a/include/subs.h b/include/subs.h deleted file mode 100644 index 384fa69d..00000000 --- a/include/subs.h +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Empire - A multi-player, client/server Internet based war game. - * Copyright (C) 1986-2006, Dave Pare, Jeff Bailey, Thomas Ruschak, - * Ken Stevens, Steve McClure - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * --- - * - * See files README, COPYING and CREDITS in the root of the source - * tree for related information and legal notices. It is expected - * that future projects/authors will amend these files as needed. - * - * --- - * - * subs.h: Headers for things having to do with subs. - * - * Known contributors to this file: - * - */ - -#ifndef SUBS_H -#define SUBS_H - -#include "misc.h" -#include "sect.h" -#include "plane.h" -#include "loan.h" -#include "treaty.h" -#include "nsc.h" -#include "land.h" -#include "com.h" -#include "nuke.h" -#include "item.h" -#include "ship.h" -#include "queue.h" -#include "xy.h" -#include "empobj.h" -#include "trade.h" -#include "player.h" -#include "prototypes.h" /* must come at end, after defines and typedefs */ - -#endif diff --git a/include/tel.h b/include/tel.h index 130210d8..dcc70190 100644 --- a/include/tel.h +++ b/include/tel.h @@ -34,6 +34,9 @@ #ifndef TEL_H #define TEL_H +#include +#include "types.h" + #define MAXTELSIZE 1024 /* doesn't apply to TEL_UPDATE */ #define TEL_NORM 0 /* normal */ diff --git a/include/trade.h b/include/trade.h index fc3d7cf0..368af973 100644 --- a/include/trade.h +++ b/include/trade.h @@ -37,6 +37,9 @@ #ifndef TRADE_H #define TRADE_H +#include +#include "types.h" + struct trdstr { short ef_type; natid trd_owner; diff --git a/include/treaty.h b/include/treaty.h index 7d00ab17..514bb9f5 100644 --- a/include/treaty.h +++ b/include/treaty.h @@ -34,6 +34,9 @@ #ifndef TREATY_H #define TREATY_H +#include +#include "types.h" + struct trtstr { short ef_type; natid trt_cna; /* proposer */ diff --git a/include/gen.h b/include/types.h similarity index 70% rename from include/gen.h rename to include/types.h index e8d2ede0..de6e6c75 100644 --- a/include/gen.h +++ b/include/types.h @@ -25,18 +25,39 @@ * * --- * - * gen.h: Includes for generic stuff + * types.h: Empire types * * Known contributors to this file: - * + * Markus Armbruster, 2006 */ -#ifndef GEN_H -#define GEN_H +#ifndef TYPES_H +#define TYPES_H -#include /* atoi etc. */ -#include "misc.h" -#include "xy.h" /* struct range */ -#include "prototypes.h" /* must come at end, after defines and typedefs */ +typedef unsigned char natid; /* NSC_NATID must match this */ +typedef short coord; + +struct emp_qelem; +struct empobj; +struct lndstr; +struct lndstr; +struct lonstr; +struct natstr; +struct nchrstr; +struct nstr_item; +struct nstr_sect; +struct nukstr; +struct plist; +struct plnstr; +struct range; +struct sctstr; +struct shiplist; +struct shpstr; +struct trdstr; +struct trtstr; +struct comstr; +struct cmndstr; + +union empobj_storage; #endif diff --git a/include/update.h b/include/update.h index 7f8f4bef..1c598ec1 100644 --- a/include/update.h +++ b/include/update.h @@ -34,16 +34,10 @@ #ifndef UPDATE_H #define UPDATE_H -#include "misc.h" -#include "queue.h" -#include "sect.h" -#include "item.h" -#include "land.h" -#include "plane.h" -#include "ship.h" +#include "file.h" #include "nat.h" -#include "nsc.h" -#include "product.h" -#include "prototypes.h" /* must come at end, after defines and typedefs */ +#include "optlist.h" +#include "prototypes.h" +#include "sect.h" #endif diff --git a/include/xy.h b/include/xy.h index 5cf59dbc..1c614a1c 100644 --- a/include/xy.h +++ b/include/xy.h @@ -34,8 +34,7 @@ #ifndef XY_H #define XY_H -#include "sect.h" -#include "nat.h" +#include "types.h" /* Used to calculate an offset into an array. Used for dynamically sizing the world. */ diff --git a/src/client/expect.c b/src/client/expect.c index b25107fb..7e1ba8fb 100644 --- a/src/client/expect.c +++ b/src/client/expect.c @@ -33,16 +33,14 @@ #include -#include "misc.h" - +#include #include #include -#include -#include #ifndef _WIN32 #include #include #endif +#include "misc.h" int recvline(int s, char *buf) diff --git a/src/client/host.c b/src/client/host.c index 7b5b077f..4eff2d8a 100644 --- a/src/client/host.c +++ b/src/client/host.c @@ -40,12 +40,11 @@ #include #include #include -#include #ifndef _WIN32 #include -#include -#include #include +#include +#include #include #else #include diff --git a/src/client/ioqueue.c b/src/client/ioqueue.c index 4af97910..4f271239 100644 --- a/src/client/ioqueue.c +++ b/src/client/ioqueue.c @@ -36,10 +36,9 @@ #include #include #include -#include +#include "ioqueue.h" #include "misc.h" #include "queue.h" -#include "ioqueue.h" static int ioqtobuf(struct ioqueue *ioq, char *buf, int cc); static void enqueuecc(struct ioqueue *ioq, char *buf, int cc); diff --git a/src/client/ioqueue.h b/src/client/ioqueue.h index c8565b0b..732db48a 100644 --- a/src/client/ioqueue.h +++ b/src/client/ioqueue.h @@ -35,6 +35,8 @@ #ifndef IOQUEUE_H #define IOQUEUE_H +#include "queue.h" + struct ioqueue { struct qelem queue; /* queue fwd/back */ int bsize; /* basic block size */ diff --git a/src/client/login.c b/src/client/login.c index e6bc0090..c3f8e59a 100644 --- a/src/client/login.c +++ b/src/client/login.c @@ -34,9 +34,6 @@ #include -#include "misc.h" -#include "proto.h" - #include #include #include @@ -44,6 +41,8 @@ #if !defined(_WIN32) #include #endif +#include "misc.h" +#include "proto.h" int login(int s, char *uname, char *cname, char *cpass, diff --git a/src/client/main.c b/src/client/main.c index d0e00b83..fce9886c 100644 --- a/src/client/main.c +++ b/src/client/main.c @@ -36,32 +36,25 @@ #include -#include "misc.h" -#include "proto.h" -#include "queue.h" -#include "ioqueue.h" -#include "tags.h" - +#include +#include #include #include #include -#include -#ifndef _WIN32 -#include -#endif -#include -#include -#ifndef _WIN32 -#include -#include -#include -#include -#else +#ifdef _WIN32 #include #include #include +#else +#include +#include #endif +#include "ioqueue.h" +#include "misc.h" +#include "proto.h" +#include "tags.h" + #ifdef _WIN32 HANDLE hStdIn; #endif diff --git a/src/client/misc.h b/src/client/misc.h index 3057b101..292e8e88 100644 --- a/src/client/misc.h +++ b/src/client/misc.h @@ -34,13 +34,9 @@ #ifndef MISC_H #define MISC_H -#include #include -#include #ifdef _WIN32 #include -#else -#include #endif struct ioqueue; diff --git a/src/client/queue.c b/src/client/queue.c index ece88034..0187c489 100644 --- a/src/client/queue.c +++ b/src/client/queue.c @@ -33,11 +33,6 @@ #include -#include -#if !defined(_WIN32) -#include -#endif -#include "misc.h" #include "queue.h" void diff --git a/src/client/servcmd.c b/src/client/servcmd.c index fbf3fb9a..18814c6c 100644 --- a/src/client/servcmd.c +++ b/src/client/servcmd.c @@ -35,23 +35,22 @@ #include -#include "misc.h" -#include "proto.h" -#include "queue.h" -#include "ioqueue.h" -#include "tags.h" - +#include +#include #include #include #include -#include -#include -#if !defined(_WIN32) -#include -#else +#ifdef _WIN32 #include +#else +#include #endif +#include "ioqueue.h" +#include "misc.h" +#include "proto.h" +#include "tags.h" + static char num_teles[64]; static char the_prompt[1024]; static int mode; diff --git a/src/client/serverio.c b/src/client/serverio.c index 93420c5b..7861e8c2 100644 --- a/src/client/serverio.c +++ b/src/client/serverio.c @@ -33,19 +33,15 @@ #include -#include "misc.h" -#include "queue.h" -#include "ioqueue.h" - #include #include - -#if !defined(_WIN32) -#include -#else +#ifdef _WIN32 #include +#else +#include #endif - +#include "misc.h" +#include "ioqueue.h" int serverio(int s, struct ioqueue *ioq) diff --git a/src/client/tags.c b/src/client/tags.c index e6a2d720..244abf0a 100644 --- a/src/client/tags.c +++ b/src/client/tags.c @@ -34,16 +34,11 @@ #include +#include +#include #include "misc.h" #include "tags.h" -#include -#include -#include -#if !defined(_WIN32) -#include -#endif - struct tagstruct *taglist; void diff --git a/src/client/termio.c b/src/client/termio.c index 12c3190b..302fcf55 100644 --- a/src/client/termio.c +++ b/src/client/termio.c @@ -33,15 +33,15 @@ #include +#include #include #include #include -#include -#ifndef _WIN32 -#include -#else +#ifdef _WIN32 #include -#endif /* _WIN32 */ +#else +#include +#endif #include "misc.h" #include "tags.h" diff --git a/src/lib/as/as.h b/src/lib/as/as.h index 98be3e30..1399106c 100644 --- a/src/lib/as/as.h +++ b/src/lib/as/as.h @@ -31,7 +31,7 @@ #define AS_H #include -#include "misc.h" +#include "types.h" /* * Coordinate. diff --git a/src/lib/as/as_cache.c b/src/lib/as/as_cache.c index 1d15c5f9..d66318d4 100644 --- a/src/lib/as/as_cache.c +++ b/src/lib/as/as_cache.c @@ -34,6 +34,7 @@ #include #include +#include #include "as.h" #include "optlist.h" diff --git a/src/lib/as/as_delete.c b/src/lib/as/as_delete.c index 4041c7fd..eab8b4be 100644 --- a/src/lib/as/as_delete.c +++ b/src/lib/as/as_delete.c @@ -20,7 +20,6 @@ #include -#include #include #include "as.h" diff --git a/src/lib/as/as_extend.c b/src/lib/as/as_extend.c index 754705ff..4c9e7e3a 100644 --- a/src/lib/as/as_extend.c +++ b/src/lib/as/as_extend.c @@ -20,7 +20,6 @@ #include -#include #include #include "as.h" diff --git a/src/lib/as/as_hash.c b/src/lib/as/as_hash.c index ba34bc0c..c211befc 100644 --- a/src/lib/as/as_hash.c +++ b/src/lib/as/as_hash.c @@ -20,7 +20,6 @@ #include -#include #include #include "as.h" diff --git a/src/lib/as/as_init.c b/src/lib/as/as_init.c index c02f26e2..10514085 100644 --- a/src/lib/as/as_init.c +++ b/src/lib/as/as_init.c @@ -20,7 +20,6 @@ #include -#include #include #include "as.h" diff --git a/src/lib/as/as_merge.c b/src/lib/as/as_merge.c index e19176fa..ccd7b799 100644 --- a/src/lib/as/as_merge.c +++ b/src/lib/as/as_merge.c @@ -20,7 +20,6 @@ #include -#include #include #include "as.h" diff --git a/src/lib/as/as_search.c b/src/lib/as/as_search.c index 8c812dc0..58606a23 100644 --- a/src/lib/as/as_search.c +++ b/src/lib/as/as_search.c @@ -24,7 +24,6 @@ #include -#include #include #include "as.h" diff --git a/src/lib/as/as_stats.c b/src/lib/as/as_stats.c index 1fdaeecd..cadc8dc4 100644 --- a/src/lib/as/as_stats.c +++ b/src/lib/as/as_stats.c @@ -20,7 +20,6 @@ #include -#include #include "as.h" /* diff --git a/src/lib/as/as_winnow.c b/src/lib/as/as_winnow.c index 9ade2e1c..339b85dc 100644 --- a/src/lib/as/as_winnow.c +++ b/src/lib/as/as_winnow.c @@ -20,7 +20,6 @@ #include -#include #include #include "as.h" diff --git a/src/lib/commands/acce.c b/src/lib/commands/acce.c index e9b85d81..14dd6d10 100644 --- a/src/lib/commands/acce.c +++ b/src/lib/commands/acce.c @@ -33,11 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "xy.h" #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/add.c b/src/lib/commands/add.c index f770005e..140a0901 100644 --- a/src/lib/commands/add.c +++ b/src/lib/commands/add.c @@ -33,20 +33,12 @@ #include -#include -#include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "sect.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "tel.h" -#include "land.h" +#include #include "commands.h" +#include "land.h" #include "optlist.h" +#include "plague.h" +#include "tel.h" int add(void) diff --git a/src/lib/commands/anti.c b/src/lib/commands/anti.c index 7954ddbb..da88c1c4 100644 --- a/src/lib/commands/anti.c +++ b/src/lib/commands/anti.c @@ -34,17 +34,10 @@ #include -#include #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nat.h" -#include "nsc.h" -#include "item.h" -#include "file.h" #include "commands.h" +#include "item.h" +#include "lost.h" #include "optlist.h" /* diff --git a/src/lib/commands/arm.c b/src/lib/commands/arm.c index 7f332063..8093f1e5 100644 --- a/src/lib/commands/arm.c +++ b/src/lib/commands/arm.c @@ -36,16 +36,10 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "nuke.h" -#include "plane.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "nuke.h" #include "optlist.h" +#include "plane.h" int arm(void) diff --git a/src/lib/commands/army.c b/src/lib/commands/army.c index d17c7839..2cd47652 100644 --- a/src/lib/commands/army.c +++ b/src/lib/commands/army.c @@ -34,12 +34,8 @@ #include #include -#include "misc.h" -#include "player.h" -#include "land.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" int army(void) diff --git a/src/lib/commands/assa.c b/src/lib/commands/assa.c index 4e7d35f7..40c82c77 100644 --- a/src/lib/commands/assa.c +++ b/src/lib/commands/assa.c @@ -34,18 +34,12 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "path.h" -#include "nat.h" -#include "xy.h" -#include "land.h" -#include "nsc.h" -#include "mission.h" -#include "ship.h" #include "combat.h" #include "commands.h" +#include "land.h" +#include "mission.h" +#include "path.h" +#include "ship.h" int assa(void) diff --git a/src/lib/commands/atta.c b/src/lib/commands/atta.c index c38e3f59..4e6a4e24 100644 --- a/src/lib/commands/atta.c +++ b/src/lib/commands/atta.c @@ -35,19 +35,12 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "sect.h" -#include "path.h" -#include "nat.h" -#include "xy.h" -#include "land.h" -#include "nsc.h" -#include "mission.h" -#include "ship.h" #include "combat.h" #include "commands.h" +#include "land.h" +#include "mission.h" +#include "path.h" +#include "ship.h" int atta(void) diff --git a/src/lib/commands/bdes.c b/src/lib/commands/bdes.c index 20186424..04e76722 100644 --- a/src/lib/commands/bdes.c +++ b/src/lib/commands/bdes.c @@ -33,14 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "path.h" -#include "nsc.h" -#include "nat.h" +#include #include "commands.h" +#include "map.h" +#include "path.h" int bdes(void) diff --git a/src/lib/commands/best.c b/src/lib/commands/best.c index a2a32b26..366742b7 100644 --- a/src/lib/commands/best.c +++ b/src/lib/commands/best.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "path.h" -#include "nsc.h" -#include "nat.h" #include "commands.h" +#include "path.h" int best(void) diff --git a/src/lib/commands/boar.c b/src/lib/commands/boar.c index 4ba1f3aa..d29e9c25 100644 --- a/src/lib/commands/boar.c +++ b/src/lib/commands/boar.c @@ -33,20 +33,13 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "sect.h" -#include "path.h" -#include "nat.h" -#include "xy.h" -#include "land.h" -#include "nsc.h" -#include "mission.h" -#include "ship.h" #include "combat.h" -#include "retreat.h" #include "commands.h" +#include "land.h" +#include "mission.h" +#include "path.h" +#include "retreat.h" +#include "ship.h" int boar(void) diff --git a/src/lib/commands/bomb.c b/src/lib/commands/bomb.c index 62257ec3..806f30c7 100644 --- a/src/lib/commands/bomb.c +++ b/src/lib/commands/bomb.c @@ -36,24 +36,16 @@ #include #include -#include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "land.h" +#include "commands.h" +#include "damage.h" #include "item.h" +#include "land.h" +#include "news.h" +#include "optlist.h" +#include "path.h" #include "plane.h" #include "retreat.h" -#include "xy.h" -#include "nsc.h" -#include "news.h" -#include "file.h" -#include "nat.h" -#include "path.h" -#include "optlist.h" -#include "damage.h" -#include "commands.h" +#include "ship.h" static void pin_bomb(struct emp_qelem *list, struct sctstr *target); static void strat_bomb(struct emp_qelem *list, struct sctstr *target); diff --git a/src/lib/commands/brea.c b/src/lib/commands/brea.c index 9b3dee2a..9a9e924c 100644 --- a/src/lib/commands/brea.c +++ b/src/lib/commands/brea.c @@ -33,10 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "nat.h" #include "commands.h" int diff --git a/src/lib/commands/budg.c b/src/lib/commands/budg.c index ecd85f3a..907d558d 100644 --- a/src/lib/commands/budg.c +++ b/src/lib/commands/budg.c @@ -36,22 +36,15 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "sect.h" -#include "product.h" -#include "nat.h" -#include "item.h" -#include "file.h" -#include "ship.h" -#include "land.h" -#include "plane.h" -#include "optlist.h" +#include #include "budg.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "optlist.h" +#include "plane.h" +#include "product.h" +#include "ship.h" static void calc_all(long (*p_sect)[2], int *taxes, int *Ncivs, int *Nuws, int *bars, int *Nbars, int *mil, diff --git a/src/lib/commands/buil.c b/src/lib/commands/buil.c index 9d1c0ede..c75f0a2e 100644 --- a/src/lib/commands/buil.c +++ b/src/lib/commands/buil.c @@ -35,23 +35,17 @@ #include #include -#include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "sect.h" -#include "nat.h" -#include "ship.h" -#include "land.h" -#include "nuke.h" -#include "plane.h" -#include "xy.h" -#include "nsc.h" -#include "treaty.h" -#include "file.h" -#include "path.h" -#include "optlist.h" #include "commands.h" +#include "land.h" +#include "lost.h" +#include "map.h" +#include "nuke.h" +#include "optlist.h" +#include "path.h" +#include "plague.h" +#include "plane.h" +#include "ship.h" +#include "treaty.h" static int build_nuke(struct sctstr *sp, struct nchrstr *np, short *vec, int tlev); diff --git a/src/lib/commands/buy.c b/src/lib/commands/buy.c index 2188239b..c77d20c6 100644 --- a/src/lib/commands/buy.c +++ b/src/lib/commands/buy.c @@ -35,23 +35,16 @@ #include -#include "misc.h" -#include "xy.h" -#include "file.h" -#include "sect.h" -#include "nat.h" -#include "news.h" -#include "nsc.h" +#include "commands.h" +#include "commodity.h" #include "item.h" #include "land.h" -#include "commodity.h" +#include "loan.h" +#include "news.h" +#include "optlist.h" #include "plane.h" #include "ship.h" #include "trade.h" -#include "player.h" -#include "loan.h" -#include "commands.h" -#include "optlist.h" /* * format: buy diff --git a/src/lib/commands/capi.c b/src/lib/commands/capi.c index 78cfbe30..ccfa9c8e 100644 --- a/src/lib/commands/capi.c +++ b/src/lib/commands/capi.c @@ -34,13 +34,6 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" int diff --git a/src/lib/commands/carg.c b/src/lib/commands/carg.c index ce2d0bd1..ebe3efea 100644 --- a/src/lib/commands/carg.c +++ b/src/lib/commands/carg.c @@ -33,15 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "land.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" #include "optlist.h" +#include "ship.h" int carg(void) diff --git a/src/lib/commands/cede.c b/src/lib/commands/cede.c index 87f88458..53e16e8b 100644 --- a/src/lib/commands/cede.c +++ b/src/lib/commands/cede.c @@ -34,19 +34,13 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include "plane.h" -#include "land.h" -#include "ship.h" -#include "nuke.h" #include "commands.h" +#include "land.h" +#include "lost.h" +#include "nuke.h" +#include "path.h" +#include "plane.h" +#include "ship.h" static void cede_hdr(void); static int cede_sect(struct nstr_sect *, natid); diff --git a/src/lib/commands/cens.c b/src/lib/commands/cens.c index 5366f6cc..c71660ef 100644 --- a/src/lib/commands/cens.c +++ b/src/lib/commands/cens.c @@ -33,10 +33,9 @@ #include -#include "prototypes.h" -#include "path.h" #include "commands.h" #include "optlist.h" +#include "path.h" static void cens_hdr(void); diff --git a/src/lib/commands/chan.c b/src/lib/commands/chan.c index f1eb26c9..f19607d7 100644 --- a/src/lib/commands/chan.c +++ b/src/lib/commands/chan.c @@ -33,14 +33,10 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" +#include "commands.h" #include "news.h" #include "optlist.h" -#include "commands.h" +#include int chan(void) diff --git a/src/lib/commands/coas.c b/src/lib/commands/coas.c index 28324317..c36c7a79 100644 --- a/src/lib/commands/coas.c +++ b/src/lib/commands/coas.c @@ -34,16 +34,9 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" #include "optlist.h" +#include "ship.h" #define TSIZE 200 diff --git a/src/lib/commands/coll.c b/src/lib/commands/coll.c index e6439d76..737c584e 100644 --- a/src/lib/commands/coll.c +++ b/src/lib/commands/coll.c @@ -34,16 +34,11 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "sect.h" +#include "commands.h" #include "item.h" #include "loan.h" +#include "lost.h" #include "news.h" -#include "nat.h" -#include "xy.h" -#include "commands.h" #include "optlist.h" int diff --git a/src/lib/commands/comm.c b/src/lib/commands/comm.c index 762994c3..14d11282 100644 --- a/src/lib/commands/comm.c +++ b/src/lib/commands/comm.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "path.h" -#include "nat.h" #include "commands.h" +#include "path.h" static void prthresh(int val); diff --git a/src/lib/commands/cons.c b/src/lib/commands/cons.c index 7ed3ae73..f9c08d15 100644 --- a/src/lib/commands/cons.c +++ b/src/lib/commands/cons.c @@ -33,17 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "loan.h" -#include "nat.h" -#include "treaty.h" -#include "news.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "loan.h" +#include "news.h" #include "optlist.h" +#include "treaty.h" /* * Things common to a loan or treaty. diff --git a/src/lib/commands/conv.c b/src/lib/commands/conv.c index 4c340422..66257fcd 100644 --- a/src/lib/commands/conv.c +++ b/src/lib/commands/conv.c @@ -37,15 +37,8 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "land.h" #include "commands.h" +#include "land.h" static long do_conv(struct nstr_sect nstr, int uwtoconvert, int for_real); diff --git a/src/lib/commands/coun.c b/src/lib/commands/coun.c index c9c7154d..4022bb39 100644 --- a/src/lib/commands/coun.c +++ b/src/lib/commands/coun.c @@ -33,15 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include -#include #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/cuto.c b/src/lib/commands/cuto.c index 1d74fbba..94fbd534 100644 --- a/src/lib/commands/cuto.c +++ b/src/lib/commands/cuto.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" #include "commands.h" +#include "path.h" int cuto(void) diff --git a/src/lib/commands/decl.c b/src/lib/commands/decl.c index 266603b7..20e1e085 100644 --- a/src/lib/commands/decl.c +++ b/src/lib/commands/decl.c @@ -33,12 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "xy.h" -#include "nsc.h" #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/deli.c b/src/lib/commands/deli.c index 2034ebcd..f32430e4 100644 --- a/src/lib/commands/deli.c +++ b/src/lib/commands/deli.c @@ -33,16 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "item.h" -#include "file.h" -#include "path.h" -#include "nsc.h" -#include "nat.h" #include "commands.h" +#include "item.h" +#include "path.h" int deli(void) diff --git a/src/lib/commands/demo.c b/src/lib/commands/demo.c index 9dad2930..2e81e9b7 100644 --- a/src/lib/commands/demo.c +++ b/src/lib/commands/demo.c @@ -33,13 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" #include "commands.h" /* diff --git a/src/lib/commands/desi.c b/src/lib/commands/desi.c index 30b6fa1c..b5b2f74e 100644 --- a/src/lib/commands/desi.c +++ b/src/lib/commands/desi.c @@ -33,16 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "path.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "optlist.h" #include "commands.h" +#include "map.h" +#include "optlist.h" +#include "path.h" static long do_desi(struct natstr *natp, char *sects, char *deschar, long cash, int for_real); diff --git a/src/lib/commands/disa.c b/src/lib/commands/disa.c index e97fb0ac..109d477b 100644 --- a/src/lib/commands/disa.c +++ b/src/lib/commands/disa.c @@ -34,7 +34,9 @@ #include #include -#include "misc.h" +#if !defined(_WIN32) +#include +#endif #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/dist.c b/src/lib/commands/dist.c index b5f09347..cf89b531 100644 --- a/src/lib/commands/dist.c +++ b/src/lib/commands/dist.c @@ -35,15 +35,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" -#include "path.h" #include "commands.h" +#include "path.h" /* * distribute diff --git a/src/lib/commands/drop.c b/src/lib/commands/drop.c index a0aba4c6..2775c40d 100644 --- a/src/lib/commands/drop.c +++ b/src/lib/commands/drop.c @@ -33,18 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "item.h" -#include "plane.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "path.h" #include "commands.h" +#include "item.h" +#include "path.h" +#include "plane.h" +#include "ship.h" int drop(void) diff --git a/src/lib/commands/dump.c b/src/lib/commands/dump.c index af020b7f..3073e39e 100644 --- a/src/lib/commands/dump.c +++ b/src/lib/commands/dump.c @@ -34,16 +34,9 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" #include "commands.h" #include "optlist.h" +#include "path.h" int dump(void) diff --git a/src/lib/commands/echo.c b/src/lib/commands/echo.c index fc4c194e..680d5594 100644 --- a/src/lib/commands/echo.c +++ b/src/lib/commands/echo.c @@ -33,8 +33,6 @@ #include -#include "misc.h" -#include "player.h" #include "commands.h" int diff --git a/src/lib/commands/edit.c b/src/lib/commands/edit.c index e7e1a46e..77647e75 100644 --- a/src/lib/commands/edit.c +++ b/src/lib/commands/edit.c @@ -39,23 +39,15 @@ #include #include -#include -#include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "xy.h" -#include "sect.h" -#include "nat.h" -#include "news.h" -#include "nsc.h" +#include "commands.h" #include "item.h" -#include "file.h" +#include "land.h" +#include "lost.h" +#include "news.h" +#include "optlist.h" +#include "plague.h" #include "plane.h" #include "ship.h" -#include "land.h" -#include "optlist.h" -#include "commands.h" #define END -1 diff --git a/src/lib/commands/enab.c b/src/lib/commands/enab.c index 04cae1a0..9ae4972b 100644 --- a/src/lib/commands/enab.c +++ b/src/lib/commands/enab.c @@ -33,9 +33,9 @@ #include -#include -#include -#include "misc.h" +#if !defined(_WIN32) +#include +#endif #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/enli.c b/src/lib/commands/enli.c index 2f38c635..81e33882 100644 --- a/src/lib/commands/enli.c +++ b/src/lib/commands/enli.c @@ -33,15 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "treaty.h" -#include "file.h" #include "commands.h" +#include "treaty.h" int enli(void) diff --git a/src/lib/commands/expl.c b/src/lib/commands/expl.c index 07adc860..2c7bc42e 100644 --- a/src/lib/commands/expl.c +++ b/src/lib/commands/expl.c @@ -33,17 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "item.h" -#include "file.h" -#include "nat.h" -#include "optlist.h" #include "commands.h" +#include "item.h" +#include "map.h" +#include "optlist.h" +#include "plague.h" static int explore_map(coord curx, coord cury, char *arg); diff --git a/src/lib/commands/fina.c b/src/lib/commands/fina.c index b0c83c57..b800531a 100644 --- a/src/lib/commands/fina.c +++ b/src/lib/commands/fina.c @@ -35,14 +35,8 @@ #include #include -#include "misc.h" -#include "player.h" -#include "loan.h" -#include "file.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" #include "commands.h" +#include "loan.h" #include "optlist.h" /* diff --git a/src/lib/commands/flash.c b/src/lib/commands/flash.c index e0c415bf..49d186a7 100644 --- a/src/lib/commands/flash.c +++ b/src/lib/commands/flash.c @@ -34,11 +34,6 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" #include "commands.h" int diff --git a/src/lib/commands/flee.c b/src/lib/commands/flee.c index 07e3ad6a..267c3080 100644 --- a/src/lib/commands/flee.c +++ b/src/lib/commands/flee.c @@ -34,12 +34,8 @@ #include #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "ship.h" int flee(void) diff --git a/src/lib/commands/fly.c b/src/lib/commands/fly.c index 747984ac..2d459c58 100644 --- a/src/lib/commands/fly.c +++ b/src/lib/commands/fly.c @@ -34,18 +34,11 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "item.h" -#include "plane.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "path.h" #include "commands.h" +#include "item.h" +#include "path.h" +#include "plane.h" +#include "ship.h" int fly(void) diff --git a/src/lib/commands/foll.c b/src/lib/commands/foll.c index 307cd0fa..3600b57e 100644 --- a/src/lib/commands/foll.c +++ b/src/lib/commands/foll.c @@ -33,16 +33,10 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" #include "commands.h" #include "optlist.h" +#include "ship.h" +#include int foll(void) diff --git a/src/lib/commands/forc.c b/src/lib/commands/forc.c index fe775a0d..9014ab38 100644 --- a/src/lib/commands/forc.c +++ b/src/lib/commands/forc.c @@ -33,11 +33,8 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "empthread.h" #include "commands.h" +#include "empthread.h" #include "server.h" int diff --git a/src/lib/commands/fort.c b/src/lib/commands/fort.c index a457fae4..8c074071 100644 --- a/src/lib/commands/fort.c +++ b/src/lib/commands/fort.c @@ -33,12 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "land.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" #include "optlist.h" int diff --git a/src/lib/commands/fuel.c b/src/lib/commands/fuel.c index 0bead0df..449bf039 100644 --- a/src/lib/commands/fuel.c +++ b/src/lib/commands/fuel.c @@ -33,15 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "optlist.h" +#include #include "commands.h" #include "empobj.h" +#include "optlist.h" +#include "plague.h" int fuel(void) diff --git a/src/lib/commands/give.c b/src/lib/commands/give.c index 94b0a63c..3903be0c 100644 --- a/src/lib/commands/give.c +++ b/src/lib/commands/give.c @@ -34,16 +34,9 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" -#include "news.h" -#include "xy.h" -#include "nsc.h" -#include "item.h" -#include "file.h" #include "commands.h" +#include "item.h" +#include "news.h" #include "optlist.h" /* diff --git a/src/lib/commands/grin.c b/src/lib/commands/grin.c index f661b813..c8924602 100644 --- a/src/lib/commands/grin.c +++ b/src/lib/commands/grin.c @@ -33,15 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" -#include "product.h" #include "commands.h" +#include "product.h" int grin(void) diff --git a/src/lib/commands/hard.c b/src/lib/commands/hard.c index da69a547..9b2c9bd9 100644 --- a/src/lib/commands/hard.c +++ b/src/lib/commands/hard.c @@ -33,17 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" +#include "commands.h" #include "item.h" #include "plane.h" #include "ship.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" -#include "commands.h" /* * harden diff --git a/src/lib/commands/head.c b/src/lib/commands/head.c index 7ccd950d..e3b9e7d9 100644 --- a/src/lib/commands/head.c +++ b/src/lib/commands/head.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "news.h" -#include "nat.h" -#include "file.h" -#include "xy.h" -#include "nsc.h" #include "commands.h" +#include "news.h" struct histstr { int h_past; diff --git a/src/lib/commands/improve.c b/src/lib/commands/improve.c index 1cb24bd4..db673a67 100644 --- a/src/lib/commands/improve.c +++ b/src/lib/commands/improve.c @@ -33,17 +33,9 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "optlist.h" +#include "path.h" int improve(void) diff --git a/src/lib/commands/info.c b/src/lib/commands/info.c index 783e7b8a..ee954ff0 100644 --- a/src/lib/commands/info.c +++ b/src/lib/commands/info.c @@ -37,18 +37,14 @@ #include +#include #include -#include -#include #include -#include #if !defined(_WIN32) #include #else #include #endif -#include "misc.h" -#include "player.h" #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/land.c b/src/lib/commands/land.c index bb70f452..5ba37e1c 100644 --- a/src/lib/commands/land.c +++ b/src/lib/commands/land.c @@ -33,14 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "land.h" -#include "nsc.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "land.h" +#include "optlist.h" int land(void) diff --git a/src/lib/commands/laun.c b/src/lib/commands/laun.c index 926feb5a..66a3552e 100644 --- a/src/lib/commands/laun.c +++ b/src/lib/commands/laun.c @@ -35,21 +35,14 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "plane.h" -#include "news.h" -#include "mission.h" -#include "ship.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include "optlist.h" -#include "damage.h" #include "commands.h" +#include "damage.h" +#include "mission.h" +#include "news.h" +#include "optlist.h" +#include "path.h" +#include "plane.h" +#include "ship.h" static int launch_as(struct plnstr *pp); static int launch_missile(struct plnstr *pp, int sublaunch); diff --git a/src/lib/commands/lboard.c b/src/lib/commands/lboard.c index a6e2442f..8b63a775 100644 --- a/src/lib/commands/lboard.c +++ b/src/lib/commands/lboard.c @@ -33,19 +33,12 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "sect.h" -#include "path.h" -#include "nat.h" -#include "xy.h" -#include "land.h" -#include "nsc.h" -#include "mission.h" -#include "ship.h" #include "combat.h" #include "commands.h" +#include "land.h" +#include "mission.h" +#include "path.h" +#include "ship.h" int lboa(void) diff --git a/src/lib/commands/ldump.c b/src/lib/commands/ldump.c index cae05243..b3a0fc32 100644 --- a/src/lib/commands/ldump.c +++ b/src/lib/commands/ldump.c @@ -34,16 +34,9 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "land.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "land.h" +#include "optlist.h" int ldump(void) diff --git a/src/lib/commands/ledg.c b/src/lib/commands/ledg.c index 32045b81..d2bd805c 100644 --- a/src/lib/commands/ledg.c +++ b/src/lib/commands/ledg.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "loan.h" -#include "file.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" #include "commands.h" +#include "loan.h" #include "optlist.h" int diff --git a/src/lib/commands/leve.c b/src/lib/commands/leve.c index cee57cc3..054a240c 100644 --- a/src/lib/commands/leve.c +++ b/src/lib/commands/leve.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" #include "commands.h" +#include "path.h" int leve(void) diff --git a/src/lib/commands/load.c b/src/lib/commands/load.c index cf22981b..002c8831 100644 --- a/src/lib/commands/load.c +++ b/src/lib/commands/load.c @@ -35,21 +35,15 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "file.h" -#include "plague.h" -#include "sect.h" -#include "ship.h" -#include "plane.h" -#include "land.h" -#include "item.h" -#include "nsc.h" -#include "nat.h" -#include "optlist.h" +#include #include "commands.h" +#include "empobj.h" +#include "item.h" +#include "land.h" +#include "optlist.h" +#include "plague.h" +#include "plane.h" +#include "ship.h" /* * The values 1 and -1 are important below, don't change them. diff --git a/src/lib/commands/look.c b/src/lib/commands/look.c index e482dcc6..f1b22974 100644 --- a/src/lib/commands/look.c +++ b/src/lib/commands/look.c @@ -33,20 +33,13 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "ship.h" -#include "land.h" -#include "plane.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include #include "commands.h" +#include "land.h" +#include "map.h" #include "optlist.h" +#include "path.h" +#include "plane.h" +#include "ship.h" static void look_ship(struct shpstr *lookship); static void look_land(struct lndstr *lookland); diff --git a/src/lib/commands/lost.c b/src/lib/commands/lost.c index db833b31..a3b3b739 100644 --- a/src/lib/commands/lost.c +++ b/src/lib/commands/lost.c @@ -33,11 +33,8 @@ #include -#include "player.h" -#include "nsc.h" -#include "file.h" -#include "lost.h" #include "commands.h" +#include "lost.h" int lost(void) diff --git a/src/lib/commands/lstat.c b/src/lib/commands/lstat.c index 9b977d71..1b293092 100644 --- a/src/lib/commands/lstat.c +++ b/src/lib/commands/lstat.c @@ -33,12 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "land.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" int lsta(void) diff --git a/src/lib/commands/lten.c b/src/lib/commands/lten.c index 2dd641b4..0374debe 100644 --- a/src/lib/commands/lten.c +++ b/src/lib/commands/lten.c @@ -37,16 +37,12 @@ #include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "file.h" -#include "ship.h" -#include "item.h" -#include "nsc.h" -#include "plane.h" -#include "land.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "plague.h" +#include "plane.h" +#include "ship.h" static void expose_land(struct shpstr *s1, struct lndstr *l1); diff --git a/src/lib/commands/map.c b/src/lib/commands/map.c index 5cae613b..6fda3bf4 100644 --- a/src/lib/commands/map.c +++ b/src/lib/commands/map.c @@ -34,17 +34,11 @@ #include -#include "misc.h" -#include "nat.h" -#include "file.h" -#include "player.h" -#include "map.h" -#include "ship.h" -#include "land.h" -#include "xy.h" -#include "nsc.h" #include "commands.h" +#include "land.h" +#include "map.h" #include "optlist.h" +#include "ship.h" int map(void) diff --git a/src/lib/commands/marc.c b/src/lib/commands/marc.c index df246616..b6293e34 100644 --- a/src/lib/commands/marc.c +++ b/src/lib/commands/marc.c @@ -35,15 +35,11 @@ #include #include -#include "misc.h" -#include "player.h" -#include "land.h" -#include "xy.h" -#include "nsc.h" -#include "path.h" -#include "file.h" -#include "map.h" #include "commands.h" +#include "file.h" +#include "land.h" +#include "map.h" +#include "path.h" static int set_leader(struct emp_qelem *list, struct lndstr **leaderp); static void switch_leader(struct emp_qelem *list, int land_uid); diff --git a/src/lib/commands/mark.c b/src/lib/commands/mark.c index bcb2ccaf..82088525 100644 --- a/src/lib/commands/mark.c +++ b/src/lib/commands/mark.c @@ -35,12 +35,9 @@ #include -#include "misc.h" -#include "item.h" -#include "commodity.h" -#include "player.h" -#include "file.h" #include "commands.h" +#include "commodity.h" +#include "item.h" #include "optlist.h" int diff --git a/src/lib/commands/mfir.c b/src/lib/commands/mfir.c index 11aeb9c8..f40218a3 100644 --- a/src/lib/commands/mfir.c +++ b/src/lib/commands/mfir.c @@ -33,18 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "retreat.h" -#include "nsc.h" -#include "file.h" -#include "queue.h" -#include -#include "optlist.h" -#include "damage.h" #include "commands.h" +#include "damage.h" #include "empobj.h" +#include "optlist.h" +#include "retreat.h" enum targ_type { targ_land, targ_ship, targ_sub, targ_unit, targ_bogus diff --git a/src/lib/commands/mine.c b/src/lib/commands/mine.c index d67f12fb..af5d94ae 100644 --- a/src/lib/commands/mine.c +++ b/src/lib/commands/mine.c @@ -33,16 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "land.h" -#include "sect.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" +#include "map.h" +#include "ship.h" /* * format: mine diff --git a/src/lib/commands/miss.c b/src/lib/commands/miss.c index 8ea878a3..2621602a 100644 --- a/src/lib/commands/miss.c +++ b/src/lib/commands/miss.c @@ -34,16 +34,11 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "path.h" -#include "mission.h" #include "commands.h" -#include "optlist.h" #include "empobj.h" +#include "mission.h" +#include "optlist.h" +#include "path.h" /* * mission [] diff --git a/src/lib/commands/mobq.c b/src/lib/commands/mobq.c index 7eae1da1..c50c6710 100644 --- a/src/lib/commands/mobq.c +++ b/src/lib/commands/mobq.c @@ -34,14 +34,9 @@ #include #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" #include "optlist.h" +#include "ship.h" int diff --git a/src/lib/commands/mobu.c b/src/lib/commands/mobu.c index 5f76bc03..00710f1a 100644 --- a/src/lib/commands/mobu.c +++ b/src/lib/commands/mobu.c @@ -33,16 +33,10 @@ #include -#include -#include -#include "misc.h" -#include "player.h" -#include "nsc.h" -#include "path.h" #include "commands.h" #include "optlist.h" +#include "path.h" #include "server.h" -#include "prototypes.h" int mobupdate(void) diff --git a/src/lib/commands/mora.c b/src/lib/commands/mora.c index c4831d4b..54efbb12 100644 --- a/src/lib/commands/mora.c +++ b/src/lib/commands/mora.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "land.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" #include "commands.h" +#include "land.h" #include "optlist.h" int diff --git a/src/lib/commands/move.c b/src/lib/commands/move.c index 5427832a..0953eb39 100644 --- a/src/lib/commands/move.c +++ b/src/lib/commands/move.c @@ -33,19 +33,12 @@ #include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "sect.h" -#include "item.h" -#include "file.h" -#include "xy.h" -#include "nat.h" -#include "nsc.h" -#include "land.h" -#include "path.h" -#include "optlist.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "optlist.h" +#include "path.h" +#include "plague.h" static int cmd_move_map(coord curx, coord cury, char *arg); diff --git a/src/lib/commands/name.c b/src/lib/commands/name.c index 2cff13f6..4115956e 100644 --- a/src/lib/commands/name.c +++ b/src/lib/commands/name.c @@ -33,14 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "nsc.h" -#include "file.h" -#include "path.h" #include "commands.h" #include "optlist.h" +#include "path.h" +#include "ship.h" /* * name diff --git a/src/lib/commands/nati.c b/src/lib/commands/nati.c index 78f5336f..104964e8 100644 --- a/src/lib/commands/nati.c +++ b/src/lib/commands/nati.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "sect.h" -#include "file.h" -#include "xy.h" -#include "optlist.h" #include "commands.h" +#include "optlist.h" int nati(void) diff --git a/src/lib/commands/navi.c b/src/lib/commands/navi.c index f068eb3b..a20e4039 100644 --- a/src/lib/commands/navi.c +++ b/src/lib/commands/navi.c @@ -34,18 +34,11 @@ #include #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include "map.h" #include "commands.h" +#include "map.h" #include "optlist.h" +#include "path.h" +#include "ship.h" static int set_flagship(struct emp_qelem *list, struct shpstr **flagshipp); static void switch_flagship(struct emp_qelem *list, int ship_uid); diff --git a/src/lib/commands/ndump.c b/src/lib/commands/ndump.c index e781e4a2..0c0347d8 100644 --- a/src/lib/commands/ndump.c +++ b/src/lib/commands/ndump.c @@ -34,12 +34,8 @@ #include -#include "misc.h" -#include "player.h" -#include "nuke.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "nuke.h" int ndump(void) diff --git a/src/lib/commands/new.c b/src/lib/commands/new.c index c8dd174d..c84bf7dd 100644 --- a/src/lib/commands/new.c +++ b/src/lib/commands/new.c @@ -33,20 +33,15 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "sect.h" -#include "path.h" -#include "file.h" -#include "xy.h" -#include "tel.h" -#include "land.h" -#include "nsc.h" -#include "optlist.h" -#include "commands.h" - #include +#if !defined(_WIN32) +#include +#endif +#include "commands.h" +#include "land.h" +#include "optlist.h" +#include "path.h" +#include "tel.h" static int isok(int x, int y); static void ok(signed char *map, int x, int y); diff --git a/src/lib/commands/newe.c b/src/lib/commands/newe.c index d62f85d1..18792c12 100644 --- a/src/lib/commands/newe.c +++ b/src/lib/commands/newe.c @@ -33,15 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "sect.h" -#include "nat.h" -#include "item.h" -#include "file.h" #include "commands.h" +#include "item.h" #include "optlist.h" int diff --git a/src/lib/commands/news.c b/src/lib/commands/news.c index 7effc5bc..cb4fc065 100644 --- a/src/lib/commands/news.c +++ b/src/lib/commands/news.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "news.h" -#include "file.h" -#include "xy.h" -#include "nsc.h" #include "commands.h" +#include "news.h" #include "optlist.h" static void preport(struct nwsstr *np); diff --git a/src/lib/commands/nuke.c b/src/lib/commands/nuke.c index 6c51498a..85a03c50 100644 --- a/src/lib/commands/nuke.c +++ b/src/lib/commands/nuke.c @@ -34,15 +34,9 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nuke.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" #include "commands.h" +#include "nuke.h" +#include "plane.h" int nuke(void) diff --git a/src/lib/commands/offe.c b/src/lib/commands/offe.c index ce7a4870..27ecfbf5 100644 --- a/src/lib/commands/offe.c +++ b/src/lib/commands/offe.c @@ -34,16 +34,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "loan.h" -#include "treaty.h" -#include "file.h" #include "commands.h" +#include "loan.h" #include "optlist.h" +#include "treaty.h" static int do_treaty(void); static int do_loan(void); diff --git a/src/lib/commands/orde.c b/src/lib/commands/orde.c index 23c3bb35..f3ae6a36 100644 --- a/src/lib/commands/orde.c +++ b/src/lib/commands/orde.c @@ -34,20 +34,12 @@ #include -#include #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include "item.h" #include "commands.h" +#include "item.h" #include "optlist.h" +#include "path.h" +#include "ship.h" /* * Command syntax: diff --git a/src/lib/commands/orig.c b/src/lib/commands/orig.c index 4c0c7e52..848453d6 100644 --- a/src/lib/commands/orig.c +++ b/src/lib/commands/orig.c @@ -34,12 +34,7 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nat.h" -#include "file.h" +#include #include "commands.h" int diff --git a/src/lib/commands/para.c b/src/lib/commands/para.c index 62b0a6a9..f5c1181d 100644 --- a/src/lib/commands/para.c +++ b/src/lib/commands/para.c @@ -34,21 +34,14 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "item.h" -#include "plane.h" -#include "land.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "path.h" -#include "mission.h" #include "combat.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "mission.h" +#include "path.h" +#include "plane.h" +#include "ship.h" static int paradrop(struct emp_qelem *list, coord x, coord y); diff --git a/src/lib/commands/path.c b/src/lib/commands/path.c index 61f058f6..36cb5045 100644 --- a/src/lib/commands/path.c +++ b/src/lib/commands/path.c @@ -34,17 +34,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" -#include "sect.h" -#include "path.h" -#include "map.h" #include "commands.h" +#include "map.h" #include "optlist.h" +#include "path.h" int path(void) diff --git a/src/lib/commands/payo.c b/src/lib/commands/payo.c index c8ee9225..d55002e4 100644 --- a/src/lib/commands/payo.c +++ b/src/lib/commands/payo.c @@ -33,16 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "ship.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" #include "commands.h" #include "optlist.h" +#include "ship.h" int payo(void) diff --git a/src/lib/commands/pboa.c b/src/lib/commands/pboa.c index dd5f0258..cf2b1a7c 100644 --- a/src/lib/commands/pboa.c +++ b/src/lib/commands/pboa.c @@ -33,11 +33,8 @@ #include -#include "misc.h" -#include "file.h" -#include "sect.h" -#include "plane.h" #include "commands.h" +#include "plane.h" int pboa(void) diff --git a/src/lib/commands/pdump.c b/src/lib/commands/pdump.c index e8890ae6..402cf08d 100644 --- a/src/lib/commands/pdump.c +++ b/src/lib/commands/pdump.c @@ -34,16 +34,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "plane.h" -#include "nsc.h" -#include "nuke.h" -#include "file.h" -#include "nat.h" -#include "optlist.h" #include "commands.h" +#include "nuke.h" +#include "optlist.h" +#include "plane.h" int pdump(void) diff --git a/src/lib/commands/peek.c b/src/lib/commands/peek.c index 625fc659..629d40df 100644 --- a/src/lib/commands/peek.c +++ b/src/lib/commands/peek.c @@ -35,12 +35,6 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" #include "commands.h" int diff --git a/src/lib/commands/plan.c b/src/lib/commands/plan.c index 69c883a8..d014a06b 100644 --- a/src/lib/commands/plan.c +++ b/src/lib/commands/plan.c @@ -35,14 +35,10 @@ #include -#include "misc.h" -#include "player.h" -#include "plane.h" -#include "nsc.h" -#include "nuke.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "nuke.h" +#include "optlist.h" +#include "plane.h" int plan(void) diff --git a/src/lib/commands/play.c b/src/lib/commands/play.c index b50d7216..f629dd07 100644 --- a/src/lib/commands/play.c +++ b/src/lib/commands/play.c @@ -34,10 +34,6 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "nat.h" #include "optlist.h" #include "commands.h" diff --git a/src/lib/commands/powe.c b/src/lib/commands/powe.c index 62a2b0b4..90008344 100644 --- a/src/lib/commands/powe.c +++ b/src/lib/commands/powe.c @@ -36,24 +36,13 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" -#include "ship.h" -#include "land.h" -#include "power.h" -#include "item.h" -#include "plane.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "optlist.h" #include "commands.h" - - -#include +#include "item.h" +#include "land.h" +#include "optlist.h" +#include "plane.h" +#include "power.h" +#include "ship.h" struct powsort { float powval; diff --git a/src/lib/commands/prod.c b/src/lib/commands/prod.c index 85426880..33a9c5c2 100644 --- a/src/lib/commands/prod.c +++ b/src/lib/commands/prod.c @@ -35,17 +35,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "sect.h" -#include "product.h" -#include "nat.h" -#include "item.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "item.h" +#include "optlist.h" +#include "product.h" static void prprod(coord, coord, int, double, double, int, char, double, double, double, char[], int[], int[], int); diff --git a/src/lib/commands/pstat.c b/src/lib/commands/pstat.c index 712d443d..53b56425 100644 --- a/src/lib/commands/pstat.c +++ b/src/lib/commands/pstat.c @@ -33,13 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "plane.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "plane.h" int pstat(void) diff --git a/src/lib/commands/rada.c b/src/lib/commands/rada.c index 363246dd..3bf8aa8f 100644 --- a/src/lib/commands/rada.c +++ b/src/lib/commands/rada.c @@ -34,17 +34,10 @@ #include #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "ship.h" -#include "land.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" #include "commands.h" +#include "land.h" #include "optlist.h" +#include "ship.h" int rada(void) diff --git a/src/lib/commands/rang.c b/src/lib/commands/rang.c index cfb78226..3b9cecd9 100644 --- a/src/lib/commands/rang.c +++ b/src/lib/commands/rang.c @@ -33,13 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "plane.h" -#include "land.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" +#include "plane.h" int range(void) diff --git a/src/lib/commands/rea.c b/src/lib/commands/rea.c index 5e4063a9..d9cd2ab5 100644 --- a/src/lib/commands/rea.c +++ b/src/lib/commands/rea.c @@ -35,20 +35,11 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "tel.h" +#include #include "commands.h" -#include "optlist.h" #include "match.h" - -#include -#include -#if !defined(_WIN32) -#include -#endif +#include "optlist.h" +#include "tel.h" int rea(void) diff --git a/src/lib/commands/real.c b/src/lib/commands/real.c index 351221bd..0b99a2da 100644 --- a/src/lib/commands/real.c +++ b/src/lib/commands/real.c @@ -33,12 +33,7 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "xy.h" -#include "file.h" -#include "nsc.h" +#include #include "commands.h" static void diff --git a/src/lib/commands/reco.c b/src/lib/commands/reco.c index e1a5ba98..527f2a4a 100644 --- a/src/lib/commands/reco.c +++ b/src/lib/commands/reco.c @@ -33,17 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "plane.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "path.h" #include "commands.h" +#include "path.h" +#include "plane.h" +#include "ship.h" int reco(void) diff --git a/src/lib/commands/reje.c b/src/lib/commands/reje.c index 619a887e..357965c3 100644 --- a/src/lib/commands/reje.c +++ b/src/lib/commands/reje.c @@ -33,12 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "xy.h" -#include "nsc.h" #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/rela.c b/src/lib/commands/rela.c index 3106c639..264672d9 100644 --- a/src/lib/commands/rela.c +++ b/src/lib/commands/rela.c @@ -33,11 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "xy.h" #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/repa.c b/src/lib/commands/repa.c index f426433c..c6cf48a4 100644 --- a/src/lib/commands/repa.c +++ b/src/lib/commands/repa.c @@ -34,13 +34,9 @@ #include #include -#include "misc.h" -#include "player.h" -#include "nat.h" +#include "commands.h" #include "loan.h" #include "news.h" -#include "file.h" -#include "commands.h" #include "optlist.h" int diff --git a/src/lib/commands/repo.c b/src/lib/commands/repo.c index f4533923..d20e2228 100644 --- a/src/lib/commands/repo.c +++ b/src/lib/commands/repo.c @@ -35,10 +35,6 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/rese.c b/src/lib/commands/rese.c index a41f2cbf..34194ebc 100644 --- a/src/lib/commands/rese.c +++ b/src/lib/commands/rese.c @@ -35,20 +35,13 @@ #include -#include "misc.h" -#include "xy.h" -#include "file.h" -#include "sect.h" +#include "commands.h" +#include "commodity.h" #include "item.h" -#include "nsc.h" -#include "nat.h" #include "land.h" +#include "optlist.h" #include "plane.h" #include "ship.h" -#include "commodity.h" -#include "player.h" -#include "commands.h" -#include "optlist.h" int rese(void) diff --git a/src/lib/commands/reso.c b/src/lib/commands/reso.c index acdbf9ea..8de6b19d 100644 --- a/src/lib/commands/reso.c +++ b/src/lib/commands/reso.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" #include "commands.h" +#include "path.h" static void reso_hdr(void); diff --git a/src/lib/commands/retr.c b/src/lib/commands/retr.c index 2b3828c2..4bc6488e 100644 --- a/src/lib/commands/retr.c +++ b/src/lib/commands/retr.c @@ -34,15 +34,12 @@ #include -#include "misc.h" -#include "player.h" +#include +#include "commands.h" +#include "land.h" +#include "path.h" #include "retreat.h" #include "ship.h" -#include "land.h" -#include "nsc.h" -#include "file.h" -#include "path.h" -#include "commands.h" int retr(void) diff --git a/src/lib/commands/rout.c b/src/lib/commands/rout.c index 6d05b6f8..57a0db07 100644 --- a/src/lib/commands/rout.c +++ b/src/lib/commands/rout.c @@ -33,18 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nat.h" -#include "nsc.h" -#include "sect.h" -#include "item.h" -#include "path.h" -#include "file.h" -#include "map.h" #include "commands.h" +#include "item.h" +#include "map.h" #include "optlist.h" +#include "path.h" int rout(void) diff --git a/src/lib/commands/sabo.c b/src/lib/commands/sabo.c index 4411e256..ab2b152e 100644 --- a/src/lib/commands/sabo.c +++ b/src/lib/commands/sabo.c @@ -33,11 +33,8 @@ #include -#include "misc.h" -#include "land.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" int sabo(void) diff --git a/src/lib/commands/sail.c b/src/lib/commands/sail.c index bbb3ca7b..e622053e 100644 --- a/src/lib/commands/sail.c +++ b/src/lib/commands/sail.c @@ -34,15 +34,10 @@ #include #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "path.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" #include "optlist.h" +#include "path.h" +#include "ship.h" static int show_sail(struct nstr_item *nstr) diff --git a/src/lib/commands/sate.c b/src/lib/commands/sate.c index 6e5530f6..2461c046 100644 --- a/src/lib/commands/sate.c +++ b/src/lib/commands/sate.c @@ -35,15 +35,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "plane.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" +#include #include "commands.h" #include "optlist.h" +#include "plane.h" int sate(void) diff --git a/src/lib/commands/scra.c b/src/lib/commands/scra.c index 1bd9aa15..4236a77d 100644 --- a/src/lib/commands/scra.c +++ b/src/lib/commands/scra.c @@ -33,14 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" +#include #include "commands.h" -#include "optlist.h" #include "empobj.h" +#include "optlist.h" int scra(void) diff --git a/src/lib/commands/scut.c b/src/lib/commands/scut.c index 32c78783..d2ead896 100644 --- a/src/lib/commands/scut.c +++ b/src/lib/commands/scut.c @@ -33,14 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" +#include #include "commands.h" -#include "optlist.h" #include "empobj.h" +#include "optlist.h" static void scuttle_land(struct lndstr *); diff --git a/src/lib/commands/sdump.c b/src/lib/commands/sdump.c index 18ed63ea..d73017f3 100644 --- a/src/lib/commands/sdump.c +++ b/src/lib/commands/sdump.c @@ -34,16 +34,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "ship.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "land.h" +#include "optlist.h" +#include "ship.h" int sdump(void) diff --git a/src/lib/commands/sect.c b/src/lib/commands/sect.c index ed3c285f..cec2348c 100644 --- a/src/lib/commands/sect.c +++ b/src/lib/commands/sect.c @@ -33,15 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" -#include "map.h" #include "commands.h" +#include "map.h" #include "optlist.h" int diff --git a/src/lib/commands/sell.c b/src/lib/commands/sell.c index 763b44d1..ffafcea6 100644 --- a/src/lib/commands/sell.c +++ b/src/lib/commands/sell.c @@ -36,22 +36,13 @@ #include -#include "misc.h" -#include "xy.h" -#include "file.h" -#include "sect.h" +#include "commands.h" +#include "commodity.h" #include "item.h" -#include "nsc.h" -#include "nat.h" +#include "land.h" +#include "optlist.h" #include "plane.h" #include "ship.h" -#include /* bailey@math-cs.kent.edu */ -#include "commodity.h" -#include "land.h" -#include "player.h" -#include "commands.h" -#include "optlist.h" -/*#define EF_COMM 10*/ /* * format: sell diff --git a/src/lib/commands/set.c b/src/lib/commands/set.c index 404e9282..8fe0c66f 100644 --- a/src/lib/commands/set.c +++ b/src/lib/commands/set.c @@ -35,19 +35,13 @@ #include -#include "misc.h" -#include "sect.h" -#include "ship.h" -#include "land.h" -#include "plane.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "trade.h" -#include "file.h" -#include "player.h" #include "commands.h" +#include "empobj.h" +#include "land.h" #include "optlist.h" +#include "plane.h" +#include "ship.h" +#include "trade.h" /* * format: set diff --git a/src/lib/commands/setres.c b/src/lib/commands/setres.c index 1c7a8810..c27379ac 100644 --- a/src/lib/commands/setres.c +++ b/src/lib/commands/setres.c @@ -35,15 +35,7 @@ #include -#include #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" #include "commands.h" /* diff --git a/src/lib/commands/setsect.c b/src/lib/commands/setsect.c index 8e9b373a..66eaed3b 100644 --- a/src/lib/commands/setsect.c +++ b/src/lib/commands/setsect.c @@ -34,17 +34,10 @@ #include -#include #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nat.h" -#include "news.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "lost.h" +#include "news.h" #include "optlist.h" diff --git a/src/lib/commands/shar.c b/src/lib/commands/shar.c index 89845484..4c2dff5c 100644 --- a/src/lib/commands/shar.c +++ b/src/lib/commands/shar.c @@ -33,11 +33,6 @@ #include -#include "misc.h" -#include "nsc.h" -#include "nat.h" -#include "player.h" -#include "file.h" #include "commands.h" int diff --git a/src/lib/commands/shark.c b/src/lib/commands/shark.c index 96b8a865..e13ebe9f 100644 --- a/src/lib/commands/shark.c +++ b/src/lib/commands/shark.c @@ -35,13 +35,8 @@ #include #include -#include "misc.h" -#include "file.h" -#include "loan.h" -#include "nat.h" -#include "xy.h" -#include "player.h" #include "commands.h" +#include "loan.h" #include "optlist.h" int diff --git a/src/lib/commands/shi.c b/src/lib/commands/shi.c index 434011e6..dc2f4c81 100644 --- a/src/lib/commands/shi.c +++ b/src/lib/commands/shi.c @@ -33,14 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "nsc.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "land.h" +#include "optlist.h" +#include "ship.h" int shi(void) diff --git a/src/lib/commands/shoo.c b/src/lib/commands/shoo.c index 28657c0d..b3a9c2cc 100644 --- a/src/lib/commands/shoo.c +++ b/src/lib/commands/shoo.c @@ -33,18 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "news.h" -#include "item.h" -#include "path.h" -#include "nat.h" -#include "file.h" -#include "nsc.h" -#include "land.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "news.h" +#include "path.h" int shoo(void) diff --git a/src/lib/commands/show.c b/src/lib/commands/show.c index 772e4490..0f04c864 100644 --- a/src/lib/commands/show.c +++ b/src/lib/commands/show.c @@ -34,13 +34,9 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "optlist.h" -#include "subs.h" #include "commands.h" +#include "nuke.h" +#include "optlist.h" int show(void) diff --git a/src/lib/commands/shut.c b/src/lib/commands/shut.c index 3f8e4349..59b5020c 100644 --- a/src/lib/commands/shut.c +++ b/src/lib/commands/shut.c @@ -33,15 +33,9 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "empthread.h" -#include "nat.h" -#include "file.h" #include "commands.h" +#include "empthread.h" #include "server.h" -#include "prototypes.h" int shut(void) diff --git a/src/lib/commands/sinf.c b/src/lib/commands/sinf.c index 96ff8716..65a1b06a 100644 --- a/src/lib/commands/sinf.c +++ b/src/lib/commands/sinf.c @@ -33,16 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" +#include "combat.h" +#include "commands.h" #include "optlist.h" #include "path.h" -#include "commands.h" -#include "combat.h" static void prmobcost(struct sctstr *, int); diff --git a/src/lib/commands/skyw.c b/src/lib/commands/skyw.c index 90f27b7e..df47e012 100644 --- a/src/lib/commands/skyw.c +++ b/src/lib/commands/skyw.c @@ -33,16 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "plane.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" #include "commands.h" #include "optlist.h" +#include "plane.h" #define TSIZE 200 diff --git a/src/lib/commands/sona.c b/src/lib/commands/sona.c index 75c7308a..333038ec 100644 --- a/src/lib/commands/sona.c +++ b/src/lib/commands/sona.c @@ -34,22 +34,13 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" +#include "commands.h" +#include "map.h" +#include "optlist.h" +#include "path.h" +#include "plane.h" #include "retreat.h" #include "ship.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include "queue.h" -#include "plane.h" -#include -#include -#include "commands.h" -#include "optlist.h" static int blankrow(char *); diff --git a/src/lib/commands/spy.c b/src/lib/commands/spy.c index c7999c74..9c57ca20 100644 --- a/src/lib/commands/spy.c +++ b/src/lib/commands/spy.c @@ -34,19 +34,14 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "item.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" -#include "news.h" -#include "path.h" -#include "file.h" -#include "land.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "map.h" +#include "news.h" #include "optlist.h" +#include "path.h" +#include "plane.h" /* * format: spy diff --git a/src/lib/commands/sstat.c b/src/lib/commands/sstat.c index e72f5b3e..41e4a15a 100644 --- a/src/lib/commands/sstat.c +++ b/src/lib/commands/sstat.c @@ -33,12 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" +#include "ship.h" int sstat(void) diff --git a/src/lib/commands/stop.c b/src/lib/commands/stop.c index a21871ed..6e452f4a 100644 --- a/src/lib/commands/stop.c +++ b/src/lib/commands/stop.c @@ -35,13 +35,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "path.h" -#include "file.h" +#include #include "commands.h" #include "empobj.h" +#include "path.h" static int start_stop(int); static int start_stop_sector(char *, int); diff --git a/src/lib/commands/stre.c b/src/lib/commands/stre.c index 6c0ae748..271e72aa 100644 --- a/src/lib/commands/stre.c +++ b/src/lib/commands/stre.c @@ -33,18 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "sect.h" -#include "path.h" -#include "nat.h" -#include "xy.h" -#include "land.h" -#include "nsc.h" -#include "ship.h" #include "combat.h" #include "commands.h" +#include "land.h" +#include "path.h" +#include "ship.h" static double units_in_sector(struct combat *def); static void stre_hdr(void); diff --git a/src/lib/commands/strv.c b/src/lib/commands/strv.c index b8feae56..2811a4dc 100644 --- a/src/lib/commands/strv.c +++ b/src/lib/commands/strv.c @@ -34,19 +34,12 @@ #include #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" -#include "item.h" -#include "ship.h" -#include "optlist.h" -#include "land.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "optlist.h" +#include "path.h" +#include "ship.h" static void starv_sects(char *range); static void starv_ships(char *range); diff --git a/src/lib/commands/supp.c b/src/lib/commands/supp.c index a88ada62..48e6b668 100644 --- a/src/lib/commands/supp.c +++ b/src/lib/commands/supp.c @@ -33,12 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "land.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "land.h" int supp(void) diff --git a/src/lib/commands/surv.c b/src/lib/commands/surv.c index 910091e5..e2a79539 100644 --- a/src/lib/commands/surv.c +++ b/src/lib/commands/surv.c @@ -34,15 +34,8 @@ #include #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "map.h" #include "commands.h" +#include "map.h" #include "optlist.h" static char code_char(struct valstr, struct sctstr *sp); diff --git a/src/lib/commands/swap.c b/src/lib/commands/swap.c index 0f86ac02..68c892d4 100644 --- a/src/lib/commands/swap.c +++ b/src/lib/commands/swap.c @@ -33,15 +33,7 @@ #include -#include #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" #include "commands.h" static void print_res(struct sctstr *); diff --git a/src/lib/commands/tele.c b/src/lib/commands/tele.c index fea31012..f63c214e 100644 --- a/src/lib/commands/tele.c +++ b/src/lib/commands/tele.c @@ -33,14 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "tel.h" -#include "news.h" -#include "file.h" #include "commands.h" +#include "news.h" #include "optlist.h" +#include "tel.h" int tele(void) diff --git a/src/lib/commands/tend.c b/src/lib/commands/tend.c index 4f2d7c1e..40a83cb3 100644 --- a/src/lib/commands/tend.c +++ b/src/lib/commands/tend.c @@ -35,19 +35,12 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "plague.h" -#include "xy.h" -#include "file.h" -#include "ship.h" -#include "item.h" -#include "nsc.h" -#include "nat.h" -#include "land.h" -#include "plane.h" #include "commands.h" +#include "item.h" +#include "land.h" +#include "plague.h" +#include "plane.h" +#include "ship.h" static void expose_ship(struct shpstr *s1, struct shpstr *s2); static int tend_land(struct shpstr *tenderp, char *units); diff --git a/src/lib/commands/terr.c b/src/lib/commands/terr.c index c6f18f65..e24225dc 100644 --- a/src/lib/commands/terr.c +++ b/src/lib/commands/terr.c @@ -33,13 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" #include "commands.h" int diff --git a/src/lib/commands/thre.c b/src/lib/commands/thre.c index 369798df..da1b5d5b 100644 --- a/src/lib/commands/thre.c +++ b/src/lib/commands/thre.c @@ -34,15 +34,8 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "item.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" #include "commands.h" +#include "item.h" /* * threshold diff --git a/src/lib/commands/togg.c b/src/lib/commands/togg.c index 531398e7..3bb88ea6 100644 --- a/src/lib/commands/togg.c +++ b/src/lib/commands/togg.c @@ -34,10 +34,6 @@ #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "nat.h" #include "commands.h" int diff --git a/src/lib/commands/torp.c b/src/lib/commands/torp.c index 37bc837b..d81b9e38 100644 --- a/src/lib/commands/torp.c +++ b/src/lib/commands/torp.c @@ -36,19 +36,12 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "file.h" -#include "xy.h" -#include "nat.h" -#include "nsc.h" -#include "news.h" -#include "retreat.h" -#include "damage.h" #include "commands.h" +#include "damage.h" +#include "news.h" #include "optlist.h" +#include "retreat.h" +#include "ship.h" static void anti_torp(int f, int ntorping, int vshipown); static int candchrg(struct shpstr *, struct shpstr *); diff --git a/src/lib/commands/trad.c b/src/lib/commands/trad.c index 75773d06..15c41bb6 100644 --- a/src/lib/commands/trad.c +++ b/src/lib/commands/trad.c @@ -36,23 +36,17 @@ #include #include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "news.h" -#include "ship.h" -#include "nuke.h" -#include "land.h" -#include "plane.h" -#include "trade.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "player.h" -#include "commodity.h" -#include "loan.h" #include "commands.h" +#include "commodity.h" +#include "empobj.h" +#include "land.h" +#include "loan.h" +#include "news.h" +#include "nuke.h" #include "optlist.h" +#include "plane.h" +#include "ship.h" +#include "trade.h" /* * format: trade diff --git a/src/lib/commands/tran.c b/src/lib/commands/tran.c index 601b1f7b..d810c0c5 100644 --- a/src/lib/commands/tran.c +++ b/src/lib/commands/tran.c @@ -34,19 +34,11 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "sect.h" +#include "commands.h" +#include "land.h" #include "nuke.h" -#include "xy.h" -#include "nsc.h" #include "plane.h" #include "ship.h" -#include "file.h" -#include "nat.h" -#include "land.h" -#include "commands.h" static int tran_pmap(coord curx, coord cury, char *arg); static int tran_nmap(coord curx, coord cury, char *arg); diff --git a/src/lib/commands/trea.c b/src/lib/commands/trea.c index 89e4bb2e..8873125d 100644 --- a/src/lib/commands/trea.c +++ b/src/lib/commands/trea.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "treaty.h" -#include "file.h" #include "commands.h" +#include "treaty.h" int trea(void) diff --git a/src/lib/commands/turn.c b/src/lib/commands/turn.c index 7bf53c54..5876cff5 100644 --- a/src/lib/commands/turn.c +++ b/src/lib/commands/turn.c @@ -34,10 +34,9 @@ #include #include -#include -#include -#include "misc.h" -#include "player.h" +#if !defined(_WIN32) +#include +#endif #include "tel.h" #include "commands.h" #include "optlist.h" diff --git a/src/lib/commands/upda.c b/src/lib/commands/upda.c index e18472e6..36f82188 100644 --- a/src/lib/commands/upda.c +++ b/src/lib/commands/upda.c @@ -33,15 +33,10 @@ #include -#include -#include -#include -#include "misc.h" -#include "player.h" #include "commands.h" #include "optlist.h" -#include "wantupd.h" #include "server.h" +#include "wantupd.h" /* * Tell what the update policy is, and when the next update diff --git a/src/lib/commands/upgr.c b/src/lib/commands/upgr.c index 90d7623b..23d67b61 100644 --- a/src/lib/commands/upgr.c +++ b/src/lib/commands/upgr.c @@ -34,17 +34,10 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "ship.h" +#include "commands.h" #include "land.h" #include "plane.h" -#include "sect.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" -#include "commands.h" +#include "ship.h" enum { UPGR_COST = 15, /* how much avail and money to charge */ diff --git a/src/lib/commands/vers.c b/src/lib/commands/vers.c index cc1c72c1..4725c314 100644 --- a/src/lib/commands/vers.c +++ b/src/lib/commands/vers.c @@ -39,15 +39,11 @@ #include -#include -#include -#include "misc.h" -#include "player.h" -#include "version.h" -#include "ship.h" -#include "optlist.h" #include "commands.h" -#include "file.h" +#include "nuke.h" +#include "optlist.h" +#include "ship.h" +#include "version.h" static void show_custom(void); static void show_opts(int val); diff --git a/src/lib/commands/wai.c b/src/lib/commands/wai.c index 442a66c1..9968e676 100644 --- a/src/lib/commands/wai.c +++ b/src/lib/commands/wai.c @@ -33,12 +33,8 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "empio.h" #include "commands.h" +#include "empio.h" int wai(void) diff --git a/src/lib/commands/wing.c b/src/lib/commands/wing.c index ba441913..38a72fed 100644 --- a/src/lib/commands/wing.c +++ b/src/lib/commands/wing.c @@ -34,12 +34,8 @@ #include #include -#include "misc.h" -#include "player.h" -#include "plane.h" -#include "nsc.h" -#include "file.h" #include "commands.h" +#include "plane.h" int wing(void) diff --git a/src/lib/commands/wipe.c b/src/lib/commands/wipe.c index 90e16e43..232a7127 100644 --- a/src/lib/commands/wipe.c +++ b/src/lib/commands/wipe.c @@ -33,13 +33,6 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" #include "commands.h" int diff --git a/src/lib/commands/work.c b/src/lib/commands/work.c index b7174e15..1e11680f 100644 --- a/src/lib/commands/work.c +++ b/src/lib/commands/work.c @@ -33,16 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "land.h" -#include "nat.h" -#include "nsc.h" -#include "file.h" -#include "optlist.h" #include "commands.h" +#include "land.h" +#include "optlist.h" static int buildeff(struct sctstr *, int, double *); diff --git a/src/lib/commands/xdump.c b/src/lib/commands/xdump.c index d7647818..0052323b 100644 --- a/src/lib/commands/xdump.c +++ b/src/lib/commands/xdump.c @@ -74,15 +74,15 @@ #include +#include #include -#include "misc.h" -#include "file.h" +#include "commands.h" +#include "empobj.h" #include "match.h" #include "news.h" -#include "nsc.h" #include "optlist.h" +#include "treaty.h" #include "version.h" -#include "commands.h" /* * Evaluate a attribute of an object into VAL, return VAL. diff --git a/src/lib/commands/zdon.c b/src/lib/commands/zdon.c index cf011564..c97e226c 100644 --- a/src/lib/commands/zdon.c +++ b/src/lib/commands/zdon.c @@ -51,13 +51,8 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "file.h" -#include "empthread.h" #include "commands.h" +#include "empthread.h" #include "optlist.h" #include "server.h" diff --git a/src/lib/common/bestpath.c b/src/lib/common/bestpath.c index 5df5601c..97c8b15f 100644 --- a/src/lib/common/bestpath.c +++ b/src/lib/common/bestpath.c @@ -45,14 +45,14 @@ #include -#include "misc.h" -#include "xy.h" -#include "sect.h" #include "file.h" +#include "misc.h" #include "nat.h" -#include "path.h" -#include "common.h" #include "optlist.h" +#include "path.h" +#include "prototypes.h" +#include "sect.h" +#include "xy.h" static int owned_and_navigable(char *, int, int, int); diff --git a/src/lib/common/bridgefall.c b/src/lib/common/bridgefall.c index e9a4c99e..40eed68d 100644 --- a/src/lib/common/bridgefall.c +++ b/src/lib/common/bridgefall.c @@ -33,19 +33,20 @@ #include -#include "misc.h" -#include "plague.h" -#include "sect.h" -#include "path.h" #include "file.h" -#include "xy.h" -#include "plane.h" #include "land.h" -#include "nsc.h" -#include "common.h" -#include "subs.h" #include "lost.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "nuke.h" #include "optlist.h" +#include "path.h" +#include "plague.h" +#include "plane.h" +#include "prototypes.h" +#include "sect.h" +#include "xy.h" void bridgefall(struct sctstr *sp, struct emp_qelem *list) diff --git a/src/lib/common/check.c b/src/lib/common/check.c index a4195124..99605158 100644 --- a/src/lib/common/check.c +++ b/src/lib/common/check.c @@ -33,21 +33,21 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" +#include "commodity.h" #include "file.h" +#include "land.h" +#include "loan.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "nuke.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" #include "sect.h" #include "ship.h" -#include "plane.h" -#include "nuke.h" -#include "land.h" -#include "nsc.h" -#include "nat.h" -#include "commodity.h" -#include "loan.h" -#include "commands.h" #include "trade.h" +#include "xy.h" /* Note that timestamps make things tricky. And, we don't * really care about the timestamp, we just care about the rest diff --git a/src/lib/common/conftab.c b/src/lib/common/conftab.c index 27693f75..82c6ba7a 100644 --- a/src/lib/common/conftab.c +++ b/src/lib/common/conftab.c @@ -36,10 +36,10 @@ #include #include #include - -#include "prototypes.h" -#include "optlist.h" #include "file.h" +#include "optlist.h" +#include "product.h" +#include "prototypes.h" static int read_custom_table_file(char *); diff --git a/src/lib/common/damage.c b/src/lib/common/damage.c index 2237752d..dd955073 100644 --- a/src/lib/common/damage.c +++ b/src/lib/common/damage.c @@ -34,19 +34,17 @@ #include +#include +#include "damage.h" +#include "land.h" #include "misc.h" +#include "nsc.h" +#include "nuke.h" +#include "optlist.h" +#include "plane.h" +#include "prototypes.h" #include "sect.h" #include "ship.h" -#include "land.h" -#include "plane.h" -#include "nuke.h" -#include "nsc.h" -#include -#include "optlist.h" -#include "damage.h" -#include "common.h" -#include "gen.h" -#include "subs.h" void item_damage(int pct, short *item) diff --git a/src/lib/common/ef_verify.c b/src/lib/common/ef_verify.c index 08a3c7c5..a2ceb28a 100644 --- a/src/lib/common/ef_verify.c +++ b/src/lib/common/ef_verify.c @@ -35,10 +35,11 @@ #include #include - -#include "prototypes.h" +#include #include "file.h" +#include "misc.h" #include "nsc.h" +#include "product.h" static void verify_fail(int, int, struct castr *, int, char *, ...) ATTRIBUTE((format (printf, 5, 6))); diff --git a/src/lib/common/file.c b/src/lib/common/file.c index 4d670461..3ee3f7c5 100644 --- a/src/lib/common/file.c +++ b/src/lib/common/file.c @@ -38,18 +38,16 @@ #include #include #include -#include -#include #if !defined(_WIN32) +#include #include #endif -#include "common.h" #include "file.h" -#include "gen.h" #include "match.h" #include "misc.h" #include "nsc.h" #include "optlist.h" +#include "prototypes.h" static int fillcache(struct empfile *, int); static int do_write(struct empfile *, void *, int, int); diff --git a/src/lib/common/fsize.c b/src/lib/common/fsize.c index 72f56cb8..fa02bb13 100644 --- a/src/lib/common/fsize.c +++ b/src/lib/common/fsize.c @@ -35,15 +35,14 @@ #include -#include "misc.h" -#include "common.h" - #include #include #if !defined(_WIN32) #include #endif +#include "prototypes.h" + /* * return the size of the file in bytes. */ diff --git a/src/lib/common/hap_fact.c b/src/lib/common/hap_fact.c index 112f168b..c5e8a3d6 100644 --- a/src/lib/common/hap_fact.c +++ b/src/lib/common/hap_fact.c @@ -33,14 +33,14 @@ #include -#include #include +#include #include "misc.h" -#include "player.h" -#include "xy.h" #include "nat.h" #include "nsc.h" -#include "common.h" +#include "player.h" +#include "prototypes.h" +#include "xy.h" double hap_fact(struct natstr *tnat, struct natstr *vnat) diff --git a/src/lib/common/hours.c b/src/lib/common/hours.c index d11f5e06..94d73a96 100644 --- a/src/lib/common/hours.c +++ b/src/lib/common/hours.c @@ -36,6 +36,7 @@ #include +#include #include #include #include "misc.h" diff --git a/src/lib/common/journal.c b/src/lib/common/journal.c index 4f8075ba..60a3297c 100644 --- a/src/lib/common/journal.c +++ b/src/lib/common/journal.c @@ -52,7 +52,6 @@ #include #include #include -#include #include #include "misc.h" #include "empthread.h" diff --git a/src/lib/common/land.c b/src/lib/common/land.c index f277b62d..a19b7172 100644 --- a/src/lib/common/land.c +++ b/src/lib/common/land.c @@ -33,16 +33,15 @@ #include -#include "misc.h" -#include "sect.h" -#include "nat.h" #include "file.h" -#include "path.h" -#include "xy.h" #include "land.h" +#include "misc.h" +#include "nat.h" #include "nsc.h" -#include "common.h" -#include "subs.h" +#include "path.h" +#include "prototypes.h" +#include "sect.h" +#include "xy.h" int adj_units(coord x, coord y, natid own) diff --git a/src/lib/common/log.c b/src/lib/common/log.c index 17e2cdf2..621f204a 100644 --- a/src/lib/common/log.c +++ b/src/lib/common/log.c @@ -34,18 +34,16 @@ #include #include "misc.h" -#include #if !defined(_WIN32) #include #endif #include #include #include -#include #include -#include "player.h" -#include "common.h" #include "optlist.h" +#include "player.h" +#include "prototypes.h" /* Debugging? If yes call abort() on internal error. */ int debug = 0; diff --git a/src/lib/common/mailbox.c b/src/lib/common/mailbox.c index 44740fb5..6f8c396e 100644 --- a/src/lib/common/mailbox.c +++ b/src/lib/common/mailbox.c @@ -33,10 +33,9 @@ #include -#include "misc.h" -#include "tel.h" -#include "optlist.h" #include +#include "optlist.h" +#include "tel.h" char * mailbox(char *buf, natid cn) diff --git a/src/lib/common/maps.c b/src/lib/common/maps.c index df8611f8..44eef459 100644 --- a/src/lib/common/maps.c +++ b/src/lib/common/maps.c @@ -34,21 +34,23 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" +#include +#include "com.h" +#include "empobj.h" #include "file.h" -#include "nat.h" -#include "map.h" -#include "ship.h" #include "land.h" -#include "plane.h" -#include "common.h" -#include "gen.h" -#include "subs.h" +#include "map.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "nuke.h" #include "optlist.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" +#include "sect.h" +#include "ship.h" +#include "xy.h" static int bmnxtsct(struct nstr_sect *); static char map_char(unsigned char type, natid own, int owner_or_god); diff --git a/src/lib/common/move.c b/src/lib/common/move.c index 06564b76..01c85442 100644 --- a/src/lib/common/move.c +++ b/src/lib/common/move.c @@ -34,11 +34,10 @@ #include #include "misc.h" -#include "xy.h" -#include "sect.h" -#include "path.h" #include "nat.h" -#include "common.h" +#include "path.h" +#include "sect.h" +#include "xy.h" double sector_mcost(struct sctstr *sp, int mobtype) diff --git a/src/lib/common/nat.c b/src/lib/common/nat.c index 2e1fdcb2..96ca6b0e 100644 --- a/src/lib/common/nat.c +++ b/src/lib/common/nat.c @@ -33,11 +33,10 @@ #include -#include "prototypes.h" +#include "file.h" #include "misc.h" #include "nat.h" -#include "file.h" -#include "optlist.h" +#include "sect.h" char *relates[] = { /* must follow nation relation defines in nat.h */ diff --git a/src/lib/common/path.c b/src/lib/common/path.c index a1062ff9..33720cd3 100644 --- a/src/lib/common/path.c +++ b/src/lib/common/path.c @@ -37,17 +37,15 @@ #include -#include -#include #include "../as/as.h" -#include "misc.h" -#include "path.h" -#include "xy.h" -#include "sect.h" #include "file.h" -#include "common.h" -#include "gen.h" +#include "misc.h" #include "optlist.h" +#include "path.h" +#include "prototypes.h" +#include "sect.h" +#include "xy.h" +#include #define BP_ASHASHSIZE 128 /* A* queue hash table size */ #define BP_NEIGHBORS 6 /* max number of neighbors */ diff --git a/src/lib/common/res_pop.c b/src/lib/common/res_pop.c index bef7ccbe..9e8c0a17 100644 --- a/src/lib/common/res_pop.c +++ b/src/lib/common/res_pop.c @@ -34,13 +34,13 @@ #include -#include "misc.h" -#include "sect.h" -#include "nat.h" #include "item.h" -#include "xy.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" -#include "common.h" +#include "prototypes.h" +#include "sect.h" +#include "xy.h" int max_population(float research, int desig, int eff) diff --git a/src/lib/common/sectdamage.c b/src/lib/common/sectdamage.c index fd1ac2ee..2fac5e56 100644 --- a/src/lib/common/sectdamage.c +++ b/src/lib/common/sectdamage.c @@ -34,21 +34,19 @@ #include +#include "combat.h" +#include "damage.h" +#include "file.h" +#include "land.h" #include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "optlist.h" +#include "plane.h" +#include "prototypes.h" #include "sect.h" #include "ship.h" -#include "land.h" -#include "plane.h" #include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "optlist.h" -#include "damage.h" -#include "common.h" -#include "gen.h" -#include "subs.h" -#include "combat.h" int sect_damage(struct sctstr *sp, int dam, struct emp_qelem *list) diff --git a/src/lib/common/stmtch.c b/src/lib/common/stmtch.c index 0d697a64..93251992 100644 --- a/src/lib/common/stmtch.c +++ b/src/lib/common/stmtch.c @@ -33,7 +33,6 @@ #include -#include "misc.h" #include "match.h" /* diff --git a/src/lib/common/tfact.c b/src/lib/common/tfact.c index cf814030..79e884c2 100644 --- a/src/lib/common/tfact.c +++ b/src/lib/common/tfact.c @@ -33,10 +33,8 @@ #include -#include "misc.h" -#include "nat.h" #include "file.h" -#include "optlist.h" +#include "nat.h" double tfact(natid cn, double mult) diff --git a/src/lib/common/type.c b/src/lib/common/type.c index d4d92964..37e0c1bc 100644 --- a/src/lib/common/type.c +++ b/src/lib/common/type.c @@ -35,17 +35,16 @@ #include -#include -#include -#include "misc.h" -#include "ship.h" -#include "land.h" -#include "plane.h" -#include "sect.h" -#include "nuke.h" #include "file.h" -#include "common.h" +#include "item.h" +#include "land.h" #include "match.h" +#include "nuke.h" +#include "plane.h" +#include "product.h" +#include "prototypes.h" +#include "sect.h" +#include "ship.h" /* * Return index of sector called NAME in dchr[], or M_NOTFOUND. diff --git a/src/lib/common/wantupd.c b/src/lib/common/wantupd.c index 392869df..7ad016ed 100644 --- a/src/lib/common/wantupd.c +++ b/src/lib/common/wantupd.c @@ -33,20 +33,18 @@ #include +#include #include +#include #if !defined(_WIN32) #include #endif +#include "file.h" #include "misc.h" #include "nat.h" -#include "file.h" -#include "wantupd.h" #include "optlist.h" -#include "common.h" - -#include -#include -#include +#include "prototypes.h" +#include "wantupd.h" void update_policy_check(void) diff --git a/src/lib/common/xundump.c b/src/lib/common/xundump.c index 53f4a0f8..544567cd 100644 --- a/src/lib/common/xundump.c +++ b/src/lib/common/xundump.c @@ -48,14 +48,10 @@ #include -#include -#include - #include -#include #include +#include #include - #include "file.h" #include "match.h" #include "nsc.h" diff --git a/src/lib/common/xy.c b/src/lib/common/xy.c index 524b74d4..819f907f 100644 --- a/src/lib/common/xy.c +++ b/src/lib/common/xy.c @@ -37,13 +37,13 @@ #include #include #include -#include "misc.h" -#include "xy.h" -#include "nat.h" -#include "sect.h" #include "file.h" -#include "common.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" +#include "prototypes.h" +#include "sect.h" +#include "xy.h" /* * return pointer to a string containing the x,y diff --git a/src/lib/empthread/lwp.c b/src/lib/empthread/lwp.c index 721c3fc4..9863a425 100644 --- a/src/lib/empthread/lwp.c +++ b/src/lib/empthread/lwp.c @@ -37,6 +37,7 @@ #include #include #include "empthread.h" +#include "misc.h" /* Flags that were passed to empth_init() */ static int empth_flags; diff --git a/src/lib/empthread/ntthread.c b/src/lib/empthread/ntthread.c index 9b2cce43..ce5c7fb1 100644 --- a/src/lib/empthread/ntthread.c +++ b/src/lib/empthread/ntthread.c @@ -46,20 +46,18 @@ #include +#include +#include #include #include -#include -#include #include -#include "misc.h" -#include "empthread.h" -#include "prototypes.h" - #define WIN32 #include #undef NS_ALL #include #include +#include "misc.h" +#include "empthread.h" #define loc_MIN_THREAD_STACK 16384 diff --git a/src/lib/empthread/posix.c b/src/lib/empthread/posix.c index 015080ed..afebb5ec 100644 --- a/src/lib/empthread/posix.c +++ b/src/lib/empthread/posix.c @@ -34,6 +34,7 @@ #include #include +#include #include "empthread.h" #include "prototypes.h" diff --git a/src/lib/empthread/pthread.c b/src/lib/empthread/pthread.c index b43527b5..8460daac 100644 --- a/src/lib/empthread/pthread.c +++ b/src/lib/empthread/pthread.c @@ -38,22 +38,20 @@ #include +#include +#include +#include +#include #include +#include +#include #if !defined(_WIN32) #include #include #endif -#include -#include -#include -#include -#include #include "misc.h" #include "empthread.h" -#include "prototypes.h" - -#include #define EMPTH_KILLED 1 diff --git a/src/lib/gen/chance.c b/src/lib/gen/chance.c index 2f8017f9..801f6e37 100644 --- a/src/lib/gen/chance.c +++ b/src/lib/gen/chance.c @@ -34,7 +34,7 @@ #include #include -#include "gen.h" +#include "prototypes.h" int chance(double d) diff --git a/src/lib/gen/copy.c b/src/lib/gen/copy.c index e2502e4a..dd57af31 100644 --- a/src/lib/gen/copy.c +++ b/src/lib/gen/copy.c @@ -33,11 +33,10 @@ #include -#include "misc.h" -#include "xy.h" #include "map.h" -#include "gen.h" +#include "misc.h" #include "optlist.h" +#include "xy.h" /* * space-fill a map or radar scan; diff --git a/src/lib/gen/emp_config.c b/src/lib/gen/emp_config.c index 01761bfc..22ea872b 100644 --- a/src/lib/gen/emp_config.c +++ b/src/lib/gen/emp_config.c @@ -44,18 +44,20 @@ #include #include +#include #include #include -#include #include #ifdef _WIN32 #include +#else +#include #endif -#include "misc.h" #include "file.h" +#include "misc.h" #include "optlist.h" -#include "gen.h" +#include "prototypes.h" /* Dummy one */ static int emp_config_dummy; diff --git a/src/lib/gen/getstarg.c b/src/lib/gen/getstarg.c index 76275b23..3309c0d9 100644 --- a/src/lib/gen/getstarg.c +++ b/src/lib/gen/getstarg.c @@ -33,8 +33,8 @@ #include +#include #include "misc.h" -#include "gen.h" /* * Get string argument. diff --git a/src/lib/gen/getstring.c b/src/lib/gen/getstring.c index 7015d156..57a8d5eb 100644 --- a/src/lib/gen/getstring.c +++ b/src/lib/gen/getstring.c @@ -33,9 +33,7 @@ #include -#include "misc.h" -#include "gen.h" -#include "subs.h" +#include "prototypes.h" /* * Print sub-prompt PROMPT, receive a line of input into BUF[1024]. diff --git a/src/lib/gen/io.c b/src/lib/gen/io.c index 76fd1025..89e8c048 100644 --- a/src/lib/gen/io.c +++ b/src/lib/gen/io.c @@ -42,28 +42,25 @@ #include #include -#include -#if !defined(_WIN32) -#include -#include -#include /* close read shutdown select */ -#include -#endif -#include #include -#include /* malloc calloc free */ - -#if defined(_WIN32) +#include +#include +#ifdef _WIN32 #define WIN32 #include #undef NS_ALL +#else +#include +#include +#include +#include #endif +#include +#include "empio.h" +#include "ioqueue.h" #include "misc.h" #include "queue.h" -#include "ioqueue.h" -#include "empio.h" -#include "gen.h" /* getfdtablesize */ #include "server.h" #include "empthread.h" diff --git a/src/lib/gen/ioqueue.c b/src/lib/gen/ioqueue.c index b1791d31..5408d68e 100644 --- a/src/lib/gen/ioqueue.c +++ b/src/lib/gen/ioqueue.c @@ -41,13 +41,13 @@ #include #include -#include +#include #if !defined(_WIN32) #include #endif +#include "ioqueue.h" #include "misc.h" #include "queue.h" -#include "ioqueue.h" static int ioqtocbuf(struct ioqueue *ioq, char *buf, int cc, int stopc); #if !defined(_WIN32) diff --git a/src/lib/gen/mapdist.c b/src/lib/gen/mapdist.c index 42da3b66..ee01773b 100644 --- a/src/lib/gen/mapdist.c +++ b/src/lib/gen/mapdist.c @@ -38,8 +38,8 @@ #include #include "misc.h" -#include "gen.h" #include "optlist.h" +#include "prototypes.h" int diffx(int x1, int x2) diff --git a/src/lib/gen/numstr.c b/src/lib/gen/numstr.c index 1f74f1a2..3ac0e988 100644 --- a/src/lib/gen/numstr.c +++ b/src/lib/gen/numstr.c @@ -33,9 +33,7 @@ #include -#include -#include "misc.h" -#include "gen.h" +#include "prototypes.h" char * numstr(char *buf, int n) diff --git a/src/lib/gen/onearg.c b/src/lib/gen/onearg.c index 83ed4157..5aaa79d1 100644 --- a/src/lib/gen/onearg.c +++ b/src/lib/gen/onearg.c @@ -33,8 +33,7 @@ #include -#include "misc.h" -#include "gen.h" +#include "prototypes.h" int onearg(char *arg, char *prompt) diff --git a/src/lib/gen/parse.c b/src/lib/gen/parse.c index 7509df52..409c6f13 100644 --- a/src/lib/gen/parse.c +++ b/src/lib/gen/parse.c @@ -34,8 +34,7 @@ #include #include -#include "misc.h" -#include "gen.h" +#include "prototypes.h" /* * Parse user command in BUF. diff --git a/src/lib/gen/round.c b/src/lib/gen/round.c index 7130ab71..bda84344 100644 --- a/src/lib/gen/round.c +++ b/src/lib/gen/round.c @@ -33,7 +33,7 @@ #include -#include "gen.h" +#include "prototypes.h" int roundintby(int n, int m) diff --git a/src/lib/gen/scthash.c b/src/lib/gen/scthash.c index a509e810..fbaa7b14 100644 --- a/src/lib/gen/scthash.c +++ b/src/lib/gen/scthash.c @@ -33,7 +33,7 @@ #include -#include "gen.h" +#include "prototypes.h" int scthash(int x, int y, int tsize) diff --git a/src/lib/gen/service.c b/src/lib/gen/service.c index 70ab73ba..0c3e9078 100644 --- a/src/lib/gen/service.c +++ b/src/lib/gen/service.c @@ -36,9 +36,9 @@ #ifdef _WIN32 #include +#include "optlist.h" #include "prototypes.h" #include "service.h" -#include "optlist.h" int install_service(char *program_name, char *service_name, char *config_file) diff --git a/src/lib/gen/tcp_listen.c b/src/lib/gen/tcp_listen.c index 2b086035..6b8691ba 100644 --- a/src/lib/gen/tcp_listen.c +++ b/src/lib/gen/tcp_listen.c @@ -36,18 +36,16 @@ #include #include #include -#include -#include #include #ifdef _WIN32 #define WIN32 #include "winsock2.h" #undef NS_ALL #else -#include -#include #include +#include #include +#include #include #endif #include "prototypes.h" diff --git a/src/lib/global/file.c b/src/lib/global/file.c index 6773c42c..51f4883d 100644 --- a/src/lib/global/file.c +++ b/src/lib/global/file.c @@ -34,26 +34,22 @@ #include #include -#include "misc.h" -#include "xy.h" +#include "commodity.h" +#include "file.h" +#include "land.h" #include "loan.h" +#include "lost.h" +#include "nat.h" +#include "news.h" #include "nsc.h" #include "nuke.h" #include "plane.h" -#include "ship.h" -#include "land.h" +#include "power.h" +#include "product.h" #include "sect.h" +#include "ship.h" #include "trade.h" #include "treaty.h" -#include "file.h" -#include "power.h" -#include "news.h" -#include "nat.h" -#include "lost.h" -#include "product.h" - -#include "commodity.h" -#include "nsc.h" /* Number of elements in ARRAY. */ #define SZ(array) (sizeof(array) / sizeof((array)[0])) diff --git a/src/lib/global/init.c b/src/lib/global/init.c index d5bb82c6..1b4c75c0 100644 --- a/src/lib/global/init.c +++ b/src/lib/global/init.c @@ -34,12 +34,13 @@ #include +#include "land.h" #include "misc.h" -#include "ship.h" +#include "optlist.h" #include "plane.h" #include "product.h" -#include "optlist.h" #include "prototypes.h" +#include "ship.h" static void init_mchr(void); static void init_pchr(void); diff --git a/src/lib/global/item.c b/src/lib/global/item.c index 8aa717f0..92719082 100644 --- a/src/lib/global/item.c +++ b/src/lib/global/item.c @@ -33,7 +33,6 @@ #include -#include "misc.h" #include "item.h" /* diff --git a/src/lib/global/land.c b/src/lib/global/land.c index 9bd04bae..4001fa4a 100644 --- a/src/lib/global/land.c +++ b/src/lib/global/land.c @@ -35,7 +35,6 @@ #include -#include "misc.h" #include "land.h" /* diff --git a/src/lib/global/news.c b/src/lib/global/news.c index 1774af60..c6216f9f 100644 --- a/src/lib/global/news.c +++ b/src/lib/global/news.c @@ -41,9 +41,7 @@ #include -#include "misc.h" #include "news.h" -#include "nsc.h" static char no_news[] = "does nothing in particular to %s"; diff --git a/src/lib/global/nsc.c b/src/lib/global/nsc.c index e0bff68a..7b015e1e 100644 --- a/src/lib/global/nsc.c +++ b/src/lib/global/nsc.c @@ -39,12 +39,10 @@ #include #include -#include "misc.h" -#include "xy.h" -#include "nsc.h" #include "empobj.h" -#include "product.h" #include "file.h" +#include "nsc.h" +#include "product.h" #define fldoff(str, fld) offsetof(struct str, fld) diff --git a/src/lib/global/nuke.c b/src/lib/global/nuke.c index f8da09a6..7856da4f 100644 --- a/src/lib/global/nuke.c +++ b/src/lib/global/nuke.c @@ -33,7 +33,6 @@ #include -#include "misc.h" #include "nuke.h" /* diff --git a/src/lib/global/plane.c b/src/lib/global/plane.c index 4c1c2964..b2842b79 100644 --- a/src/lib/global/plane.c +++ b/src/lib/global/plane.c @@ -37,7 +37,6 @@ #include -#include "misc.h" #include "plane.h" /* diff --git a/src/lib/global/product.c b/src/lib/global/product.c index eef142a9..737daef8 100644 --- a/src/lib/global/product.c +++ b/src/lib/global/product.c @@ -33,7 +33,6 @@ #include -#include "misc.h" #include "product.h" /* diff --git a/src/lib/global/sect.c b/src/lib/global/sect.c index 1aae43c3..97097b02 100644 --- a/src/lib/global/sect.c +++ b/src/lib/global/sect.c @@ -37,7 +37,6 @@ #include -#include "misc.h" #include "sect.h" /* diff --git a/src/lib/global/ship.c b/src/lib/global/ship.c index 436e4ed4..f9b8a0e0 100644 --- a/src/lib/global/ship.c +++ b/src/lib/global/ship.c @@ -37,7 +37,6 @@ #include -#include "misc.h" #include "ship.h" /* diff --git a/src/lib/global/symbol.c b/src/lib/global/symbol.c index 5c7ab5d0..9cb42124 100644 --- a/src/lib/global/symbol.c +++ b/src/lib/global/symbol.c @@ -34,11 +34,16 @@ #include #include "land.h" +#include "misc.h" #include "mission.h" +#include "nat.h" #include "news.h" +#include "nsc.h" #include "nuke.h" #include "plague.h" #include "plane.h" +#include "retreat.h" +#include "sect.h" #include "ship.h" #include "treaty.h" diff --git a/src/lib/lwp/lwp.c b/src/lib/lwp/lwp.c index d20a9e61..de10fbc4 100644 --- a/src/lib/lwp/lwp.c +++ b/src/lib/lwp/lwp.c @@ -35,7 +35,6 @@ #include #include -#include #include #include "lwp.h" #include "lwpint.h" diff --git a/src/lib/lwp/lwpint.h b/src/lib/lwp/lwpint.h index 2f1edcd7..e7cb65bc 100644 --- a/src/lib/lwp/lwpint.h +++ b/src/lib/lwp/lwpint.h @@ -35,12 +35,15 @@ #ifndef LWPINT_H #define LWPINT_H +#include #ifdef UCONTEXT #include #else /* !UCONTEXT */ #include #endif /* !UCONTEXT */ +#include "misc.h" + /* process control block. do *not* change the position of context */ struct lwpProc { #ifdef UCONTEXT diff --git a/src/lib/lwp/sel.c b/src/lib/lwp/sel.c index a9cf1c93..62bca68d 100644 --- a/src/lib/lwp/sel.c +++ b/src/lib/lwp/sel.c @@ -34,9 +34,7 @@ #include -#include #include -#include #include #include #include diff --git a/src/lib/lwp/sig.c b/src/lib/lwp/sig.c index 9800a97b..104478e6 100644 --- a/src/lib/lwp/sig.c +++ b/src/lib/lwp/sig.c @@ -35,7 +35,6 @@ #include #include -#include "misc.h" #include "lwp.h" #include "lwpint.h" diff --git a/src/lib/player/accept.c b/src/lib/player/accept.c index 70bc49aa..709a0922 100644 --- a/src/lib/player/accept.c +++ b/src/lib/player/accept.c @@ -34,27 +34,13 @@ #include -#if defined(_WIN32) +#ifdef _WIN32 #define WIN32 #include #undef NS_ALL -#endif - -#include "prototypes.h" -#include "misc.h" -#include "proto.h" -#include "empthread.h" -#include "player.h" -#include "file.h" -#include "empio.h" -#include "power.h" -#include "gen.h" -#include "optlist.h" - -#if !defined(_WIN32) +#else #include #include -#include #include #include #include @@ -63,9 +49,18 @@ #include #include #include -#include #include +#include "empio.h" +#include "empthread.h" +#include "file.h" +#include "misc.h" +#include "optlist.h" +#include "player.h" +#include "power.h" +#include "proto.h" +#include "prototypes.h" + static struct emp_qelem Players; static int player_socket; static size_t player_addrlen; diff --git a/src/lib/player/dispatch.c b/src/lib/player/dispatch.c index 8eb6e6f1..ff6fa117 100644 --- a/src/lib/player/dispatch.c +++ b/src/lib/player/dispatch.c @@ -34,18 +34,16 @@ #include -#include "prototypes.h" -#include "misc.h" -#include "player.h" #include "com.h" -#include "match.h" -#include "nat.h" -#include "file.h" -#include "proto.h" #include "empio.h" +#include "file.h" +#include "match.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" -#include "subs.h" -#include "common.h" +#include "player.h" +#include "proto.h" +#include "prototypes.h" #include "server.h" /* diff --git a/src/lib/player/empdis.c b/src/lib/player/empdis.c index e286a7e3..cf2204eb 100644 --- a/src/lib/player/empdis.c +++ b/src/lib/player/empdis.c @@ -35,20 +35,18 @@ #include -#include "prototypes.h" #include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "tel.h" -#include "proto.h" #include "com.h" -#include "file.h" #include "empio.h" +#include "file.h" #include "match.h" -#include "subs.h" -#include "common.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" +#include "player.h" +#include "proto.h" +#include "prototypes.h" +#include "tel.h" #include #include diff --git a/src/lib/player/empmod.c b/src/lib/player/empmod.c index d9ff0e12..aeadf9f2 100644 --- a/src/lib/player/empmod.c +++ b/src/lib/player/empmod.c @@ -38,6 +38,7 @@ #include #include "com.h" +#include "nat.h" #include "prototypes.h" struct cmndstr player_coms[] = { diff --git a/src/lib/player/init_nats.c b/src/lib/player/init_nats.c index adfd0978..102177b0 100644 --- a/src/lib/player/init_nats.c +++ b/src/lib/player/init_nats.c @@ -34,15 +34,13 @@ #include -#include "prototypes.h" -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" #include "file.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" -#include "common.h" -#include "gen.h" +#include "player.h" +#include "prototypes.h" +#include "sect.h" static int nat_cap(int); diff --git a/src/lib/player/login.c b/src/lib/player/login.c index 411fffab..ade42551 100644 --- a/src/lib/player/login.c +++ b/src/lib/player/login.c @@ -35,27 +35,18 @@ #include -#include -#include "prototypes.h" -#include "misc.h" -#include "proto.h" -#include "player.h" #include "com.h" -#include "empthread.h" #include "empio.h" -#include "match.h" -#include "nsc.h" -#include "nat.h" -#include "optlist.h" +#include "empthread.h" #include "file.h" -#include "subs.h" -#include "common.h" -#include "gen.h" - -#if !defined(_WIN32) -#include -#endif -#include +#include "match.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "optlist.h" +#include "player.h" +#include "proto.h" +#include "prototypes.h" static int client_cmd(void); static int coun_cmd(void); diff --git a/src/lib/player/nat.c b/src/lib/player/nat.c index dd5aa5db..67819d94 100644 --- a/src/lib/player/nat.c +++ b/src/lib/player/nat.c @@ -33,12 +33,9 @@ #include -#include "prototypes.h" -#include "misc.h" -#include "nat.h" #include "file.h" -#include "player.h" -#include +#include "nat.h" +#include "prototypes.h" int natbyname(char *name, natid *result) diff --git a/src/lib/player/player.c b/src/lib/player/player.c index b3d4310a..95af6d43 100644 --- a/src/lib/player/player.c +++ b/src/lib/player/player.c @@ -33,28 +33,23 @@ #include -#include "prototypes.h" -#include -#include "misc.h" -#include "player.h" -#include "proto.h" #include "com.h" -#include "nat.h" -#include "sect.h" -#include "file.h" -#include "proto.h" #include "empio.h" #include "empthread.h" -#include "tel.h" -#include "gen.h" -#include "subs.h" -#include "common.h" -#include "optlist.h" +#include "file.h" #include "journal.h" +#include "misc.h" +#include "nat.h" +#include "optlist.h" +#include "player.h" +#include "proto.h" +#include "proto.h" +#include "prototypes.h" +#include "sect.h" +#include "tel.h" #if !defined(_WIN32) #include -#include #endif #include #include diff --git a/src/lib/player/recvclient.c b/src/lib/player/recvclient.c index a6c1d154..f356593d 100644 --- a/src/lib/player/recvclient.c +++ b/src/lib/player/recvclient.c @@ -33,13 +33,10 @@ #include -#include "prototypes.h" -#include -#include "misc.h" #include "empio.h" #include "journal.h" #include "player.h" -#include "empthread.h" +#include "prototypes.h" /* * Receive a line of input from the current player. diff --git a/src/lib/subs/aircombat.c b/src/lib/subs/aircombat.c index 520cf95b..842d8af9 100644 --- a/src/lib/subs/aircombat.c +++ b/src/lib/subs/aircombat.c @@ -36,23 +36,22 @@ #include -#include - -#include "misc.h" -#include "player.h" -#include "news.h" -#include "land.h" -#include "sect.h" -#include "plane.h" -#include "ship.h" -#include "nat.h" #include "file.h" -#include "xy.h" +#include "land.h" +#include "map.h" +#include "misc.h" +#include "nat.h" +#include "news.h" #include "nsc.h" -#include "path.h" -#include "prototypes.h" #include "optlist.h" +#include "path.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" +#include "sect.h" #include "server.h" +#include "ship.h" +#include "xy.h" #define FLAK_GUN_MAX 14 diff --git a/src/lib/subs/askyn.c b/src/lib/subs/askyn.c index ae5dff73..8cfbec77 100644 --- a/src/lib/subs/askyn.c +++ b/src/lib/subs/askyn.c @@ -34,8 +34,6 @@ #include -#include "misc.h" -#include #include "prototypes.h" /* diff --git a/src/lib/subs/aswplnsubs.c b/src/lib/subs/aswplnsubs.c index 4a5288f4..9a759a1e 100644 --- a/src/lib/subs/aswplnsubs.c +++ b/src/lib/subs/aswplnsubs.c @@ -33,12 +33,12 @@ #include -#include -#include "misc.h" #include "file.h" -#include "ship.h" +#include "misc.h" +#include "nat.h" #include "plane.h" #include "prototypes.h" +#include "ship.h" int on_shiplist(short uid, struct shiplist *head) diff --git a/src/lib/subs/attsub.c b/src/lib/subs/attsub.c index 8b823339..ed6f0b59 100644 --- a/src/lib/subs/attsub.c +++ b/src/lib/subs/attsub.c @@ -35,25 +35,28 @@ #include +#include #include -#include "misc.h" -#include "player.h" +#include "combat.h" #include "file.h" +#include "item.h" +#include "land.h" +#include "lost.h" +#include "map.h" +#include "misc.h" +#include "mission.h" +#include "nat.h" +#include "news.h" +#include "nsc.h" +#include "optlist.h" +#include "path.h" #include "plague.h" +#include "player.h" +#include "prototypes.h" #include "sect.h" #include "ship.h" -#include "path.h" -#include "news.h" #include "treaty.h" -#include "nat.h" #include "xy.h" -#include "land.h" -#include "nsc.h" -#include "mission.h" -#include "combat.h" -#include "item.h" -#include "optlist.h" -#include "prototypes.h" #define CASUALTY_LUMP 1 /* How big casualty chunks should be */ diff --git a/src/lib/subs/bigmap.c b/src/lib/subs/bigmap.c index f972b3fe..1723ca0e 100644 --- a/src/lib/subs/bigmap.c +++ b/src/lib/subs/bigmap.c @@ -34,10 +34,9 @@ #include -#include "misc.h" -#include "player.h" #include "file.h" -#include "prototypes.h" +#include "map.h" +#include "sect.h" /* values of only_bmap: * 0 = update both maps diff --git a/src/lib/subs/border.c b/src/lib/subs/border.c index 62f62f6e..9bce2323 100644 --- a/src/lib/subs/border.c +++ b/src/lib/subs/border.c @@ -33,10 +33,10 @@ #include -#include "misc.h" -#include "xy.h" -#include "prototypes.h" +#include "map.h" #include "optlist.h" +#include "prototypes.h" +#include "xy.h" void border(struct range *rp, char *prefstr, char *sep) diff --git a/src/lib/subs/bsanct.c b/src/lib/subs/bsanct.c index 3d2fd1de..18bd3720 100644 --- a/src/lib/subs/bsanct.c +++ b/src/lib/subs/bsanct.c @@ -33,16 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" -#include "nat.h" -#include "news.h" -#include "path.h" #include "file.h" +#include "news.h" +#include "player.h" #include "prototypes.h" +#include "sect.h" void bsanct(void) diff --git a/src/lib/subs/caploss.c b/src/lib/subs/caploss.c index 69259e19..66cf7e6f 100644 --- a/src/lib/subs/caploss.c +++ b/src/lib/subs/caploss.c @@ -33,13 +33,15 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" +#include "commodity.h" #include "file.h" +#include "loan.h" +#include "nat.h" #include "news.h" -#include "prototypes.h" #include "optlist.h" +#include "player.h" +#include "prototypes.h" +#include "sect.h" void caploss(struct sctstr *sp, natid coun, char *msg) diff --git a/src/lib/subs/chkmoney.c b/src/lib/subs/chkmoney.c index 15771b82..5a910237 100644 --- a/src/lib/subs/chkmoney.c +++ b/src/lib/subs/chkmoney.c @@ -33,7 +33,6 @@ #include -#include "misc.h" #include "player.h" #include "prototypes.h" diff --git a/src/lib/subs/cnumb.c b/src/lib/subs/cnumb.c index d934d885..b6434fd7 100644 --- a/src/lib/subs/cnumb.c +++ b/src/lib/subs/cnumb.c @@ -33,11 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "nat.h" #include "file.h" #include "match.h" +#include "nat.h" #include "prototypes.h" /* diff --git a/src/lib/subs/coastal.c b/src/lib/subs/coastal.c index 7d1bce4d..721ef953 100644 --- a/src/lib/subs/coastal.c +++ b/src/lib/subs/coastal.c @@ -33,9 +33,10 @@ #include -#include "prototypes.h" #include "file.h" #include "path.h" +#include "prototypes.h" +#include "sect.h" static void update_coastal_flag(struct sctstr *sp, struct sctstr *sectp) diff --git a/src/lib/subs/control.c b/src/lib/subs/control.c index 41d13932..58c41c81 100644 --- a/src/lib/subs/control.c +++ b/src/lib/subs/control.c @@ -33,17 +33,10 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" #include "file.h" -#include "path.h" -#include "xy.h" #include "land.h" -#include "nsc.h" -#include "item.h" #include "prototypes.h" +#include "sect.h" /* * Does the player->owner have military control of this sector? diff --git a/src/lib/subs/detonate.c b/src/lib/subs/detonate.c index 0290bd75..b7a5308b 100644 --- a/src/lib/subs/detonate.c +++ b/src/lib/subs/detonate.c @@ -33,20 +33,21 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nat.h" #include "file.h" -#include "sect.h" -#include "nuke.h" -#include "ship.h" #include "land.h" +#include "lost.h" +#include "misc.h" +#include "nat.h" #include "news.h" -#include "plane.h" #include "nsc.h" +#include "nuke.h" #include "optlist.h" +#include "plane.h" +#include "player.h" #include "prototypes.h" +#include "sect.h" +#include "ship.h" +#include "xy.h" static void kaboom(int x, int y, int rad, natid cn); diff --git a/src/lib/subs/disloan.c b/src/lib/subs/disloan.c index 6d7e9962..7d87157c 100644 --- a/src/lib/subs/disloan.c +++ b/src/lib/subs/disloan.c @@ -46,11 +46,10 @@ #include -#include "misc.h" -#include "player.h" +#include "file.h" #include "loan.h" #include "nat.h" -#include "file.h" +#include "player.h" #include "prototypes.h" int diff --git a/src/lib/subs/distrea.c b/src/lib/subs/distrea.c index d0e6e2d4..5dcd9f45 100644 --- a/src/lib/subs/distrea.c +++ b/src/lib/subs/distrea.c @@ -33,12 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "treaty.h" -#include "nat.h" #include "file.h" +#include "nat.h" +#include "player.h" #include "prototypes.h" +#include "treaty.h" int distrea(int n, struct trtstr *tp) diff --git a/src/lib/subs/fortdef.c b/src/lib/subs/fortdef.c index 0ecb2102..4b77e239 100644 --- a/src/lib/subs/fortdef.c +++ b/src/lib/subs/fortdef.c @@ -39,17 +39,13 @@ #include -#include "misc.h" -#include "xy.h" -#include "nat.h" -#include "sect.h" -#include "ship.h" -#include "land.h" -#include "news.h" -#include "nsc.h" #include "file.h" +#include "nat.h" +#include "news.h" #include "optlist.h" #include "prototypes.h" +#include "sect.h" +#include "ship.h" #define NOISY 1 diff --git a/src/lib/subs/getbit.c b/src/lib/subs/getbit.c index a66fab1f..fdff4b2b 100644 --- a/src/lib/subs/getbit.c +++ b/src/lib/subs/getbit.c @@ -33,16 +33,9 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "sect.h" -#include "nat.h" -#include "prototypes.h" #include "optlist.h" - - +#include "prototypes.h" +#include "sect.h" /* * diff --git a/src/lib/subs/getele.c b/src/lib/subs/getele.c index 483dc685..009e354d 100644 --- a/src/lib/subs/getele.c +++ b/src/lib/subs/getele.c @@ -33,11 +33,9 @@ #include -#include -#include "misc.h" #include "player.h" -#include "tel.h" #include "prototypes.h" +#include "tel.h" static int tilde_escape(char *s); diff --git a/src/lib/subs/land.c b/src/lib/subs/land.c index 688a1905..209bd7f6 100644 --- a/src/lib/subs/land.c +++ b/src/lib/subs/land.c @@ -33,15 +33,16 @@ #include -#include "misc.h" -#include "player.h" #include "file.h" #include "land.h" -#include "ship.h" +#include "lost.h" +#include "misc.h" #include "nsc.h" -#include "plane.h" -#include "prototypes.h" #include "optlist.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" +#include "ship.h" int lnd_postread(int n, void *ptr) diff --git a/src/lib/subs/landgun.c b/src/lib/subs/landgun.c index 745180e8..a350adc3 100644 --- a/src/lib/subs/landgun.c +++ b/src/lib/subs/landgun.c @@ -33,11 +33,12 @@ #include -#include "misc.h" #include "file.h" #include "nat.h" #include "optlist.h" #include "prototypes.h" +#include "sect.h" +#include "ship.h" double landgun(int effic, int guns) diff --git a/src/lib/subs/list.c b/src/lib/subs/list.c index 016152c8..8d13262e 100644 --- a/src/lib/subs/list.c +++ b/src/lib/subs/list.c @@ -33,16 +33,17 @@ #include -#include "misc.h" -#include "player.h" -#include "ship.h" -#include "land.h" -#include "plane.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" +#include #include "file.h" +#include "land.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "plane.h" +#include "player.h" #include "prototypes.h" +#include "ship.h" +#include "xy.h" int shipsatxy(coord x, coord y, int wantflags, int nowantflags) diff --git a/src/lib/subs/lndsub.c b/src/lib/subs/lndsub.c index 6eaabbd7..35248564 100644 --- a/src/lib/subs/lndsub.c +++ b/src/lib/subs/lndsub.c @@ -36,23 +36,24 @@ #include #include -#include "misc.h" -#include "player.h" -#include "file.h" -#include "sect.h" -#include "path.h" -#include "news.h" -#include "nat.h" -#include "xy.h" -#include "land.h" -#include "ship.h" -#include "nsc.h" -#include "mission.h" -#include "plane.h" +#include #include "combat.h" #include "damage.h" +#include "file.h" +#include "land.h" +#include "misc.h" +#include "mission.h" +#include "nat.h" +#include "news.h" +#include "nsc.h" #include "optlist.h" +#include "path.h" +#include "plane.h" +#include "player.h" #include "prototypes.h" +#include "sect.h" +#include "ship.h" +#include "xy.h" static void lnd_mess(char *, struct llist *); static int lnd_hit_mine(struct lndstr *, struct lchrstr *); diff --git a/src/lib/subs/lostsub.c b/src/lib/subs/lostsub.c index a2750d88..d805764e 100644 --- a/src/lib/subs/lostsub.c +++ b/src/lib/subs/lostsub.c @@ -33,14 +33,8 @@ #include -#include "misc.h" -#include "player.h" #include "file.h" -#include "land.h" -#include "ship.h" -#include "nsc.h" #include "lost.h" -#include "prototypes.h" static int findlost(char, natid, short, coord, coord, int); diff --git a/src/lib/subs/mission.c b/src/lib/subs/mission.c index 039a26ee..7f8b1e06 100644 --- a/src/lib/subs/mission.c +++ b/src/lib/subs/mission.c @@ -34,20 +34,20 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "path.h" -#include "mission.h" -#include "item.h" -#include +#include #include "damage.h" -#include "queue.h" -#include "prototypes.h" -#include "optlist.h" #include "empobj.h" +#include "file.h" +#include "item.h" +#include "misc.h" +#include "mission.h" +#include "nsc.h" +#include "optlist.h" +#include "path.h" +#include "player.h" +#include "prototypes.h" +#include "queue.h" +#include "xy.h" struct genlist { struct emp_qelem queue; /* list of units */ diff --git a/src/lib/subs/move.c b/src/lib/subs/move.c index 36245b35..190234b4 100644 --- a/src/lib/subs/move.c +++ b/src/lib/subs/move.c @@ -33,18 +33,14 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "item.h" -#include "file.h" -#include "xy.h" -#include "path.h" -#include "nat.h" -#include "map.h" -#include "nsc.h" +#include #include "damage.h" +#include "file.h" +#include "map.h" +#include "path.h" +#include "player.h" #include "prototypes.h" +#include "sect.h" static int move_map(coord curx, coord cury, char *arg); diff --git a/src/lib/subs/mslsub.c b/src/lib/subs/mslsub.c index 4b9d3af0..81e2107a 100644 --- a/src/lib/subs/mslsub.c +++ b/src/lib/subs/mslsub.c @@ -34,22 +34,23 @@ #include +#include +#include "file.h" +#include "land.h" #include "misc.h" -#include "queue.h" +#include "mission.h" +#include "nat.h" +#include "news.h" +#include "nsc.h" +#include "optlist.h" +#include "path.h" +#include "plane.h" #include "player.h" +#include "prototypes.h" +#include "queue.h" #include "sect.h" #include "ship.h" -#include "optlist.h" -#include "plane.h" -#include "land.h" -#include "news.h" #include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "path.h" -#include "mission.h" -#include "prototypes.h" int msl_equip(struct plnstr *pp) diff --git a/src/lib/subs/mtch.c b/src/lib/subs/mtch.c index a02d5a37..e29d6fcc 100644 --- a/src/lib/subs/mtch.c +++ b/src/lib/subs/mtch.c @@ -33,8 +33,6 @@ #include -#include "misc.h" -#include "player.h" #include "com.h" #include "match.h" #include "prototypes.h" diff --git a/src/lib/subs/natarg.c b/src/lib/subs/natarg.c index 099fd4e1..a19f996c 100644 --- a/src/lib/subs/natarg.c +++ b/src/lib/subs/natarg.c @@ -34,13 +34,14 @@ #include #include -#include "misc.h" -#include "nat.h" -#include "player.h" +#include #include "file.h" #include "match.h" -#include "prototypes.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" +#include "player.h" +#include "prototypes.h" /* * Get nation argument. diff --git a/src/lib/subs/neigh.c b/src/lib/subs/neigh.c index fec473b8..ee88f908 100644 --- a/src/lib/subs/neigh.c +++ b/src/lib/subs/neigh.c @@ -33,12 +33,10 @@ #include -#include "misc.h" -#include "sect.h" -#include "path.h" #include "file.h" -#include "nat.h" +#include "path.h" #include "prototypes.h" +#include "sect.h" int neigh(coord x, coord y, natid own) diff --git a/src/lib/subs/nreport.c b/src/lib/subs/nreport.c index 8ab80f43..f4f997b6 100644 --- a/src/lib/subs/nreport.c +++ b/src/lib/subs/nreport.c @@ -35,10 +35,11 @@ #include -#include "prototypes.h" -#include "news.h" #include "file.h" +#include "nat.h" +#include "news.h" #include "optlist.h" +#include "prototypes.h" #define SLOTS 5 diff --git a/src/lib/subs/nstr.c b/src/lib/subs/nstr.c index 21d1a5f2..734531b8 100644 --- a/src/lib/subs/nstr.c +++ b/src/lib/subs/nstr.c @@ -35,12 +35,13 @@ #include +#include #include -#include "misc.h" #include "file.h" #include "match.h" -#include "nsc.h" +#include "nat.h" #include "optlist.h" +#include "player.h" #include "prototypes.h" static char *nstr_parse_val(char *, struct valstr *); diff --git a/src/lib/subs/nuke.c b/src/lib/subs/nuke.c index 0d08cbf4..2363d111 100644 --- a/src/lib/subs/nuke.c +++ b/src/lib/subs/nuke.c @@ -35,15 +35,17 @@ #include +#include "file.h" +#include "lost.h" #include "misc.h" -#include "player.h" +#include "nat.h" +#include "nsc.h" #include "nuke.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" #include "sect.h" #include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "prototypes.h" int nuk_postread(int n, void *ptr) diff --git a/src/lib/subs/nxtitem.c b/src/lib/subs/nxtitem.c index 0e0517cf..c6884ca6 100644 --- a/src/lib/subs/nxtitem.c +++ b/src/lib/subs/nxtitem.c @@ -33,14 +33,15 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "ship.h" -#include "land.h" -#include "nsc.h" +#include "empobj.h" #include "file.h" +#include "land.h" +#include "misc.h" +#include "nsc.h" +#include "player.h" #include "prototypes.h" +#include "ship.h" +#include "xy.h" int nxtitem(struct nstr_item *np, void *ptr) diff --git a/src/lib/subs/nxtsct.c b/src/lib/subs/nxtsct.c index 7a9c2925..34289df2 100644 --- a/src/lib/subs/nxtsct.c +++ b/src/lib/subs/nxtsct.c @@ -33,13 +33,10 @@ #include -#include "misc.h" -#include "xy.h" -#include "sect.h" -#include "nsc.h" #include "file.h" -#include "prototypes.h" #include "optlist.h" +#include "prototypes.h" +#include "sect.h" /* * get the next sector in the range diff --git a/src/lib/subs/paths.c b/src/lib/subs/paths.c index e94cadc8..a14e835e 100644 --- a/src/lib/subs/paths.c +++ b/src/lib/subs/paths.c @@ -33,14 +33,11 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "path.h" -#include "nat.h" -#include "sect.h" #include "file.h" +#include "path.h" +#include "player.h" #include "prototypes.h" +#include "sect.h" int chkdir(char dir_char, int min_dir, int max_dir) diff --git a/src/lib/subs/plane.c b/src/lib/subs/plane.c index 5d44fa9a..a3e52a09 100644 --- a/src/lib/subs/plane.c +++ b/src/lib/subs/plane.c @@ -34,14 +34,16 @@ #include -#include "misc.h" -#include "player.h" -#include "plane.h" -#include "ship.h" -#include "land.h" #include "file.h" -#include "prototypes.h" +#include "land.h" +#include "lost.h" +#include "misc.h" +#include "nuke.h" #include "optlist.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" +#include "ship.h" int pln_postread(int n, void *ptr) diff --git a/src/lib/subs/plnsub.c b/src/lib/subs/plnsub.c index 9830db81..e1720da8 100644 --- a/src/lib/subs/plnsub.c +++ b/src/lib/subs/plnsub.c @@ -37,20 +37,23 @@ #include #include +#include "file.h" +#include "item.h" +#include "land.h" +#include "lost.h" +#include "map.h" #include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "nuke.h" +#include "optlist.h" +#include "path.h" +#include "plane.h" #include "player.h" +#include "prototypes.h" #include "sect.h" #include "ship.h" -#include "land.h" -#include "item.h" -#include "plane.h" #include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "path.h" -#include "prototypes.h" -#include "optlist.h" static int pln_equip(struct plist *, struct ichrstr *, int, char); diff --git a/src/lib/subs/pr.c b/src/lib/subs/pr.c index b2b04395..b4ba4121 100644 --- a/src/lib/subs/pr.c +++ b/src/lib/subs/pr.c @@ -51,20 +51,20 @@ #include -#include #include #include #include -#include "proto.h" -#include "misc.h" -#include "player.h" -#include "nat.h" +#include +#include "com.h" #include "empio.h" #include "file.h" -#include "com.h" -#include "tel.h" -#include "server.h" +#include "misc.h" +#include "nat.h" +#include "player.h" +#include "proto.h" #include "prototypes.h" +#include "server.h" +#include "tel.h" static void pr_player(struct player *pl, int id, char *buf); static void upr_player(struct player *pl, int id, char *buf); diff --git a/src/lib/subs/radmap.c b/src/lib/subs/radmap.c index 516c2386..d5118fe8 100644 --- a/src/lib/subs/radmap.c +++ b/src/lib/subs/radmap.c @@ -33,17 +33,19 @@ #include +#include +#include "file.h" +#include "map.h" #include "misc.h" -#include "player.h" -#include "xy.h" #include "nat.h" +#include "nsc.h" +#include "optlist.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" #include "sect.h" #include "ship.h" -#include "plane.h" -#include "file.h" -#include "nsc.h" -#include "prototypes.h" -#include "optlist.h" +#include "xy.h" static void radmap2(int, int, int, int, int, double, int); diff --git a/src/lib/subs/rej.c b/src/lib/subs/rej.c index 66f91ed1..566e1bd6 100644 --- a/src/lib/subs/rej.c +++ b/src/lib/subs/rej.c @@ -33,13 +33,12 @@ #include -#include "misc.h" -#include "nat.h" #include "file.h" +#include "nat.h" #include "news.h" +#include "optlist.h" #include "player.h" #include "prototypes.h" -#include "optlist.h" #include "server.h" int diff --git a/src/lib/subs/retreat.c b/src/lib/subs/retreat.c index 940afba2..f657f4bd 100644 --- a/src/lib/subs/retreat.c +++ b/src/lib/subs/retreat.c @@ -33,22 +33,23 @@ #include -#include -#include "misc.h" -#include "player.h" -#include "nat.h" -#include "retreat.h" -#include "ship.h" -#include "land.h" -#include "sect.h" -#include "news.h" -#include "xy.h" -#include "nsc.h" -#include "path.h" -#include "file.h" +#include #include "damage.h" -#include "prototypes.h" +#include "file.h" +#include "land.h" +#include "map.h" +#include "misc.h" +#include "nat.h" +#include "news.h" +#include "nsc.h" #include "optlist.h" +#include "path.h" +#include "player.h" +#include "prototypes.h" +#include "retreat.h" +#include "sect.h" +#include "ship.h" +#include "xy.h" static int findcondition(char); static int retreat_land1(struct lndstr *, char, int); diff --git a/src/lib/subs/sarg.c b/src/lib/subs/sarg.c index e42c604d..9ccf7b04 100644 --- a/src/lib/subs/sarg.c +++ b/src/lib/subs/sarg.c @@ -35,15 +35,15 @@ #include #include -#include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" +#include #include "file.h" -#include "prototypes.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" #include "optlist.h" +#include "player.h" +#include "prototypes.h" +#include "xy.h" /* * returns one of diff --git a/src/lib/subs/satmap.c b/src/lib/subs/satmap.c index b1167692..1f45c7e0 100644 --- a/src/lib/subs/satmap.c +++ b/src/lib/subs/satmap.c @@ -33,18 +33,20 @@ #include +#include +#include "file.h" +#include "land.h" +#include "map.h" #include "misc.h" +#include "nat.h" +#include "nsc.h" +#include "optlist.h" +#include "plane.h" #include "player.h" -#include "xy.h" +#include "prototypes.h" #include "sect.h" #include "ship.h" -#include "land.h" -#include "plane.h" -#include "nsc.h" -#include "nat.h" -#include "file.h" -#include "prototypes.h" -#include "optlist.h" +#include "xy.h" static char **rad; static char *radbuf; diff --git a/src/lib/subs/sect.c b/src/lib/subs/sect.c index ffc235a5..72ce7e79 100644 --- a/src/lib/subs/sect.c +++ b/src/lib/subs/sect.c @@ -34,17 +34,19 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "xy.h" -#include "nat.h" +#include #include "file.h" #include "land.h" +#include "lost.h" +#include "misc.h" +#include "nat.h" #include "nsc.h" -#include "plane.h" -#include "prototypes.h" #include "optlist.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" +#include "sect.h" +#include "xy.h" static int checksect(struct sctstr *); diff --git a/src/lib/subs/ship.c b/src/lib/subs/ship.c index 4acf860f..5b0b0458 100644 --- a/src/lib/subs/ship.c +++ b/src/lib/subs/ship.c @@ -34,15 +34,16 @@ #include -#include "misc.h" -#include "player.h" #include "file.h" -#include "ship.h" #include "land.h" -#include "plane.h" +#include "lost.h" +#include "misc.h" #include "nsc.h" -#include "prototypes.h" #include "optlist.h" +#include "plane.h" +#include "player.h" +#include "prototypes.h" +#include "ship.h" int shp_postread(int n, void *ptr) diff --git a/src/lib/subs/show.c b/src/lib/subs/show.c index 09a76fd8..1fab3053 100644 --- a/src/lib/subs/show.c +++ b/src/lib/subs/show.c @@ -38,20 +38,19 @@ #include #include -#include "misc.h" -#include "player.h" -#include "nuke.h" -#include "ship.h" -#include "land.h" -#include "item.h" -#include "plane.h" -#include "sect.h" -#include "optlist.h" #include "file.h" +#include "item.h" +#include "land.h" #include "nat.h" -#include "prototypes.h" -#include "nsc.h" #include "news.h" +#include "nuke.h" +#include "optlist.h" +#include "plane.h" +#include "player.h" +#include "product.h" +#include "prototypes.h" +#include "sect.h" +#include "ship.h" struct look_list { union { diff --git a/src/lib/subs/shpsub.c b/src/lib/subs/shpsub.c index 4cfce330..bf5f8783 100644 --- a/src/lib/subs/shpsub.c +++ b/src/lib/subs/shpsub.c @@ -36,25 +36,27 @@ #include #include -#include "misc.h" -#include "queue.h" -#include "player.h" -#include "sect.h" -#include "ship.h" -#include "plane.h" -#include "land.h" -#include "news.h" -#include "item.h" -#include "xy.h" -#include "nsc.h" -#include "file.h" -#include "nat.h" -#include "path.h" -#include "mission.h" -#include "optlist.h" +#include #include "damage.h" -#include "server.h" +#include "file.h" +#include "item.h" +#include "land.h" +#include "map.h" +#include "misc.h" +#include "mission.h" +#include "nat.h" +#include "news.h" +#include "nsc.h" +#include "optlist.h" +#include "path.h" +#include "plane.h" +#include "player.h" #include "prototypes.h" +#include "queue.h" +#include "sect.h" +#include "server.h" +#include "ship.h" +#include "xy.h" static int shp_check_one_mines(struct mlist *); static int shp_hit_mine(struct shpstr *, struct mchrstr *); diff --git a/src/lib/subs/snxtitem.c b/src/lib/subs/snxtitem.c index 4b8e5a8d..709f9778 100644 --- a/src/lib/subs/snxtitem.c +++ b/src/lib/subs/snxtitem.c @@ -33,6 +33,7 @@ #include +#include #include "misc.h" #include "player.h" #include "xy.h" diff --git a/src/lib/subs/snxtsct.c b/src/lib/subs/snxtsct.c index 75dbedb1..83781c7f 100644 --- a/src/lib/subs/snxtsct.c +++ b/src/lib/subs/snxtsct.c @@ -33,13 +33,14 @@ #include -#include "misc.h" -#include "player.h" -#include "xy.h" -#include "nsc.h" #include "file.h" -#include "prototypes.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" #include "optlist.h" +#include "player.h" +#include "prototypes.h" +#include "xy.h" /* * setup the nstr_sect structure for sector selection. diff --git a/src/lib/subs/supply.c b/src/lib/subs/supply.c index 6384cc92..74caa77c 100644 --- a/src/lib/subs/supply.c +++ b/src/lib/subs/supply.c @@ -34,19 +34,14 @@ #include #include -#include "misc.h" -#include "nat.h" -#include "ship.h" -#include "land.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "path.h" -#include "item.h" #include "file.h" +#include "land.h" +#include "nat.h" #include "optlist.h" #include "player.h" #include "prototypes.h" +#include "sect.h" +#include "ship.h" static int get_minimum(struct lndstr *, i_type); static int s_commod(int, int, int, i_type, int, int); diff --git a/src/lib/subs/takeover.c b/src/lib/subs/takeover.c index aed1ccec..6b084e69 100644 --- a/src/lib/subs/takeover.c +++ b/src/lib/subs/takeover.c @@ -34,17 +34,19 @@ #include -#include "misc.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "plane.h" -#include "land.h" -#include "ship.h" +#include #include "file.h" -#include "prototypes.h" +#include "land.h" +#include "lost.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" #include "optlist.h" +#include "plane.h" +#include "prototypes.h" +#include "sect.h" +#include "ship.h" +#include "xy.h" void takeover(struct sctstr *sp, natid newown) diff --git a/src/lib/subs/trdsub.c b/src/lib/subs/trdsub.c index 96aa2d90..b9851d99 100644 --- a/src/lib/subs/trdsub.c +++ b/src/lib/subs/trdsub.c @@ -35,22 +35,23 @@ #include -#include "misc.h" -#include "player.h" -#include "sect.h" -#include "nat.h" +#include "empobj.h" +#include "file.h" #include "item.h" -#include "ship.h" #include "land.h" +#include "loan.h" +#include "misc.h" +#include "nat.h" +#include "nsc.h" #include "nuke.h" +#include "optlist.h" #include "plane.h" +#include "player.h" +#include "prototypes.h" +#include "sect.h" +#include "ship.h" #include "trade.h" #include "xy.h" -#include "nsc.h" -#include "file.h" -#include "loan.h" -#include "prototypes.h" -#include "optlist.h" int trade_check_ok(struct trdstr *tp, union empobj_storage *tgp) diff --git a/src/lib/subs/trechk.c b/src/lib/subs/trechk.c index 6ab78d5e..aaf6e2b6 100644 --- a/src/lib/subs/trechk.c +++ b/src/lib/subs/trechk.c @@ -41,15 +41,12 @@ #include -#include "misc.h" -#include "treaty.h" +#include "file.h" #include "nat.h" #include "news.h" -#include "file.h" -#include "xy.h" -#include "nsc.h" -#include "prototypes.h" #include "optlist.h" +#include "prototypes.h" +#include "treaty.h" int trechk(natid actor, natid victim, int provision) diff --git a/src/lib/subs/whatitem.c b/src/lib/subs/whatitem.c index 7ce6b0f7..a5edc163 100644 --- a/src/lib/subs/whatitem.c +++ b/src/lib/subs/whatitem.c @@ -33,8 +33,6 @@ #include -#include "misc.h" -#include "item.h" #include "prototypes.h" /* diff --git a/src/lib/subs/wu.c b/src/lib/subs/wu.c index aa240ac8..f495387a 100644 --- a/src/lib/subs/wu.c +++ b/src/lib/subs/wu.c @@ -29,24 +29,25 @@ * * Known contributors to this file: * Steve McClure, 2000 - * */ #include -#include -#include "misc.h" #include +#include +#include #if !defined(_WIN32) +#include #include #endif -#include "nat.h" -#include "tel.h" #include "file.h" -#include "player.h" -#include "server.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" +#include "player.h" #include "prototypes.h" +#include "server.h" +#include "tel.h" static struct telstr last_tel[MAXNOC]; diff --git a/src/lib/update/age.c b/src/lib/update/age.c index 8b6ee2ad..066f6d59 100644 --- a/src/lib/update/age.c +++ b/src/lib/update/age.c @@ -33,12 +33,7 @@ #include -#include "misc.h" -#include "nat.h" -#include "file.h" #include "update.h" -#include "gen.h" -#include "optlist.h" void age_levels(int etu) diff --git a/src/lib/update/anno.c b/src/lib/update/anno.c index 806fdf28..b374a7e3 100644 --- a/src/lib/update/anno.c +++ b/src/lib/update/anno.c @@ -36,17 +36,10 @@ #include -#include "misc.h" -#include "tel.h" -#include #include #include -#if !defined(_WIN32) -#include -#endif +#include "tel.h" #include "update.h" -#include "optlist.h" -#include "common.h" static int copy_and_expire(FILE *annfp, FILE *tmpfp, char *tmp_filename, time_t expiry_time); diff --git a/src/lib/update/bp.c b/src/lib/update/bp.c index 05c88b3c..a106bd9c 100644 --- a/src/lib/update/bp.c +++ b/src/lib/update/bp.c @@ -33,13 +33,8 @@ #include -#include "misc.h" -#include "nat.h" -#include "sect.h" #include "budg.h" #include "update.h" -#include "common.h" -#include "optlist.h" static int bud_key[I_MAX + 2] = { 1, 2, 3, 4, 0, 0, 0, 0, 0, 0, 5, 6, 0, 0, 7 }; diff --git a/src/lib/update/deliver.c b/src/lib/update/deliver.c index 4a99b147..9f264ee3 100644 --- a/src/lib/update/deliver.c +++ b/src/lib/update/deliver.c @@ -33,16 +33,10 @@ #include -#include "misc.h" -#include "plague.h" -#include "sect.h" #include "item.h" #include "path.h" -#include "file.h" -#include "xy.h" +#include "plague.h" #include "update.h" -#include "subs.h" -#include "common.h" #define DELIVER_BONUS 4.0 diff --git a/src/lib/update/distribute.c b/src/lib/update/distribute.c index 5fcc9506..e3d9f1df 100644 --- a/src/lib/update/distribute.c +++ b/src/lib/update/distribute.c @@ -34,20 +34,12 @@ #include -#include -#include "misc.h" -#include "plague.h" -#include "nat.h" -#include "sect.h" -#include "item.h" -#include "xy.h" -#include "path.h" -#include "file.h" #include "distribute.h" -#include "update.h" -#include "subs.h" -#include "common.h" +#include "item.h" +#include "path.h" +#include "plague.h" #include "prototypes.h" +#include "update.h" #define EXPORT_BONUS 10.0 #define IMPORT_BONUS 10.0 diff --git a/src/lib/update/finish.c b/src/lib/update/finish.c index 785faa3d..d5d8c27c 100644 --- a/src/lib/update/finish.c +++ b/src/lib/update/finish.c @@ -35,16 +35,10 @@ #include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "file.h" -#include "xy.h" -#include "path.h" #include "distribute.h" +#include "path.h" #include "update.h" -#include "common.h" -#include "optlist.h" +#include /* Used for building up distribution info */ struct distinfo { diff --git a/src/lib/update/human.c b/src/lib/update/human.c index 31d1271b..2cb08f11 100644 --- a/src/lib/update/human.c +++ b/src/lib/update/human.c @@ -35,20 +35,13 @@ #include -#include -#include "misc.h" -#include "sect.h" -#include "nat.h" +#include "budg.h" #include "item.h" #include "news.h" -#include "xy.h" -#include "optlist.h" -#include "budg.h" #include "player.h" #include "update.h" -#include "common.h" -#include "gen.h" -#include "subs.h" +#include "xy.h" +#include static int growfood(struct sctstr *, short *, int, int); static int starve_some(short *, i_type, int); diff --git a/src/lib/update/land.c b/src/lib/update/land.c index 2fbab61a..7bb8a64c 100644 --- a/src/lib/update/land.c +++ b/src/lib/update/land.c @@ -36,24 +36,15 @@ #include -#include -#include "misc.h" -#include "plague.h" -#include "sect.h" -#include "nat.h" -#include "land.h" -#include "ship.h" -#include "news.h" -#include "file.h" -#include "optlist.h" #include "budg.h" -#include "player.h" -#include "update.h" +#include "land.h" #include "lost.h" -#include "common.h" -#include "subs.h" -#include "common.h" -#include "gen.h" +#include "news.h" +#include "plague.h" +#include "player.h" +#include "ship.h" +#include "update.h" +#include static void landrepair(struct lndstr *, struct natstr *, int *, int); static void upd_land(struct lndstr *, int, struct natstr *, int *, int); diff --git a/src/lib/update/main.c b/src/lib/update/main.c index 3339ef1b..a5abb88d 100644 --- a/src/lib/update/main.c +++ b/src/lib/update/main.c @@ -35,23 +35,12 @@ #include -#include "misc.h" -#include "nat.h" -#include "file.h" -#include "sect.h" -#include "player.h" -#include "empthread.h" #include "budg.h" -#include "player.h" -#include "update.h" -#include "common.h" -#include "optlist.h" +#include "empthread.h" #include "journal.h" +#include "player.h" #include "server.h" -#include -#if !defined(_WIN32) -#include -#endif +#include "update.h" long money[MAXNOC]; long pops[MAXNOC]; diff --git a/src/lib/update/material.c b/src/lib/update/material.c index 1777cfcd..19f5483b 100644 --- a/src/lib/update/material.c +++ b/src/lib/update/material.c @@ -33,13 +33,9 @@ #include -#include "misc.h" -#include "sect.h" #include "budg.h" #include "player.h" #include "update.h" -#include "common.h" -#include "subs.h" void get_materials(struct sctstr *sp, int *bp, int *mvec, int check) diff --git a/src/lib/update/mobility.c b/src/lib/update/mobility.c index fbacfd9f..9310deaa 100644 --- a/src/lib/update/mobility.c +++ b/src/lib/update/mobility.c @@ -34,19 +34,11 @@ #include -#include "misc.h" -#include "sect.h" -#include "ship.h" #include "land.h" #include "plane.h" -#include "nat.h" -#include "file.h" -#include "optlist.h" -#include "update.h" -#include "gen.h" -#include "subs.h" -#include "optlist.h" #include "server.h" +#include "ship.h" +#include "update.h" int updating_mob = 1; diff --git a/src/lib/update/move_sat.c b/src/lib/update/move_sat.c index f856b3d1..5aac8215 100644 --- a/src/lib/update/move_sat.c +++ b/src/lib/update/move_sat.c @@ -34,17 +34,10 @@ #include #include -#include "misc.h" -#include "plane.h" -#include "sect.h" -#include "xy.h" #include "nsc.h" -#include "nat.h" #include "path.h" -#include "file.h" +#include "plane.h" #include "update.h" -#include "subs.h" -#include "optlist.h" #ifndef PI #define PI 3.14159265358979323846 diff --git a/src/lib/update/nat.c b/src/lib/update/nat.c index 746a43f6..7bc0467a 100644 --- a/src/lib/update/nat.c +++ b/src/lib/update/nat.c @@ -35,16 +35,9 @@ #include #include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "item.h" -#include "file.h" -#include "xy.h" -#include "optlist.h" -#include "update.h" -#include "subs.h" #include "budg.h" +#include "item.h" +#include "update.h" /* * hap and edu avg mean that the weight on current happiness is diff --git a/src/lib/update/nav_ship.c b/src/lib/update/nav_ship.c index 22211700..c0b72b41 100644 --- a/src/lib/update/nav_ship.c +++ b/src/lib/update/nav_ship.c @@ -34,23 +34,13 @@ #include -#include "misc.h" #include -#include "ship.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" #include "item.h" -#include "optlist.h" -#include "player.h" +#include "nsc.h" +#include "path.h" +#include "ship.h" #include "update.h" -#include "subs.h" -#include "common.h" -#include static void swap(struct shpstr *); diff --git a/src/lib/update/nav_util.c b/src/lib/update/nav_util.c index 3171e83a..206f9058 100644 --- a/src/lib/update/nav_util.c +++ b/src/lib/update/nav_util.c @@ -33,26 +33,15 @@ #include -#include "misc.h" - #include -#include "plague.h" -#include "ship.h" -#include "plane.h" -#include "land.h" -#include "sect.h" -#include "xy.h" -#include "nsc.h" -#include "nat.h" -#include "path.h" -#include "file.h" #include "item.h" -#include "optlist.h" -#include "player.h" +#include "land.h" +#include "nsc.h" +#include "path.h" +#include "plague.h" +#include "plane.h" +#include "ship.h" #include "update.h" -#include "subs.h" -#include "common.h" -#include "gen.h" /* load a specific ship given its * location and what field to modify. diff --git a/src/lib/update/nxtitemp.c b/src/lib/update/nxtitemp.c index 2d9896c8..25e71994 100644 --- a/src/lib/update/nxtitemp.c +++ b/src/lib/update/nxtitemp.c @@ -33,16 +33,11 @@ #include -#include "misc.h" -#include "xy.h" -#include "ship.h" +#include "empobj.h" #include "land.h" #include "nsc.h" -#include "file.h" -#include "player.h" +#include "ship.h" #include "update.h" -#include "gen.h" -#include "common.h" void * nxtitemp(struct nstr_item *np) diff --git a/src/lib/update/plague.c b/src/lib/update/plague.c index f117588a..4429d06d 100644 --- a/src/lib/update/plague.c +++ b/src/lib/update/plague.c @@ -33,20 +33,11 @@ #include -#include "misc.h" -#include "plague.h" -#include "sect.h" -#include "nat.h" #include "item.h" -#include "news.h" -#include "file.h" -#include "xy.h" -#include "optlist.h" -#include "update.h" -#include "common.h" -#include "subs.h" #include "lost.h" -#include "gen.h" +#include "news.h" +#include "plague.h" +#include "update.h" static int infect_people(struct natstr *, struct sctstr *); diff --git a/src/lib/update/plane.c b/src/lib/update/plane.c index a155e7bd..c588ba55 100644 --- a/src/lib/update/plane.c +++ b/src/lib/update/plane.c @@ -35,20 +35,12 @@ #include -#include "misc.h" -#include "sect.h" -#include "plane.h" -#include "ship.h" -#include "nat.h" -#include "file.h" -#include "optlist.h" #include "budg.h" -#include "player.h" -#include "update.h" #include "lost.h" -#include "subs.h" -#include "common.h" -#include "gen.h" +#include "plane.h" +#include "player.h" +#include "ship.h" +#include "update.h" static void planerepair(struct plnstr *, struct natstr *, int *, int); static void upd_plane(struct plnstr *, int, struct natstr *, int *, int); diff --git a/src/lib/update/populace.c b/src/lib/update/populace.c index 1058a929..f5bcfeaf 100644 --- a/src/lib/update/populace.c +++ b/src/lib/update/populace.c @@ -33,18 +33,10 @@ #include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "file.h" -#include "path.h" -#include "xy.h" #include "land.h" -#include "update.h" -#include "subs.h" -#include "gen.h" -#include "common.h" #include "lost.h" +#include "path.h" +#include "update.h" void populace(struct natstr *np, struct sctstr *sp, int etu) diff --git a/src/lib/update/prepare.c b/src/lib/update/prepare.c index 702b6d88..26652579 100644 --- a/src/lib/update/prepare.c +++ b/src/lib/update/prepare.c @@ -35,21 +35,13 @@ #include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "item.h" -#include "file.h" -#include "xy.h" -#include "path.h" -#include "optlist.h" #include "budg.h" +#include "item.h" +#include "land.h" +#include "path.h" #include "player.h" #include "ship.h" -#include "land.h" #include "update.h" -#include "gen.h" -#include "common.h" void prepare_sects(int etu, int *bp) diff --git a/src/lib/update/produce.c b/src/lib/update/produce.c index ae7b2077..d863a6ef 100644 --- a/src/lib/update/produce.c +++ b/src/lib/update/produce.c @@ -33,18 +33,10 @@ #include -#include "misc.h" -#include "sect.h" -#include "product.h" -#include "nat.h" -#include "xy.h" -#include "player.h" -#include "update.h" -#include "gen.h" -#include "subs.h" -#include "common.h" -#include "optlist.h" #include "budg.h" +#include "player.h" +#include "product.h" +#include "update.h" static void materials_charge(struct pchrstr *, short *, int); static int materials_cost(struct pchrstr *, short *, int *); diff --git a/src/lib/update/removewants.c b/src/lib/update/removewants.c index a1b15e62..316d1544 100644 --- a/src/lib/update/removewants.c +++ b/src/lib/update/removewants.c @@ -33,9 +33,6 @@ #include -#include "misc.h" -#include "nat.h" -#include "file.h" #include "update.h" int diff --git a/src/lib/update/revolt.c b/src/lib/update/revolt.c index 3f613ee3..b26c71ad 100644 --- a/src/lib/update/revolt.c +++ b/src/lib/update/revolt.c @@ -34,21 +34,13 @@ #include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "news.h" -#include "file.h" -#include "path.h" -#include "xy.h" #include "land.h" +#include "lost.h" +#include "news.h" #include "nsc.h" +#include "path.h" #include "plane.h" #include "update.h" -#include "common.h" -#include "gen.h" -#include "lost.h" -#include "subs.h" static void take_casualties(struct sctstr *, int); diff --git a/src/lib/update/sail.c b/src/lib/update/sail.c index 1f746087..66bea91b 100644 --- a/src/lib/update/sail.c +++ b/src/lib/update/sail.c @@ -36,19 +36,11 @@ #include -#include "misc.h" -#include "sect.h" +#include +#include "nsc.h" #include "path.h" #include "ship.h" -#include "file.h" -#include "nat.h" -#include "xy.h" -#include "nsc.h" #include "update.h" -#include "subs.h" -#include "common.h" -#include -#include static void fltp_to_list(struct fltheadstr *, struct emp_qelem *); diff --git a/src/lib/update/sect.c b/src/lib/update/sect.c index f25f7e5a..f0105ac8 100644 --- a/src/lib/update/sect.c +++ b/src/lib/update/sect.c @@ -34,24 +34,15 @@ #include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "item.h" -#include "file.h" -#include "xy.h" -#include "path.h" -#include "product.h" -#include "optlist.h" #include "budg.h" -#include "player.h" +#include "item.h" #include "land.h" +#include "lost.h" +#include "path.h" +#include "player.h" +#include "product.h" #include "ship.h" #include "update.h" -#include "subs.h" -#include "common.h" -#include "lost.h" -#include "gen.h" /* * Increase sector efficiency if old type == new type. diff --git a/src/lib/update/ship.c b/src/lib/update/ship.c index 5c2f5a8e..1d4b93ec 100644 --- a/src/lib/update/ship.c +++ b/src/lib/update/ship.c @@ -37,25 +37,15 @@ #include #include -#include "misc.h" -#include "plague.h" -#include "sect.h" -#include "nat.h" -#include "ship.h" -#include "news.h" -#include "file.h" -#include "product.h" -#include "land.h" -#include "xy.h" -#include "nsc.h" -#include "optlist.h" -#include "player.h" -#include "update.h" -#include "common.h" -#include "subs.h" -#include "gen.h" -#include "lost.h" #include "budg.h" +#include "land.h" +#include "lost.h" +#include "news.h" +#include "plague.h" +#include "player.h" +#include "product.h" +#include "ship.h" +#include "update.h" static void shiprepair(struct shpstr *, struct natstr *, int *, int); static void upd_ship(struct shpstr *, int, struct natstr *, int *, int); diff --git a/src/server/idle.c b/src/server/idle.c index b6714287..e368fb2a 100644 --- a/src/server/idle.c +++ b/src/server/idle.c @@ -34,12 +34,10 @@ #include #include -#include "misc.h" -#include "player.h" -#include "empio.h" #include "empthread.h" -#include "prototypes.h" #include "optlist.h" +#include "player.h" +#include "prototypes.h" #include "server.h" /*ARGSUSED*/ diff --git a/src/server/lostitem.c b/src/server/lostitem.c index bd4b7218..d5be0c1f 100644 --- a/src/server/lostitem.c +++ b/src/server/lostitem.c @@ -33,12 +33,9 @@ #include -#include "misc.h" -#include "player.h" #include "empthread.h" #include "file.h" #include "lost.h" -#include "prototypes.h" #include "optlist.h" #include "server.h" diff --git a/src/server/main.c b/src/server/main.c index 5eafacc6..9166d7fa 100644 --- a/src/server/main.c +++ b/src/server/main.c @@ -37,40 +37,40 @@ #include -#if !defined(_WIN32) -#include -#endif #include #include #include -#include #if defined(_WIN32) #define WIN32 #include #undef NS_ALL #include -#include "../lib/gen/getopt.h" +#include #include "service.h" -#include "direct.h" +#include "../lib/gen/getopt.h" +#else +#include +#include #endif -#include "misc.h" -#include "nat.h" +#include "empio.h" +#include "empthread.h" #include "file.h" #include "journal.h" -#include "player.h" -#include "empthread.h" -#include "plane.h" -#include "nuke.h" #include "land.h" -#include "ship.h" -#include "sect.h" -#include "product.h" +#include "misc.h" +#include "nat.h" +#include "nuke.h" #include "optlist.h" -#include "server.h" -#include "version.h" +#include "plane.h" +#include "player.h" +#include "product.h" #include "prototypes.h" +#include "sect.h" +#include "server.h" +#include "ship.h" +#include "version.h" static void create_pidfile(char *, pid_t); diff --git a/src/server/marketup.c b/src/server/marketup.c index cdabe6d2..4dbe7f95 100644 --- a/src/server/marketup.c +++ b/src/server/marketup.c @@ -33,12 +33,11 @@ #include -#include "misc.h" -#include "player.h" #include "empthread.h" #include "file.h" -#include "server.h" +#include "player.h" #include "prototypes.h" +#include "server.h" /*ARGSUSED*/ static void diff --git a/src/server/shutdown.c b/src/server/shutdown.c index 00f107ec..49bf065b 100644 --- a/src/server/shutdown.c +++ b/src/server/shutdown.c @@ -33,15 +33,12 @@ #include -#include "misc.h" -#include "player.h" -#include "empio.h" -#include "empthread.h" -#include "nat.h" -#include "file.h" #include -#include "server.h" +#include "empthread.h" +#include "file.h" +#include "nat.h" #include "prototypes.h" +#include "server.h" int shutdown_pending; diff --git a/src/server/timestamp.c b/src/server/timestamp.c index dc9b15ce..56af0676 100644 --- a/src/server/timestamp.c +++ b/src/server/timestamp.c @@ -36,11 +36,10 @@ #include #include -#include "misc.h" -#include "player.h" #include "empthread.h" -#include "prototypes.h" +#include "misc.h" #include "optlist.h" +#include "prototypes.h" #include "server.h" /*ARGSUSED*/ diff --git a/src/server/update.c b/src/server/update.c index e6b12467..0cbbc58e 100644 --- a/src/server/update.c +++ b/src/server/update.c @@ -36,16 +36,15 @@ #include #include -#include #ifndef _WIN32 #include #endif #include -#include "misc.h" -#include "player.h" #include "empthread.h" -#include "prototypes.h" +#include "misc.h" #include "optlist.h" +#include "player.h" +#include "prototypes.h" #include "server.h" empth_sem_t *update_sem; diff --git a/src/util/fairland.c b/src/util/fairland.c index e4e419a1..3ceb0da3 100644 --- a/src/util/fairland.c +++ b/src/util/fairland.c @@ -68,22 +68,23 @@ static int quiet = 0; #if defined(_WIN32) #include "../lib/gen/getopt.h" +#else +#include #endif #include #include #include -#include #include -#include "misc.h" -#include "power.h" -#include "nat.h" -#include "sect.h" #include "file.h" -#include "xy.h" +#include "misc.h" +#include "nat.h" #include "optlist.h" +#include "power.h" #include "prototypes.h" +#include "sect.h" #include "version.h" +#include "xy.h" /* do not change these 4 defines */ #define LANDMIN 1 /* plate altitude for normal land */ diff --git a/src/util/files.c b/src/util/files.c index 5d1238b9..42752b2a 100644 --- a/src/util/files.c +++ b/src/util/files.c @@ -35,32 +35,29 @@ #include -#include #include -#if !defined(_WIN32) -#include -#include -#else +#include +#if defined(_WIN32) #include #include "../lib/gen/getopt.h" +#else +#include +#include #endif -#include -#include -#include -#include "misc.h" -#include "sect.h" -#include "nat.h" -#include "ship.h" -#include "land.h" -#include "plane.h" -#include "nuke.h" -#include "power.h" -#include "trade.h" #include "file.h" -#include "tel.h" -#include "prototypes.h" +#include "land.h" +#include "misc.h" +#include "nat.h" +#include "nuke.h" #include "optlist.h" +#include "plane.h" +#include "power.h" +#include "prototypes.h" +#include "sect.h" +#include "ship.h" +#include "tel.h" +#include "trade.h" #include "version.h" static void file_sct_init(coord, coord, struct sctstr *ptr, diff --git a/src/util/pconfig.c b/src/util/pconfig.c index 593e9e9f..22c506b1 100644 --- a/src/util/pconfig.c +++ b/src/util/pconfig.c @@ -34,7 +34,6 @@ #include #include -#include "optlist.h" #include "prototypes.h" int