]> git.pond.sub.org Git - empserver/blob - src/lib/global/land.c
1a9e0878e60877849df8465ac1879e2b0eef6da4
[empserver] / src / lib / global / land.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  *  land.c: Land unit characteristics
29  * 
30  *  Known contributors to this file:
31  *     Thomas Ruschak, 1992
32  *     Ken Stevens, 1995
33  *     Steve McClure, 1998-2000
34  */
35
36 #include "misc.h"
37 #include "var.h"
38 #include "land.h"
39
40 struct lchrstr lchr[] = {
41
42 /* name
43    lcm, hcm, mil, gun, shell, tech,   $,
44    att, def, vul, spd, vis, spy, rad, frg, acc, dam, amm, aaf, fc, fu, xpl, mxl
45    flags, nv
46    cargo
47 */
48     {2,
49      {V_FOOD, V_MILIT},
50      {12, 20},
51      "cav  cavalry",
52      10, 5, 0, 0, 0, 30, 500,
53      1.2, 0.5, 80, 32, 18, 4, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0,
54      L_RECON | L_LIGHT,
55      },
56
57     {3,
58      {V_FOOD, V_SHELL, V_MILIT},
59      {15, 1, 25},
60      "linf light infantry",
61      8, 4, 0, 0, 0, 40, 300,
62      1.0, 1.5, 60, 28, 15, 2, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0,
63      L_ASSAULT | L_LIGHT,
64      },
65
66     {2,
67      {V_FOOD, V_MILIT},
68      {24, 100},
69      "inf  infantry",
70      10, 5, 0, 0, 0, 50, 500,
71      1.0, 1.5, 60, 25, 15, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0,
72      L_ASSAULT | L_LIGHT,
73      },
74
75     {3,
76      {V_FOOD, V_SHELL, V_MILIT},
77      {60, 8, 100},
78      "mtif motor inf",
79      15, 10, 0, 0, 0, 190, 400,
80      1.2, 2.2, 60, 33, 17, 1, 3, 0, 0, 0, 2, 3, 13, 1, 0, 0,
81      L_LIGHT,
82      },
83
84     {3,
85      {V_FOOD, V_SHELL, V_MILIT},
86      {60, 8, 100},
87      "mif  mech inf",
88      15, 10, 0, 0, 0, 190, 800,
89      1.5, 2.5, 50, 33, 17, 1, 3, 0, 0, 0, 2, 3, 13, 1, 0, 0,
90      L_LIGHT,
91      },
92
93     {3,
94      {V_FOOD, V_SHELL, V_MILIT},
95      {60, 4, 100},
96      "mar  marines",
97      10, 5, 0, 0, 0, 140, 1000,
98      1.4, 2.4, 60, 25, 14, 2, 1, 0, 0, 0, 1, 2, 0, 0, 0, 0,
99      L_MARINE | L_ASSAULT | L_LIGHT,
100      },
101
102     {10,
103      {V_SHELL, V_GUN, V_FOOD, V_LCM, V_HCM, V_DUST, V_BAR, V_IRON,
104       V_PETROL, V_MILIT},
105      {200, 10, 300, 200, 100, 100, 10, 100, 300, 25},
106      "sup  supply",
107      10, 5, 0, 0, 0, 50, 500,
108      0.1, 0.2, 80, 25, 20, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
109      L_LIGHT | L_SUPPLY,
110      },
111
112     {12,
113      {V_SHELL, V_GUN, V_FOOD, V_LCM, V_HCM, V_DUST, V_BAR, V_IRON,
114       V_PETROL, V_MILIT, V_OIL, V_RAD},
115      {990, 200, 990, 990, 990, 500, 100, 500, 990, 990, 990, 150},
116      "tra  train",
117      100, 50, 0, 0, 0, 40, 3500,
118      0.0, 0.0, 120, 10, 25, 3, 0, 0, 0, 0, 0, 0, 0, 0, 5, 12,
119      L_XLIGHT | L_TRAIN | L_HEAVY | L_SUPPLY,
120      },
121
122     {0,
123      {V_FOOD},
124      {0,},
125      "spy  infiltrator",
126      10, 5, 0, 0, 0, 40, 750,
127      0.0, 0.0, 80, 32, 18, 4, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0,
128      L_ASSAULT | L_RECON | L_LIGHT | L_SPY,
129      },
130
131     {1,
132      {V_SHELL},
133      {3,},
134      "com  commando",
135      10, 5, 0, 0, 0, 55, 1500,
136      0.0, 0.0, 80, 32, 18, 4, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0,
137      L_ASSAULT | L_RECON | L_LIGHT | L_SPY,
138      },
139
140     {3,
141      {V_FOOD, V_SHELL, V_MILIT},
142      {12, 5, 20},
143      "aau  aa unit",
144      20, 10, 0, 0, 0, 70, 500,
145      0.5, 1.0, 60, 18, 20, 1, 1, 0, 0, 0, 1, 2, 0, 0, 0, 0,
146      L_FLAK | L_LIGHT,
147      },
148
149     {4,
150      {V_FOOD, V_SHELL, V_MILIT, V_GUN},
151      {24, 40, 25, 10},
152      "art  artillery",
153      20, 10, 0, 0, 0, 35, 800,
154      0.1, 0.4, 70, 18, 20, 1, 0, 8, 50, 5, 2, 1, 0, 0, 0, 0,
155      L_LIGHT,
156      },
157
158     {4,
159      {V_FOOD, V_SHELL, V_MILIT, V_GUN},
160      {12, 20, 25, 6},
161      "lat  lt artillery",
162      20, 10, 0, 0, 0, 70, 500,
163      0.2, 0.6, 60, 30, 18, 1, 1, 5, 10, 3, 1, 1, 0, 0, 0, 0,
164      L_LIGHT,
165      },
166
167     {4,
168      {V_FOOD, V_SHELL, V_MILIT, V_GUN},
169      {24, 80, 25, 12},
170      "hat  hvy artillery",
171      40, 20, 0, 0, 0, 100, 800,
172      0.0, 0.2, 60, 12, 20, 1, 0, 11, 99, 8, 4, 1, 0, 0, 0, 0,
173      0,
174      },
175
176     {4,
177      {V_FOOD, V_SHELL, V_MILIT, V_GUN},
178      {15, 40, 25, 10},
179      "mat  mech artillery",
180      20, 10, 0, 0, 0, 200, 1000,
181      0.2, 0.6, 50, 35, 17, 1, 1, 8, 35, 6, 3, 3, 13, 1, 0, 0,
182      L_LIGHT,
183      },
184
185     {3,
186      {V_FOOD, V_SHELL, V_MILIT},
187      {12, 3, 20},
188      "eng  engineer",
189      10, 5, 0, 0, 0, 130, 3000,
190      1.2, 2.4, 50, 25, 14, 2, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0,
191      L_ENGINEER | L_ASSAULT | L_LIGHT,
192      },
193
194     {3,
195      {V_FOOD, V_SHELL, V_MILIT},
196      {15, 4, 20},
197      "meng mech engineer",
198      10, 5, 0, 0, 0, 260, 4500,
199      1.8, 3.5, 45, 33, 15, 3, 3, 0, 0, 0, 1, 5, 25, 2, 0, 0,
200      L_ENGINEER | L_ASSAULT | L_LIGHT,
201      },
202
203     {3,
204      {V_FOOD, V_SHELL, V_MILIT},
205      {30, 4, 50},
206      "lar  lt armor",
207      10, 5, 0, 0, 0, 150, 600,
208      2.0, 1.0, 50, 42, 15, 4, 4, 0, 0, 0, 1, 2, 25, 1, 0, 0,
209      L_RECON | L_LIGHT,
210      },
211
212     {3,
213      {V_FOOD, V_SHELL, V_MILIT},
214      {48, 3, 100},
215      "har  hvy armor",
216      20, 10, 0, 0, 0, 120, 500,
217      2.0, 0.8, 50, 18, 17, 1, 1, 0, 0, 0, 2, 1, 10, 2, 0, 0,
218      0,
219      },
220
221     {3,
222      {V_FOOD, V_SHELL, V_MILIT},
223      {30, 4, 50},
224      "arm  armor",
225      20, 10, 0, 0, 0, 170, 1000,
226      3.0, 1.5, 40, 33, 16, 2, 2, 0, 0, 0, 1, 2, 13, 1, 0, 0,
227      L_LIGHT,
228      },
229
230     {3,
231      {V_FOOD, V_SHELL, V_MILIT},
232      {30, 4, 50},
233      "sec  security",
234      10, 5, 0, 0, 0, 170, 600,
235      1.0, 2.0, 60, 25, 15, 2, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0,
236      L_SECURITY | L_LIGHT,
237      },
238
239     {2,
240      {V_FOOD, V_MILIT},
241      {7, 10},
242      "rad  radar unit",
243      10, 5, 0, 0, 0, 270, 1000,
244      0.0, 0.0, 50, 33, 15, 3, 0, 0, 0, 0, 0, 2, 25, 2, 1, 0,
245      L_XLIGHT | L_RADAR | L_LIGHT,
246      },
247
248 /* name
249    lcm, hcm, mil, gun, shell, tech,   $,
250    att, def, vul, spd, vis, spy, rad, frg, acc, dam, amm, aaf, fc, fu, xpl,
251    flags, nv
252    cargo
253 */
254
255     {0,
256      {0},
257      {0},
258      "",
259      0, 0, 0, 0, 0, 0, 0,
260      0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
261      0,
262      }
263 };
264
265 int lnd_maxno = (sizeof(lchr) / sizeof(struct lchrstr)) - 1;