]> git.pond.sub.org Git - empserver/blob - src/lib/global/plane.c
Update copyright notice.
[empserver] / src / lib / global / plane.c
1 /*
2  *  Empire - A multi-player, client/server Internet based war game.
3  *  Copyright (C) 1986-2004, 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  *  plane.c: Plane characteristics
29  * 
30  *  Known contributors to this file:
31  *     Dave Pare, 1986
32  *     Jeff Bailey
33  *     Thomas Ruschak, 1992
34  *     Ken Stevens, 1995
35  *     Steve McClure, 1998
36  */
37
38 /*
39  * plane characteristics
40  * flags indicate capabilities of craft...
41  * P_T: tactical, P_F: fighter/interceptor, P_B: bomber,
42  * P_C: cargo, P_G: glider, P_V: vtol, P_M: (one-shot) missile
43  * P_L: light, can land on carriers.
44  * P_O: orbits (sat's & anti-sats), P_N: nuke killer (SDI)
45  * P_X: stealthy
46  * P_E: Extra light
47  * P_K: Chopper
48  * P_P: Can paratroop
49  * P_A: ASW plane, can find subs when reconning, can bomb subs
50  * P_R: recon plane, gets some info
51  * P_I: Image capability (advanced spying)
52  * 
53  * Note if a plane is P_M (a missile) then it will automatically be made
54  * P_V (vtol) in init_global()
55  */
56
57 #include "misc.h"
58 #include "plane.h"
59
60 struct plchrstr plchr[] = {
61
62 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
63     {
64      "f1   Sopwith Camel",
65      8, 2, 400, 50, 90, 1, 1, 1, 4, 1, 1,
66      0,
67      P_V | P_T | P_F},
68
69 /* name        lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
70     {
71      "f2   P-51 Mustang",
72      8, 2, 400, 80, 80, 1, 4, 4, 8, 1, 1,
73      0,
74      P_L | P_T | P_F},
75
76 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
77     {
78      "jf1  F-4 Phantom",
79      12, 4, 1000, 125, 45, 1, 14, 14, 11, 2, 3,
80      0,
81      P_T | P_F | P_L},
82
83
84 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
85     {
86      "jf2  AV-8B Harrier",
87      12, 4, 1400, 195, 30, 1, 17, 17, 14, 2, 3,
88      0,
89      P_T | P_F | P_L | P_V},
90
91 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
92     {
93      "sf   F-117A Nighthawk",
94      15, 5, 3000, 325, 45, 3, 19, 19, 20, 2, 4,
95      80,
96      P_T | P_F | P_L},
97
98 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
99     {
100      "es   P-38 Lightning",
101      9, 3, 700, 90, 60, 1, 5, 5, 15, 1, 2,
102      0,
103      P_ESC | P_T},
104
105 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
106     {
107      "jes  F-14E jet escort",
108      14, 8, 1400, 160, 60, 1, 10, 10, 25, 2, 3,
109      0,
110      P_ESC | P_T},
111
112 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
113     {
114      "lb   TBD-1 Devastator",
115      10, 3, 550, 60, 50, 2, 0, 3, 7, 1, 1,
116      0,
117      P_L | P_V | P_T | P_B},
118
119 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
120     {
121      "jl   A-6 Intruder",
122      14, 4, 1000, 130, 25, 3, 0, 9, 11, 2, 3,
123      0,
124      P_T | P_B | P_L},
125
126 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
127     {
128      "mb   medium bomber",
129      14, 5, 1000, 80, 45, 4, 0, 5, 14, 3, 3,
130      0,
131      P_T | P_B},
132
133 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
134     {
135      "jfb  FB-111 Aardvark f/b",
136      20, 10, 1800, 140, 30, 7, 8, 8, 20, 5, 5,
137      0,
138      P_T | P_B},
139     {
140      "hb   B-26B Marauder",
141      20, 6, 1100, 90, 90, 5, 0, 4, 15, 2, 2,
142      0,
143      P_B},
144
145 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
146     {
147      "jhb  B-52 Strato-Fortress",
148      26, 13, 3200, 150, 80, 12, 0, 11, 35, 5, 6,
149      0,
150      P_B},
151
152 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
153     {
154      "sb   B-2 stealth bomber",
155      15, 5, 4000, 325, 25, 8, 0, 15, 28, 2, 5,
156      80,
157      P_T | P_B},
158
159
160 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
161     {
162      "as   anti-sub plane",
163      10, 3, 550, 100, 85, 2, 0, 3, 15, 2, 2,
164      0,
165      P_SWEEP | P_MINE | P_T | P_A},
166
167 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
168     {
169      "np   naval plane",
170      20, 10, 1800, 135, 70, 3, 0, 4, 28, 4, 2,
171      0,
172      P_SWEEP | P_MINE | P_C | P_T | P_A | P_L},
173
174 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
175     {
176      "nc   AH-1 Cobra",
177      8, 2, 800, 160, 55, 2, 0, 3, 11, 2, 2,
178      0,
179      P_V | P_SWEEP | P_T | P_A | P_K},
180
181 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
182     {
183      "ac   AH-64 Apache",
184      8, 2, 800, 200, 15, 1, 0, 9, 11, 2, 2,
185      40,
186      P_V | P_T | P_K},
187
188 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
189     {
190      "tc   transport chopper",
191      8, 2, 800, 135, 0, 5, 0, 3, 7, 2, 2,
192      40,
193      P_V | P_C | P_P | P_L | P_K},
194
195 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
196     {
197      "tr   C-56 Lodestar",
198      14, 5, 1000, 85, 0, 7, 0, 2, 15, 3, 3,
199      0,
200      P_C | P_P},
201
202 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
203     {
204      "jt   C-141 Starlifter",
205      18, 5, 1500, 160, 0, 16, 0, 9, 35, 3, 4,
206      0,
207      P_C | P_P},
208
209 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
210     {
211      "zep  Zeppelin",
212      6, 2, 1000, 70, 60, 2, 0, -3, 15, 3, 2,
213      0,
214      P_S | P_V | P_T | P_C},
215 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
216     {
217      "re   recon",
218      12, 4, 800, 130, 0, 0, 0, 4, 15, 2, 2,
219      20,
220      P_S},
221
222 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
223     {
224      "sp   E2-C Hawkeye",
225      15, 5, 2000, 190, 0, 0, 0, 11, 32, 2, 5,
226      50,
227      P_S},
228
229 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
230     {
231      "lst  landsat",
232      20, 20, 2000, 245, 0, 0, 0, 3, 41, 0, 9,
233      0,
234      P_O},
235
236 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
237     {
238      "ss   KH-7 spysat",
239      20, 20, 4000, 305, 0, 0, 0, 3, 61, 0, 9,
240      0,
241      P_I | P_O | P_S},
242
243 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
244     {
245      "mi   Harpoon",
246      8, 2, 300, 160, 50, 6, 0, 5, 6, 0, 0,
247      0,
248      P_L | P_T | P_M | P_MAR},
249 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
250     {
251      "sam  Sea Sparrow",
252      3, 1, 200, 180, 0, 0, 0, 18, 2, 0, 0,
253      0,
254      P_L | P_F | P_E | P_M},
255
256 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
257     {
258      "ssm  V2",
259      15, 15, 800, 145, 60, 3, 0, 3, 4, 0, 0,
260      0,
261      P_T | P_M},
262
263 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
264     {
265      "srbm Atlas",
266      20, 20, 1000, 200, 60, 6, 0, 5, 9, 0, 0,
267      0,
268      P_T | P_M},
269
270 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
271     {
272      "irbm Titan",
273      20, 20, 1500, 260, 60, 8, 0, 10, 15, 0, 0,
274      0,
275      P_T | P_M},
276
277 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
278     {
279      "icbm Minuteman",
280      20, 20, 3000, 310, 60, 10, 0, 15, 41, 0, 0,
281      0,
282      P_T | P_M},
283 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
284     {
285      "slbm Trident",
286      20, 20, 2000, 280, 60, 8, 0, 6, 23, 0, 0,
287      0,
288      P_T | P_L | P_M},
289
290 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
291     {
292      "asat anti-sat",
293      20, 20, 2000, 305, 50, 6, 0, 7, 13, 0, 4,
294      0,
295      P_O | P_M},
296
297 /* name          lcm hcm   $$$  tch acc ld  at/df  ran mil gas stlth  flags */
298     {
299      "abm  Patriot",
300      16, 8, 1500, 270, 50, 0, 0, 31, 12, 0, 0,
301      0,
302      P_N | P_M},
303     {
304      "", 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
305      0,
306      0}
307 };
308
309 int pln_maxno = (sizeof(plchr) / sizeof(struct plchrstr)) - 1;