Mercurial > ~darius > hgwebdir.cgi > paradise_client
comparison data.h @ 1:ff5e05767bd3 ALPHA
Empty changelog
author | darius |
---|---|
date | Sat, 06 Dec 1997 05:41:28 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
0:d17661b1e221 | 1:ff5e05767bd3 |
---|---|
1 /* $Id: data.h,v 1.1.1.1 1997/12/06 05:41:28 darius Exp $ */ | |
2 | |
3 /* | |
4 * data.h | |
5 */ | |
6 | |
7 #ifndef data_h_ | |
8 #define data_h_ | |
9 | |
10 #include "copyright.h" | |
11 #include "struct.h" | |
12 #include <stdio.h> /* for def of file */ | |
13 #ifdef hpux | |
14 #include <time.h> | |
15 #else | |
16 #include <sys/time.h> | |
17 #endif | |
18 | |
19 #define EX_FRAMES 5 | |
20 #define SBEXPVIEWS 7 | |
21 #define NUMDETFRAMES 5 /* # frames in torp explosion */ | |
22 #define ex_width 64 | |
23 #define ex_height 64 | |
24 #define sbexp_width 80 | |
25 #define sbexp_height 80 | |
26 #define cloud_width 9 | |
27 #define cloud_height 9 | |
28 #define plasmacloud_width 13 | |
29 #define plasmacloud_height 13 | |
30 #define etorp_width 3 | |
31 #define etorp_height 3 | |
32 #define NDRONEVIEWS 16 /* dependent on oldbitmaps.h */ | |
33 #define drone_width 6 | |
34 #define drone_height 6 | |
35 #define fighter_width 5 | |
36 #define fighter_height 5 | |
37 #define warpbeacon_width 8 | |
38 #define warpbeacon_height 12 | |
39 #define eplasmatorp_width 7 | |
40 #define eplasmatorp_height 7 | |
41 #define mplasmatorp_width 5 | |
42 #define mplasmatorp_height 5 | |
43 #define mtorp_width 3 | |
44 #define mtorp_height 3 | |
45 #define crossmask_width 16 | |
46 #define crossmask_height 16 | |
47 #define planet_width 30 | |
48 #define planet_height 30 | |
49 #define wormhole_width 80 | |
50 #define wormhole_height 80 | |
51 #define terrain_width 20 | |
52 #define terrain_height 20 | |
53 #define mplanet_width 16 | |
54 #define mplanet_height 16 | |
55 #define cloak_width 20 | |
56 #define cloak_height 20 | |
57 | |
58 extern int paradise; /* is the server a paradise server? */ | |
59 #ifdef HOCKEY | |
60 extern int hockey; /* is the server a hockey server [BDyess] */ | |
61 #endif /*HOCKEY*/ | |
62 | |
63 extern int nplayers; | |
64 extern int nshiptypes; | |
65 extern int ntorps; | |
66 extern int npthingies; | |
67 extern int ngthingies; | |
68 extern int nplasmas; | |
69 extern int nphasers; | |
70 extern int nplanets; | |
71 | |
72 #ifdef HOCKEY | |
73 /* hockey stuff [BDyess] */ | |
74 extern int galacticHockeyLines; /* draw lines on the galactic? [BDyess] */ | |
75 extern int tacticalHockeyLines; /* draw lines on the tactical? [BDyess] */ | |
76 extern int cleanHockeyGalactic; /* don't draw planets on the galactic when | |
77 playing hockey [BDyess] */ | |
78 extern int teamColorHockeyLines; /* color hockey lines by team [BDyess] */ | |
79 extern struct hockeyLine hlines[NUM_HOCKEY_LINES]; | |
80 #endif /*HOCKEY*/ | |
81 | |
82 extern int metaFork; /* allow spawning off of clients from meta- | |
83 server window [BDyess] */ | |
84 extern int viewBox; /* flag for viewBox [BDyess] */ | |
85 extern int allowViewBox; /* allow flag for viewBox [BDyess] */ | |
86 | |
87 extern int sectorNums; /* flag for numbered sectors in galactic -TH */ | |
88 extern int lockLine; /* for line from me to lock in galac -TH */ | |
89 extern int mapSort; /* use new sorting in galactic -TH */ | |
90 extern int autoSetWar; /* automatically set war dec's -TH */ | |
91 extern int tacPlanetInfo; /* info on local planets; see data.c -TH */ | |
92 | |
93 #ifdef WIDE_PLIST | |
94 extern char *playerList; /* string of fields for wide playerlist */ | |
95 extern char *playerListStart; /* comma seperated set of strings for plist */ | |
96 extern int resizePlayerList; | |
97 #endif /* WIDE_PLIST */ | |
98 | |
99 #ifdef PACKET_LIGHTS | |
100 extern int packetLights; /* flag for packetLights [BDyess] */ | |
101 #endif /* PACKET_LIGHTS */ | |
102 | |
103 /* for showgalactic and showlocal rotation sequence [BDyess] */ | |
104 extern char *showGalacticSequence, *showLocalSequence; | |
105 | |
106 /* Lynx wants the playerlist blanked upon entry. Ok, whatever [BDyess] */ | |
107 extern int allowPlayerlist; | |
108 | |
109 /* message window array [BDyess] */ | |
110 extern struct messageWin messWin[]; | |
111 | |
112 /* global counters for number of queued messages [BDyess] */ | |
113 extern int me_messages, all_messages, team_messages; | |
114 | |
115 /* added 1/94 -JR */ | |
116 extern int niftyNewMessages; | |
117 | |
118 /* needed for rc_distress [BDyess] */ | |
119 extern int F_gen_distress; | |
120 | |
121 extern struct dmacro_list *distmacro; | |
122 extern struct dmacro_list dist_defaults[]; | |
123 extern struct dmacro_list dist_prefered[]; | |
124 extern int sizedist; | |
125 | |
126 #ifdef BEEPLITE | |
127 extern int F_allow_beeplite; | |
128 extern unsigned char F_beeplite_flags; | |
129 | |
130 extern char *distlite[]; | |
131 extern int UseLite; | |
132 extern int DefLite; | |
133 extern int emph_planet_seq_n[]; | |
134 extern int emph_player_seq_n[]; | |
135 extern W_Icon emph_planet_seq[]; | |
136 extern W_Icon emph_player_seq[]; | |
137 extern W_Icon emph_player_seql[]; | |
138 extern W_Color emph_planet_color[MAX_PLANETS]; | |
139 extern W_Color emph_player_color[MAX_PLAYER]; | |
140 #define emph_planet_seq_frames 5 | |
141 #define emph_planet_seq_width 24 | |
142 #define emph_planet_seq_height 24 | |
143 #define emph_player_seq_frames 3 | |
144 #define emph_player_seq_width 24 | |
145 #define emph_player_seq_height 24 | |
146 #define emph_player_seql_frames 3 | |
147 #define emph_player_seql_width 30 | |
148 #define emph_player_seql_height 30 | |
149 extern int beep_lite_cycle_time_player; | |
150 extern int beep_lite_cycle_time_planet; | |
151 #endif /* BEEPLITE */ | |
152 | |
153 /* time client connected to server [BDyess] */ | |
154 extern time_t timeStart; | |
155 | |
156 #ifdef TIMER | |
157 /* timer data */ | |
158 extern int timerType; | |
159 extern time_t timeBank[]; | |
160 #endif /* TIMER */ | |
161 | |
162 #ifdef MACROS | |
163 extern struct macro *macrotable[256]; | |
164 extern int macroState; | |
165 extern char lastMessage[100]; | |
166 #endif /* MACROS */ | |
167 | |
168 /* ghoststart data */ | |
169 extern int ghoststart; | |
170 extern int ghost_pno; | |
171 | |
172 /* defaults list */ | |
173 extern struct stringlist *defaults; | |
174 | |
175 /* upgrade kludge flag [BDyess] */ | |
176 extern int upgrading; | |
177 | |
178 /* continuousmouse kludge [BDyess] */ | |
179 extern int exitInputLoop; | |
180 | |
181 /* clearzone data */ | |
182 extern int czsize; | |
183 extern struct _clearzone *clearzone; | |
184 extern int clearcount; | |
185 #ifdef HOCKEY | |
186 extern int clearline[4][32 + 2 * 32 + NUM_HOCKEY_LINES]; | |
187 #else | |
188 extern int clearline[4][32 + 2 * 32]; | |
189 #endif /*HOCKEY*/ | |
190 extern int clearlmark[2]; | |
191 extern int clearlmcount; | |
192 extern int clearlcount; | |
193 extern int mclearzone[6][32]; /* for map window */ | |
194 | |
195 extern struct player *players; | |
196 extern struct player *me; | |
197 extern struct torp *torps; | |
198 extern struct thingy *thingies; | |
199 extern struct plasmatorp *plasmatorps; | |
200 extern struct status *status; | |
201 extern struct status2 *status2; | |
202 extern struct ship *myship; | |
203 extern struct shiplist *shiptypes; | |
204 extern struct stats *mystats; | |
205 extern struct planet *planets; | |
206 extern struct t_unit *terrainInfo; | |
207 extern int received_terrain_info; | |
208 extern int terrain_x; | |
209 extern int terrain_y; | |
210 extern struct phaser *phasers; | |
211 extern struct team *teams; | |
212 extern struct planet pdata[]; | |
213 | |
214 extern int logPhaserMissed; /* log or not 'phaser missed' messages | |
215 [BDyess] */ | |
216 extern int phaserStats; /* Phaser statistics on or off -JR */ | |
217 extern int phasFired, phasHits, totalDmg; /* the stats */ | |
218 | |
219 extern int infoIcon; /* information icon flag [BDyess] */ | |
220 extern int iconified; /* iconified or not flag [BDyess] */ | |
221 extern char *defaultsFile; | |
222 extern short *slot; | |
223 extern char *defNickName; | |
224 extern char *defFlavor; | |
225 extern int oldalert; | |
226 /*extern int remap[];*/ | |
227 extern int udcounter; | |
228 extern char *title; | |
229 extern char *cloakchars; /* characters used for cloakers, defaults to | |
230 ?? */ | |
231 extern int cloakcharslen; | |
232 extern struct plupdate pl_update[]; | |
233 extern int currentship; | |
234 extern int messpend; | |
235 extern int lastcount; | |
236 extern int mdisplayed; | |
237 extern int redrawall; | |
238 extern int nopilot; | |
239 extern int watch; | |
240 extern int selfdest; | |
241 extern int lastm; | |
242 extern int delay; | |
243 extern int rdelay; | |
244 extern int mapmode; | |
245 extern int namemode; | |
246 extern int showShields; | |
247 extern int showStats; | |
248 #ifdef ATM | |
249 extern int msgBeep; /* ATM - msg beep */ | |
250 #endif /* ATM */ | |
251 extern int warncount; | |
252 extern int warntimer; | |
253 extern int infomapped; | |
254 extern void *infothing; /* infow contents [BDyess] */ | |
255 extern int infoupdate; /* update flag for infow [BDyess] */ | |
256 extern int infotype; /* type of info thing [BDyess] */ | |
257 extern int keepInfo; /* .xtrekrc setting */ | |
258 extern int infowin_up; /* how long should it remain up? */ | |
259 #ifdef ATM | |
260 extern int scanmapped; /* ATM - scanner stuff */ | |
261 #endif /* ATM */ | |
262 extern int mustexit; | |
263 extern int messtime; | |
264 extern int keeppeace; | |
265 extern int drawgrid; | |
266 | |
267 /* playerlist settings */ | |
268 extern int sortPlayers; | |
269 extern int hideNoKills; | |
270 extern int showDead; | |
271 extern int showPreLogins; | |
272 extern int sortOutfitting; | |
273 extern int robsort; | |
274 | |
275 /* dashboard settings */ | |
276 extern int Dashboard; | |
277 extern int newDashboard; | |
278 extern int cup_half_full; | |
279 | |
280 extern int logmess; | |
281 extern char *logFile; | |
282 extern FILE *logfilehandle; | |
283 extern int showPhaser; | |
284 extern int vary_hull; | |
285 extern int warpStreaks; | |
286 extern int fastQuit; | |
287 extern int pigSelf; | |
288 #ifdef CONTINUOUS_MOUSE | |
289 extern int continuousMouse; | |
290 extern int allowContinuousMouse; | |
291 extern int clickDelay; | |
292 /* turns on and off continuousMouse for each button [BDyess] */ | |
293 extern int buttonRepeatMask; | |
294 #endif /* CONTINUOUS_MOUSE */ | |
295 extern int autoQuit; | |
296 | |
297 #ifdef GATEWAY | |
298 extern unsigned long netaddr; /* for blessing */ | |
299 #endif | |
300 | |
301 #ifdef NOWARP | |
302 extern int messageon; | |
303 #endif | |
304 | |
305 extern char blk_refitstring[80]; | |
306 extern int blk_gwidth; | |
307 extern float blk_windgwidth; | |
308 /*extern int blk_altbits;*/ | |
309 extern int showKitchenSink; | |
310 extern int blk_showStars; | |
311 extern int blk_bozolist; | |
312 extern int blk_friendlycloak; | |
313 | |
314 extern int forceMono; | |
315 | |
316 extern int showlocal, showgalactic; | |
317 extern int sendmotdbitmaps; | |
318 extern char *shipnos; | |
319 extern int sock; | |
320 extern int xtrekPort; | |
321 extern int queuePos; | |
322 extern int pickOk; | |
323 extern int lastRank; | |
324 extern int promoted; | |
325 extern int loginAccept; | |
326 extern unsigned localflags; | |
327 extern int tournMask; | |
328 extern int nextSocket; | |
329 extern int updatePlayer[]; | |
330 extern char *serverName; | |
331 extern int loggedIn; | |
332 extern int reinitPlanets; | |
333 extern int redrawPlayer[]; | |
334 extern int lastUpdate[]; | |
335 extern int timerDelay; | |
336 extern int reportKills; | |
337 extern char *unixSoundPath; | |
338 extern char *unixSoundDev; | |
339 extern int playSounds; | |
340 | |
341 #ifdef ATM | |
342 extern int scanplayer; | |
343 extern int showTractor; | |
344 extern int commMode; /* UDP */ | |
345 extern int commModeReq; /* UDP */ | |
346 extern int commStatus; /* UDP */ | |
347 extern int commSwitchTimeout; /* UDP */ | |
348 extern int udpTotal; /* UDP */ | |
349 extern int udpDropped; /* UDP */ | |
350 extern int udpRecentDropped; /* UDP */ | |
351 extern int udpSock; /* UDP */ | |
352 extern int udpDebug; /* UDP */ | |
353 extern int udpClientSend; /* UDP */ | |
354 extern int udpClientRecv; /* UDP */ | |
355 extern int udpSequenceChk; /* UDP */ | |
356 extern int updateSpeed; | |
357 | |
358 #ifdef METASERVER | |
359 /* metaserver window stuff */ | |
360 extern int usemeta; | |
361 extern char *metaserverAddress; | |
362 #endif /* METASERVER */ | |
363 | |
364 /* MOTD data */ | |
365 extern struct page *currpage; | |
366 extern struct page *motddata; | |
367 | |
368 #ifdef GATEWAY | |
369 extern int gw_serv_port, gw_port, gw_local_port; /* UDP */ | |
370 extern char *gw_mach; /* UDP */ | |
371 #endif | |
372 #endif /* ATM */ | |
373 | |
374 extern int showMySpeed; | |
375 extern int showTractorPressor; | |
376 extern int showAllTractorPressor; | |
377 extern int allowShowAllTractorPressor; | |
378 extern int showLock; | |
379 extern int autoKey; | |
380 extern int extraBorder; | |
381 #ifdef ATM | |
382 /* udp options */ | |
383 extern int tryUdp; | |
384 #endif /* ATM */ | |
385 | |
386 | |
387 extern double Sin[], *Cos; | |
388 | |
389 extern W_Icon stipple, clockpic, icon; | |
390 /*extern W_Icon teamicon[4];*/ | |
391 | |
392 #define VIEWS 16 | |
393 extern W_Icon expview[EX_FRAMES]; | |
394 extern W_Icon sbexpview[SBEXPVIEWS]; | |
395 extern W_Icon cloud[NUMDETFRAMES]; | |
396 extern W_Icon plasmacloud[NUMDETFRAMES]; | |
397 extern W_Icon etorp, mtorp; | |
398 extern W_Icon drone_bm[16]; | |
399 extern W_Icon eplasmatorp, mplasmatorp, fighter[VIEWS]; | |
400 extern W_Icon warpbeacon, wbflash; | |
401 extern W_Icon hull[8]; | |
402 | |
403 extern W_Icon cloakicon; | |
404 | |
405 #ifdef ATM | |
406 extern W_Icon tractbits, pressbits; | |
407 #endif /* ATM */ | |
408 | |
409 #define NEW_SHIP_BM | |
410 | |
411 struct ship_shape *shape_of_ship( /* team, class */ ); | |
412 | |
413 /**************************/ | |
414 /* stellar object bitmaps */ | |
415 /* | |
416 b tactical owner | |
417 mb galactic owner | |
418 b2 tactical resources | |
419 mb2 galactic resources | |
420 */ | |
421 | |
422 #define STARFRAMES 10 | |
423 #define WORMFRAMES 8 | |
424 | |
425 extern W_Icon starBM[STARFRAMES], mstarBM; | |
426 extern W_Icon wormBM[WORMFRAMES]; | |
427 extern W_Icon mholeBM; /* wormhole galactic bitmap [BDyess] */ | |
428 | |
429 extern W_Icon bplanets[6]; /* TS "show owner" mode bitmaps */ | |
430 extern W_Icon mbplanets[6]; /* GS "show owner" mode bitmaps */ | |
431 extern W_Icon bplanets2[16]; /* TS "show facilities" mode bitmaps */ | |
432 extern W_Icon mbplanets2[16]; /* GS "show facilities" mode bitmaps */ | |
433 extern W_Icon bplanetsr[8]; /* TS "show resources" mode bitmaps */ | |
434 extern W_Icon mbplanetsr[8]; /* GS "show resources" mode bitmaps */ | |
435 extern W_Icon bplanetsMOO[16]; /* TS MOO-style bitmaps */ | |
436 extern W_Icon mbplanetsMOO[16]; /* GS MOO-style bitmaps */ | |
437 #define NSCOUTAGES 5 | |
438 extern W_Icon mbplanetsA[NSCOUTAGES]; /* GS "show age" mode bitmaps */ | |
439 | |
440 extern W_Icon basteroid[6]; | |
441 extern W_Icon mbasteroid[6]; | |
442 extern W_Icon basteroid2[2]; | |
443 extern W_Icon mbasteroid2[2]; | |
444 extern W_Icon asteroidBM[16]; | |
445 extern W_Icon asteroidfluff[3]; /* for "smoothness" */ | |
446 | |
447 extern W_Icon kitchenSink; | |
448 | |
449 extern W_Color borderColor, backColor, textColor, myColor, warningColor, shipCol[6], | |
450 rColor, yColor, gColor, unColor, foreColor; | |
451 | |
452 /*extern char teamletdata[]; | |
453 extern char *teamshortdata[];*/ | |
454 extern char pseudo[PSEUDOSIZE]; | |
455 extern char defpasswd[PSEUDOSIZE]; | |
456 extern char login[PSEUDOSIZE]; | |
457 | |
458 extern struct rank ranks[NUMRANKS]; | |
459 extern struct rank2 *ranks2; | |
460 extern struct royalty *royal; | |
461 extern int nranks2; | |
462 extern int nroyals; | |
463 | |
464 extern W_Window messagew, w, mapw, statwin, baseWin, infow, iconWin, tstatw, war, | |
465 warnw, helpWin, teamWin[4], qwin, /* messwa, messwt, messwi, | |
466 messwk, */ planetw, planetw2, rankw, playerw, optionWin, /* reviewWin, phaserwin, */ metaWin, | |
467 macroWin, defWin, motdWin; | |
468 #ifdef ATM | |
469 extern W_Window scanw, scanwin, udpWin; | |
470 #endif /* ATM */ | |
471 | |
472 #ifdef SHORT_PACKETS | |
473 extern W_Window spWin; | |
474 #endif | |
475 | |
476 #ifdef TOOLS | |
477 extern W_Window toolsWin; | |
478 extern int shelltools; | |
479 | |
480 #endif | |
481 | |
482 #ifdef SOUND | |
483 extern W_Window soundWin; | |
484 #endif | |
485 | |
486 #ifdef ROTATERACE | |
487 extern int rotate; | |
488 extern int rotate_deg; | |
489 #endif | |
490 | |
491 #ifdef NOWARP | |
492 extern int messageon; | |
493 extern int warp; | |
494 #endif | |
495 | |
496 extern int RSA_Client; | |
497 extern int blk_zoom; | |
498 extern int autoZoom, autoUnZoom, auto_zoom_timer, autoZoomOverride; | |
499 | |
500 extern int use_msgw; | |
501 | |
502 extern int show_shield_dam; | |
503 extern int bd; /* BORG TEST */ | |
504 | |
505 | |
506 #ifdef SHORT_PACKETS | |
507 extern int tryShort; | |
508 extern int recv_short; | |
509 extern int recv_mesg; | |
510 extern int recv_kmesg; | |
511 extern int recv_threshold; | |
512 extern char recv_threshold_s[]; | |
513 extern int recv_warn; | |
514 extern int godToAllOnKills; | |
515 #endif | |
516 | |
517 /* ping client stuff, ick */ | |
518 extern int ping; /* to ping or not to ping */ | |
519 extern long packets_sent; /* # all packets sent to server */ | |
520 extern long packets_received; /* # all packets received */ | |
521 extern W_Window pStats; | |
522 | |
523 extern int lowercaset; | |
524 | |
525 extern char *agriWord; | |
526 | |
527 #ifdef DNET | |
528 extern unsigned long sigsPending, sockMask, udpSockMask; | |
529 #endif | |
530 | |
531 #ifdef FEATURE | |
532 extern int F_feature_packets; | |
533 extern int why_dead; | |
534 extern int cloakerMaxWarp; | |
535 extern int F_dead_warp; | |
536 extern int F_multiline_enabled; | |
537 extern int F_UseNewMacro; | |
538 extern int F_terrain; | |
539 extern unsigned char F_terrain_major; | |
540 extern unsigned char F_terrain_minor; | |
541 extern int F_gz_motd; | |
542 extern unsigned char F_gz_motd_major; | |
543 extern unsigned char F_gz_motd_minor; | |
544 #endif | |
545 | |
546 #ifdef CHECK_DROPPED | |
547 extern int reportDroppedPackets;/* report on various dropped packet kludges */ | |
548 extern int longest_ph_fuse; | |
549 #endif | |
550 | |
551 #ifdef UPDATE_SIZES | |
552 extern int totalbytes; | |
553 extern int updatebytes, alivebytes; | |
554 extern int peakbytes; | |
555 extern int packetbytes[100]; | |
556 #endif | |
557 | |
558 extern int askforUpdate; | |
559 | |
560 extern int jubileePhasers; | |
561 | |
562 extern int scrollBeep; | |
563 | |
564 #ifdef RECORDER | |
565 extern int recordGame; | |
566 extern char *recordFile; | |
567 extern int maxRecord; | |
568 | |
569 extern int playback; | |
570 extern char *playFile; | |
571 extern int pb_update, paused, pb_advance, pb_scan, pb_slow; | |
572 #endif | |
573 | |
574 #ifdef COW_HAS_IT_WHY_SHOULDNT_WE | |
575 extern int showMapAtMotd; | |
576 #endif | |
577 | |
578 extern int redrawDelay; | |
579 | |
580 #ifdef LOCAL_SHIPSTATS | |
581 extern int localShipStats; | |
582 extern char *statString; | |
583 extern int statHeight, localStatsX, localStatsY; | |
584 #endif | |
585 | |
586 #ifdef SHOW_IND | |
587 extern int showIND; | |
588 #endif | |
589 | |
590 /* char[] containing the client version */ | |
591 | |
592 extern char CLIENTVERS[]; | |
593 #endif |