Add some missing declarations to headers. Remove some redundant
declarations elsewhere. Change linkage of some functions to static.
This commit is contained in:
parent
e7811102a3
commit
4a3f0b8146
43 changed files with 72 additions and 169 deletions
|
@ -44,9 +44,7 @@
|
|||
#include "tel.h"
|
||||
#include "land.h"
|
||||
#include "commands.h"
|
||||
|
||||
extern float start_education, start_happiness;
|
||||
extern float start_technology, start_research;
|
||||
#include "optlist.h"
|
||||
|
||||
int
|
||||
add(void)
|
||||
|
|
|
@ -48,8 +48,6 @@
|
|||
#include "commands.h"
|
||||
#include "optlist.h"
|
||||
|
||||
extern int etu_per_update;
|
||||
extern int sect_mob_neg_factor;
|
||||
/*
|
||||
* format: anti <SECT>
|
||||
*/
|
||||
|
|
|
@ -56,15 +56,6 @@
|
|||
#define MIN(x,y) ((x) > (y) ? (y) : (x))
|
||||
#endif
|
||||
|
||||
extern int etu_per_update;
|
||||
extern double bankint;
|
||||
extern double money_civ;
|
||||
extern double money_uw;
|
||||
extern double money_mil;
|
||||
extern double obrate, uwbrate;
|
||||
extern int etu_per_update;
|
||||
extern double money_res;
|
||||
|
||||
static void calc_all(long int (*p_sect)[2], int *taxes, int *Ncivs,
|
||||
int *Nuws, int *bars, int *Nbars, int *mil,
|
||||
int *ships, int *sbuild, int *nsbuild, int *smaint,
|
||||
|
|
|
@ -68,10 +68,6 @@ static int build_plane(register struct sctstr *sp,
|
|||
|
||||
static int cash; /* static ok */
|
||||
|
||||
extern int morale_base;
|
||||
extern int sect_mob_neg_factor;
|
||||
extern int etu_per_update;
|
||||
|
||||
/*
|
||||
* build <WHAT> <SECTS> <TYPE|DIR|MEG> [NUMBER]
|
||||
*/
|
||||
|
|
|
@ -54,8 +54,6 @@
|
|||
#include "commands.h"
|
||||
#include "optlist.h"
|
||||
|
||||
extern int MARK_DELAY;
|
||||
|
||||
/*
|
||||
* format: buy <COMMODITY>
|
||||
*
|
||||
|
|
|
@ -46,9 +46,6 @@
|
|||
|
||||
static int explore_map(s_char *what, coord curx, coord cury, s_char *arg);
|
||||
|
||||
extern int etu_per_update;
|
||||
extern int sect_mob_neg_factor;
|
||||
|
||||
int
|
||||
explore(void)
|
||||
{
|
||||
|
|
|
@ -235,7 +235,6 @@ printdir(void)
|
|||
extern int alphasort(const struct dirent *const *,
|
||||
const struct dirent *const *);
|
||||
#endif
|
||||
extern s_char *infodir;
|
||||
static time_t lastmodtime;
|
||||
static int number;
|
||||
static struct dirent **dp;
|
||||
|
@ -369,7 +368,6 @@ apro(void)
|
|||
int
|
||||
info(void)
|
||||
{
|
||||
extern s_char *infodir;
|
||||
s_char buf[255];
|
||||
FILE *fp;
|
||||
s_char *bp;
|
||||
|
@ -441,7 +439,6 @@ info(void)
|
|||
static int
|
||||
printdir(void)
|
||||
{
|
||||
extern s_char *infodir;
|
||||
HANDLE hDir;
|
||||
WIN32_FIND_DATA fData;
|
||||
int count;
|
||||
|
@ -473,7 +470,6 @@ printdir(void)
|
|||
int
|
||||
apro(void)
|
||||
{
|
||||
extern s_char *infodir;
|
||||
HANDLE hDir;
|
||||
WIN32_FIND_DATA fData;
|
||||
FILE *fp;
|
||||
|
|
|
@ -55,7 +55,6 @@
|
|||
#define LOAD 1
|
||||
#define UNLOAD -1
|
||||
|
||||
void gift(int givee, int giver, s_char *ptr, int type, s_char *mesg);
|
||||
static int load_plane_ship(struct sctstr *sectp, struct shpstr *sp,
|
||||
int noisy, int load_unload, int *nshipsp);
|
||||
static int load_land_ship(struct sctstr *sectp, struct shpstr *sp,
|
||||
|
|
|
@ -41,8 +41,7 @@
|
|||
#include "nat.h"
|
||||
#include "deity.h"
|
||||
#include "commands.h"
|
||||
|
||||
extern int morale_base;
|
||||
#include "optlist.h"
|
||||
|
||||
int
|
||||
morale(void)
|
||||
|
|
|
@ -49,10 +49,6 @@
|
|||
#include <fcntl.h>
|
||||
#include <math.h>
|
||||
|
||||
extern float start_education, start_happiness;
|
||||
extern float start_technology, start_research;
|
||||
extern int morale_base;
|
||||
|
||||
static int deity_build_land(int, coord, coord, natid, int);
|
||||
static int isok(int x, int y);
|
||||
static void ok(s_char *map, int x, int y);
|
||||
|
@ -64,9 +60,6 @@ static struct range defrealm = { -8, -5, 10, 5, 0, 0 };
|
|||
int
|
||||
new(void)
|
||||
{
|
||||
#ifdef START_UNITS
|
||||
extern int start_unit_type[START_UNITS];
|
||||
#endif /* START_UNITS */
|
||||
struct sctstr sect;
|
||||
struct natstr *natp;
|
||||
struct boundstr newrealms;
|
||||
|
|
|
@ -48,7 +48,6 @@
|
|||
#include "land.h"
|
||||
#include "commands.h"
|
||||
|
||||
extern int etu_per_update;
|
||||
static void starv_sects(s_char *range);
|
||||
static void starv_ships(s_char *range);
|
||||
static void starv_units(s_char *range);
|
||||
|
|
|
@ -57,8 +57,6 @@ static void fire_dchrg(struct shpstr *sp, struct shpstr *targ, int range,
|
|||
int ntargets);
|
||||
static int fire_torp(struct shpstr *, struct shpstr *, int, int);
|
||||
|
||||
s_char *prsub(struct shpstr *sp);
|
||||
|
||||
int
|
||||
torp(void)
|
||||
{
|
||||
|
|
|
@ -55,10 +55,6 @@
|
|||
#include "commands.h"
|
||||
#include "optlist.h"
|
||||
|
||||
extern int sect_mob_neg_factor;
|
||||
extern int etu_per_update;
|
||||
extern int TRADE_DELAY;
|
||||
|
||||
/*
|
||||
* format: trade
|
||||
*/
|
||||
|
|
|
@ -47,8 +47,6 @@
|
|||
#include "optlist.h"
|
||||
#include "commands.h"
|
||||
|
||||
extern float drnuke_const;
|
||||
|
||||
int
|
||||
vers(void)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue