]> git.pond.sub.org Git - empserver/blob - src/lib/global/product.c
Indented with src/scripts/indent-emp.
[empserver] / src / lib / global / product.c
1 /*
2  *  Empire - A multi-player, client/server Internet based war game.
3  *  Copyright (C) 1986-2000, Dave Pare, Jeff Bailey, Thomas Ruschak,
4  *                           Ken Stevens, Steve McClure
5  *
6  *  This program is free software; you can redistribute it and/or modify
7  *  it under the terms of the GNU General Public License as published by
8  *  the Free Software Foundation; either version 2 of the License, or
9  *  (at your option) any later version.
10  *
11  *  This program is distributed in the hope that it will be useful,
12  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  *  GNU General Public License for more details.
15  *
16  *  You should have received a copy of the GNU General Public License
17  *  along with this program; if not, write to the Free Software
18  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19  *
20  *  ---
21  *
22  *  See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
23  *  related information and legal notices. It is expected that any future
24  *  projects/authors will amend these files as needed.
25  *
26  *  ---
27  *
28  *  product.c: Product information
29  * 
30  *  Known contributors to this file:
31  *     
32  */
33
34 #include "misc.h"
35 #include "product.h"
36 #include "sect.h"
37 #include "nat.h"
38 #include "var.h"
39
40
41 struct pchrstr pchr[] = {
42 /*       level      cost    nrndx nrdep nlndx   nlmin nllag effic  sname name */
43     {0, {0}, {0},
44      0, 0, 0, 0, 0, 0, 0, 0, 0,
45      "unused", "",},
46     {2, {V_LCM, V_HCM}, {2, 1},
47      V_SHELL, -1, 3, 0, 0, NAT_TLEV, 20, 10, 100,
48      "shells", "shells",},
49     {3, {V_OIL, V_LCM, V_HCM}, {1, 5, 10},
50      V_GUN, -1, 30, 0, 0, NAT_TLEV, 20, 10, 100,
51      "guns", "guns",},
52     {1, {V_OIL}, {1},
53      V_PETROL, -1, 1, 0, 0, NAT_TLEV, 20, 10, 1000,
54      "petrol", "petrol",},
55     {0, {0}, {0},
56      V_IRON, -1, 0, OFFSET(sctstr, sct_min), 0, -1, 0, 0, 100,
57      "iron ore", "iron",},
58     {0, {0}, {0},
59      V_DUST, -1, 0, OFFSET(sctstr, sct_gmin), 20, -1, 0, 0, 100,
60      "gold dust", "dust",},
61     {1, {V_DUST}, {5},
62      V_BAR, -1, 10, 0, 0, -1, 0, 0, 100,
63      "gold bars", "bars",},
64     {0, {0}, {0},
65      V_FOOD, -1, 0, OFFSET(sctstr, sct_fertil), 0, NAT_TLEV, -10, 10, 900,
66      "food", "food",},
67     {0, {0}, {0},
68      V_OIL, -1, 0, OFFSET(sctstr, sct_oil), 10, NAT_TLEV, -10, 10, 100,
69      "oil", "oil",},
70     {1, {V_IRON}, {1},
71      V_LCM, -1, 0, 0, 0, NAT_TLEV, -10, 10, 100,
72      "light construction materials", "lcm",},
73     {1, {V_IRON}, {2},
74      V_HCM, -1, 0, 0, 0, NAT_TLEV, -10, 10, 100,
75      "heavy construction materials", "hcm",},
76     {3, {V_DUST, V_OIL, V_LCM}, {1, 5, 10},
77      0, NAT_TLEV, 5 * ETUS, 0, 0, NAT_ELEV, 5, 10, 100,
78      "technological breakthroughs", "tech",},
79     {3, {V_DUST, V_OIL, V_LCM}, {1, 5, 10},
80      0, NAT_RLEV, 90, 0, 0, NAT_ELEV, 5, 10, 100,
81      "medical discoveries", "medical",},
82     {1, {V_LCM}, {1},
83      0, NAT_ELEV, 9, 0, 0, -1, 0, 0, 100,
84      "a class of graduates", "edu",},
85     {1, {V_LCM}, {1},
86      0, NAT_HLEV, 9, 0, 0, -1, 0, 0, 100,
87      "happy strollers", "happy",},
88     {0, {0}, {0},
89      V_RAD, -1, 2, OFFSET(sctstr, sct_uran), 35, NAT_TLEV, 40, 10, 100,
90      "radioactive materials", "rad",},
91     {0, {0}, {0},
92      V_DUST, -1, 0, OFFSET(sctstr, sct_gmin), 20, -1, 0, 0, 75,
93      "gold dust", "dust",},
94     {0, {0}, {0},
95      0, 0, 0, 0, 0, 0, 0, 0, 0, "", "",}
96 };
97
98 int prd_maxno = (sizeof(pchr) / sizeof(struct pchrstr)) - 1;