(P_SHELL, P_GUN, P_PETROL, P_IRON, P_DUST, P_BAR, P_FOOD, P_OIL)
(P_LCM, P_HCM, P_TLEV, P_RLEV, P_ELEV, P_HLEV, P_URAN): Use -1 instead of 0 for `no product', shift down product indexes and update product.config and sector.config accordingly. (budg, prod, show_sect_capab, produce, produce_sect): Adapt test for no product. (ef_elt_byname): Remove the hack to hide pchr[0]. (prod_eff): Oops on no product.
This commit is contained in:
parent
08937006d7
commit
f284b0beab
9 changed files with 62 additions and 60 deletions
|
@ -58,21 +58,21 @@ struct pchrstr {
|
|||
char *p_sname; /* short (7 char or less) name of product */
|
||||
};
|
||||
|
||||
#define P_SHELL 1
|
||||
#define P_GUN 2
|
||||
#define P_PETROL 3
|
||||
#define P_IRON 4
|
||||
#define P_DUST 5
|
||||
#define P_BAR 6
|
||||
#define P_FOOD 7
|
||||
#define P_OIL 8
|
||||
#define P_LCM 9
|
||||
#define P_HCM 10
|
||||
#define P_TLEV 11
|
||||
#define P_RLEV 12
|
||||
#define P_ELEV 13
|
||||
#define P_HLEV 14
|
||||
#define P_URAN 15
|
||||
#define P_SHELL 0
|
||||
#define P_GUN 1
|
||||
#define P_PETROL 2
|
||||
#define P_IRON 3
|
||||
#define P_DUST 4
|
||||
#define P_BAR 5
|
||||
#define P_FOOD 6
|
||||
#define P_OIL 7
|
||||
#define P_LCM 8
|
||||
#define P_HCM 9
|
||||
#define P_TLEV 10
|
||||
#define P_RLEV 11
|
||||
#define P_ELEV 12
|
||||
#define P_HLEV 13
|
||||
#define P_URAN 14
|
||||
|
||||
extern struct pchrstr pchr[P_URAN + 2];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue