]> git.pond.sub.org Git - empserver/blob - src/lib/global/symbol.c
Remove option TREATIES
[empserver] / src / lib / global / symbol.c
1 /*
2  *  Empire - A multi-player, client/server Internet based war game.
3  *  Copyright (C) 1986-2014, Dave Pare, Jeff Bailey, Thomas Ruschak,
4  *                Ken Stevens, Steve McClure, Markus Armbruster
5  *
6  *  Empire 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 3 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, see <http://www.gnu.org/licenses/>.
18  *
19  *  ---
20  *
21  *  See files README, COPYING and CREDITS in the root of the source
22  *  tree for related information and legal notices.  It is expected
23  *  that future projects/authors will amend these files as needed.
24  *
25  *  ---
26  *
27  *  symbol.c: Empire symbol tables
28  *
29  *  Known contributors to this file:
30  *     Markus Armbruster, 2006-2010
31  */
32
33 #include <config.h>
34
35 #include "land.h"
36 #include "misc.h"
37 #include "mission.h"
38 #include "nat.h"
39 #include "news.h"
40 #include "nsc.h"
41 #include "nuke.h"
42 #include "plague.h"
43 #include "plane.h"
44 #include "retreat.h"
45 #include "sect.h"
46 #include "ship.h"
47
48 struct symbol agreement_statuses[] = {
49     {AGREE_FREE, "free"},
50     {AGREE_PROPOSED, "proposed"},
51     {AGREE_SIGNED, "signed"},
52     {0, NULL}
53 };
54
55 struct symbol land_chr_flags[] = {
56     {L_ENGINEER, "engineer"},
57     {L_SUPPLY, "supply"},
58     {L_SECURITY, "security"},
59     {L_LIGHT, "light"},
60     {L_MARINE, "marine"},
61     {L_RECON, "recon"},
62     {L_RADAR, "radar"},
63     {L_ASSAULT, "assault"},
64     {L_FLAK, "flak"},
65     {L_SPY, "spy"},
66     {L_TRAIN, "train"},
67     {L_HEAVY, "heavy"},
68     {0, NULL}
69 };
70
71 struct symbol level[] = {
72     {-1, "none"},
73     {NAT_TLEV, "technology"},
74     {NAT_RLEV, "research"},
75     {NAT_ELEV, "education"},
76     {NAT_HLEV, "happiness"},
77     {0, NULL}
78 };
79
80 struct symbol meta_flags[] = {
81     {NSC_DEITY, "deity"},
82     {NSC_EXTRA, "extra"},
83     {NSC_CONST, "const"},
84     {NSC_BITS, "bits"},
85     {0, NULL}
86 };
87
88 struct symbol meta_type[] = {
89     {NSC_LONG, "d"},
90     {NSC_DOUBLE, "g"},
91     {NSC_STRING, "s"},
92     {NSC_CHAR, "d"},
93     {NSC_UCHAR, "d"},
94     {NSC_SHORT, "d"},
95     {NSC_USHORT, "d"},
96     {NSC_INT, "d"},
97     {NSC_XCOORD, "d"},
98     {NSC_YCOORD, "d"},
99     {NSC_HIDDEN, "d"},
100     {NSC_TIME, "d"},
101     {NSC_FLOAT, "g"},
102     {NSC_STRINGY, "c"},
103     {NSC_NOTYPE, NULL}
104 };
105
106 struct symbol missions[] = {
107     {MI_NONE, "none"},
108     {MI_INTERDICT, "interdiction"},
109     {MI_SUPPORT, "support"},
110     {MI_RESERVE, "reserve"},
111     {MI_ESCORT, "escort"},
112     {MI_AIR_DEFENSE, "air defense"},
113     {MI_DSUPPORT, "defensive support"},
114     {MI_OSUPPORT, "offensive support"},
115     {0, NULL}
116 };
117
118 struct symbol nation_flags[] = {
119     {NF_INFORM, "inform"},
120     {NF_FLASH, "flash"},
121     {NF_BEEP, "beep"},
122     {NF_COASTWATCH, "coastwatch"},
123     {NF_SONAR, "sonar"},
124     {NF_TECHLISTS, "techlists"},
125     {NF_SACKED, "sacked"},
126     {0, NULL}
127 };
128
129 struct symbol nation_rejects[] = {
130     {REJ_TELE, "telegrams"},
131     {REJ_ANNO, "announcements"},
132     {REJ_LOAN, "loans"},
133     {0, NULL}
134 };
135
136 struct symbol nation_relations[] = {
137     {-1, "unknown"},
138     {AT_WAR, "at-war"},
139     {HOSTILE, "hostile"},
140     {NEUTRAL, "neutral"},
141     {FRIENDLY, "friendly"},
142     {ALLIED, "allied"},
143     {0, NULL}
144 };
145
146 struct symbol nation_status[] = {
147     {STAT_UNUSED, "unused"},
148     {STAT_NEW, "new"},
149     {STAT_VIS, "visitor"},
150     {STAT_SANCT, "sanctuary"},
151     {STAT_ACTIVE, "active"},
152     {STAT_GOD, "deity"},
153     {0, NULL}
154 };
155
156 struct symbol nuke_chr_flags[] = {
157     {N_NEUT, "neutron"},
158     {0, NULL}
159 };
160
161 struct symbol packing[] = {
162     {IPKG, "inefficient"},
163     {NPKG, "normal"},
164     {WPKG, "warehouse"},
165     {UPKG, "urban"},
166     {BPKG, "bank"},
167     {0, NULL}
168 };
169
170 struct symbol page_headings[] = {
171     {N_NOTUSED, "Comics"},
172     {N_FOR, "Foreign Affairs"},
173     {N_FRONT, "The Front Line"},
174     {N_SEA, "The High Seas"},
175     {N_SKY, "Sky Watch"},
176     {N_MISS, "Guidance Systems"},
177     {N_ARTY, "Firestorms"},
178     {N_ECON, "Business & Economics"},
179     {N_COLONY, "The Frontier"},
180     {N_HOME, "The Home Front"},
181     {N_SPY, "Espionage"},
182     {N_TELE, "Telecommunications"},
183     {0, NULL}
184 };
185
186 struct symbol plague_stages[] = {
187     {PLG_HEALTHY, "healthy"},
188     {PLG_DYING, "dying"},
189     {PLG_INFECT, "infect"},
190     {PLG_INCUBATE, "incubate"},
191     {PLG_EXPOSED, "exposed"},
192     {0, NULL}
193 };
194
195 struct symbol plane_chr_flags[] = {
196     {P_T, "tactical"},
197     {P_B, "bomber"},
198     {P_F, "intercept"},
199     {P_C, "cargo"},
200     {P_V, "VTOL"},
201     {P_M, "missile"},
202     {P_L, "light"},
203     {P_S, "spy"},
204     {P_I, "image"},
205     {P_O, "satellite"},
206     {P_N, "SDI"},
207     {P_E, "x-light"},
208     {P_K, "helo"},
209     {P_A, "ASW"},
210     {P_P, "para"},
211     {P_ESC, "escort"},
212     {P_MINE, "mine"},
213     {P_SWEEP, "sweep"},
214     {P_MAR, "marine"},
215     {0, NULL}
216 };
217
218 struct symbol plane_flags[] = {
219     {PLN_LAUNCHED, "launched"},
220     {PLN_SYNCHRONOUS, "synchronous"},
221     {PLN_AIRBURST, "airburst"},
222     {0, NULL}
223 };
224
225 struct symbol resources[] = {
226     /* names should match resource selector names in sect_ca[] */
227     {0, "none"},
228     {offsetof(struct sctstr, sct_min), "min"},
229     {offsetof(struct sctstr, sct_gmin), "gold"},
230     {offsetof(struct sctstr, sct_fertil), "fert"},
231     {offsetof(struct sctstr, sct_oil), "ocontent"},
232     {offsetof(struct sctstr, sct_uran), "uran"},
233     {0, NULL}
234 };
235
236 struct symbol retreat_flags[] = {
237     {RET_GROUP, "group"},
238     {RET_INJURED, "injured"},
239     {RET_TORPED, "torped"},
240     {RET_SONARED, "sonared"},
241     {RET_HELPLESS, "helpless"},
242     {RET_BOMBED, "bombed"},
243     {RET_DCHRGED, "depth-charged"},
244     {RET_BOARDED, "boarded"},
245     {0, NULL}
246 };
247
248 struct symbol sector_navigation[] = {
249     {NAV_NONE, "land"},
250     {NAVOK, "sea"},
251     {NAV_02, "harbor"},
252     {NAV_CANAL, "canal"},
253     {NAV_60, "bridge"},
254     {0, NULL}
255 };
256
257 struct symbol ship_chr_flags[] = {
258     {M_FOOD, "fish"},
259     {M_TORP, "torp"},
260     {M_DCH, "dchrg"},
261     {M_FLY, "plane"},
262     {M_MSL, "miss"},
263     {M_OIL, "oil"},
264     {M_SONAR, "sonar"},
265     {M_MINE, "mine"},
266     {M_SWEEP, "sweep"},
267     {M_SUB, "sub"},
268     {M_LAND, "land"},
269     {M_SUBT, "sub-torp"},
270     {M_TRADE, "trade"},
271     {M_SEMILAND, "semi-land"},
272     {M_SUPPLY, "supply"},
273     {M_CANAL, "canal"},
274     {M_ANTIMISSILE, "anti-missile"},
275     {0, NULL}
276 };