home *** CD-ROM | disk | FTP | other *** search
/ Dream 52 / Amiga_Dream_52.iso / Linux / Divers / xgalaga-2_0_tar.gz / xgalaga-2_0_tar / xgalaga-2.0 / mkimgsrc < prev    next >
C/C++ Source or Header  |  1998-04-12  |  27KB  |  640 lines

  1. #!/usr/local/bin/perl
  2. #
  3. # creates images.c and images.h.  Takes the imagedir as a parameter.
  4. #
  5. # Bill Dyess, 10/5/94
  6. #
  7. # Bill Dyess, 2/11/95
  8. #  - Now always compiles in default.x[pb]m.
  9. #  - Compiles in all image files if -c given as a parameter.
  10. #
  11. require "find.pl";
  12.  
  13. $path = $ARGV[0];
  14. if ($path eq "-c") {
  15.   $compile_in = 1;
  16.   $path = $ARGV[1];
  17. } else {
  18.   $compile_in = 0;
  19. }
  20.  
  21. die "Usage: $0 [-c] <imagedir>\n  -c    Compile in all images.\n" unless $path;
  22.  
  23. &find($path);
  24.  
  25. &init_lookup();
  26.  
  27. open(C,">images.c") || die "can't open images.c: $!";
  28. open(H,">images.h") || die "can't open images.h: $!";
  29. open(SCRIPT_IN,"$0") || die "can't open $0: $!";
  30. open(SCRIPT_OUT,">$0.out") || die "can't open $0.out: $!";
  31. while(<SCRIPT_IN>) { 
  32.   print SCRIPT_OUT; 
  33.   last if /^  %lookup = \(/; 
  34. }
  35. close(SCRIPT_IN);
  36.  
  37. $help = "/* {width,height,frames,xpm,filename,loaded,alternate,bad,compiled_in,xbmdata,xpmdata,pixmap,clipmask} */\n";
  38.  
  39. print C <<EOF;
  40. /* images.c.  Contains the image control data. [BDyess] */
  41. /* automatically created by scripts/mkimgsrc */
  42.  
  43. #include <stdlib.h>
  44. #include "Wlib.h"
  45. #include "images.h"
  46. #include "struct.h"
  47. #include "proto.h"
  48.  
  49. /* compiled in images in alphabetical order, XBM before XPM. [BDyess] */
  50. EOF
  51.  
  52. # sort the filelist
  53. @filelist = sort keys %table;
  54.  
  55. # copy in all the xbm and xpm data if $compile_in is set, otherwise just
  56. # the data for the default image.
  57. chdir($path) || die "can't chdir() to $path: $!";
  58. if($compile_in) {
  59.   for $file (@filelist) {
  60.     &include_bitmap($file);
  61.     &include_pixmap($file);
  62.   }
  63. } else {
  64.   &include_bitmap("/default");
  65. }
  66.  
  67. # includes the given bitmap in the C source.
  68. sub include_bitmap {
  69.   local($file) = @_;
  70.   $ok = 0;
  71.   if(open(IN,".$file.xbm")) {
  72.     while(<IN>) {
  73.       if (/^#define\s*\S*_width\s*(\d*)/) {
  74.     $lookup{"${file}_width"} = $1;
  75.     next;
  76.       }
  77.       if (/^#define\s*\S*_height\s*(\d*)/) {
  78.     $lookup{"${file}_height"} = $1;
  79.     next;
  80.       }
  81.       if (/^static.*char\s\S*_bits\[\]/) {
  82.         $name = $file;
  83.     $name =~ s,^/,,;
  84.     $name =~ s,[/.],_,g;
  85.         print C "static char ${name}_bits[] = {\n";
  86.     $lookup{"${file}_xbmdata"} = "${name}_bits";
  87.     $ok = 1;
  88.     next;
  89.       }
  90.       print C;
  91.     }
  92.     print C "\n";
  93.     if($ok) {
  94.       $lookup{"${file}_compiled_in"} = 1;
  95.     } else {
  96.       print STDERR "Error parsing $file.xbm!\n";
  97.     }
  98.   }
  99. }
  100.  
  101. # includes the given pixmap in the C source.
  102. sub include_pixmap {
  103.   local($file) = @_;
  104.   $ok = 0;
  105.   if(open(IN,".$file.xpm")) {
  106.     while(<IN>) {
  107.       if (/static.*char[\s\*]*\S*\[\]/) {
  108.         $name = $file;
  109.     $name =~ s,^/,,;
  110.     $name =~ s,[/.],_,g;
  111.     s/\*\s*\S*\[\]/* ${name}_xpm\[\]/;
  112.         print C;
  113.     $lookup{"${file}_xpmdata"} = "${name}_xpm";
  114.         $ok = 1;
  115.       } else {
  116.     print C;
  117.       }
  118.     }
  119.     print C "\n";
  120.     if($ok) {
  121.       $lookup{"${file}_compiled_in"} = 1;
  122.     } else {
  123.       print STDERR "Error parsing $file.xpm!\n";
  124.     }
  125.   }
  126. }
  127.  
  128. # start of imagearray
  129. #$height = $lookup{"/default_height"};
  130. #$width = $lookup{"/default_width"};
  131. print C <<EOF;
  132. /* keep sorted (for bsearch) [BDyess] */
  133. static W_Image imagearray[] = {
  134. EOF
  135. #   {$height, $width, 1, 0, "/default", 1, I_DEFAULT, 0, 1, default_bits, default_xpm, 0, 0},
  136.  
  137.  
  138. print H <<EOF;
  139. /* images.h.  Contains the #defines and extern's for all the image management
  140.    data [BDyess] */
  141. /* automatically created by scripts/mkimgsrc */
  142.  
  143. #include "Wlib.h"
  144.  
  145. W_Image * getImage P((int offset));
  146. void loadImageByFilename P((char *filename));
  147. void loadAllImages P((void));
  148.  
  149. #define I_DEFAULT              0
  150. EOF
  151. #
  152.  
  153. $counter = 0; #1;
  154. for $file (@filelist) {
  155.   &print_lookup($file);
  156.   print C $help if ($counter % 25) == 0;
  157.   $frames = $lookup{"${file}_frames"};
  158.   $frames = 0 unless $frames;
  159.   $alternate = $lookup{"${file}_alternate"};
  160.   $alternate = "I_DEFAULT" unless $alternate;
  161.   $width = $lookup{"${file}_width"};
  162.   $width = 0 unless $width;
  163.   $height = $lookup{"${file}_height"};
  164.   $height = 0 unless $height;
  165.   $is_compiled_in = $lookup{"${file}_compiled_in"};
  166.   $is_compiled_in = 0 unless $is_compiled_in;
  167.   $xbmdata = $lookup{"${file}_xbmdata"};
  168.   $xbmdata = "NULL" unless $xbmdata;
  169.   $xpmdata = $lookup{"${file}_xpmdata"};
  170.   if($xpmdata) {
  171.     $xpmdata = "(char**)$xpmdata";
  172.   } else {
  173.     $xpmdata = "NULL" unless $xpmdata;
  174.   }
  175.   print C <<EOF;
  176.    {$width, $height, $frames, 0, "$file", 0, $alternate, 0, $is_compiled_in, $xbmdata, $xpmdata, 0, 0},
  177. EOF
  178.   $file =~ s,^/,,;
  179.   $file =~ s,[./],_,g;
  180.   $file = "\U$file";
  181.   $file =~ s/^(WEAPONS|PLANETS|INTRO)_//;
  182.   printf(H "#define I_%-20s $counter\n",$file);
  183.   $counter++;
  184. }
  185.  
  186. $counter--;
  187. printf(H "#define I_%-20s $counter\n",LAST);
  188.  
  189. print C <<EOF;
  190. };
  191.  
  192. W_Image *
  193. getImage(offset)
  194.   int offset;
  195. {
  196.   W_Image * image = &imagearray[offset];
  197.   if(!image->loaded) {
  198.     W_LoadImage(image);
  199.   }
  200.   return image;
  201. }
  202.  
  203. #ifndef __STDC__
  204. #define const
  205. #endif /*__STDC__*/
  206.  
  207. int cmpfilenames(left,right)
  208.   const void *left, *right;
  209. {
  210.   return strcmp((char*)left,((W_Image*)right)->filename);
  211. }
  212.  
  213. void
  214. loadImageByFilename(filename)
  215.   char *filename;
  216. {
  217.   W_Image *image;
  218.  
  219.   image = bsearch(filename, imagearray, sizeof(imagearray) / sizeof(W_Image),
  220.                   sizeof(W_Image), cmpfilenames);
  221.   if(image && !image->loaded) W_LoadImage(image);
  222. }
  223.  
  224. void
  225. loadAllImages()
  226. {
  227.   int i;
  228.   for(i=I_DEFAULT; i<I_LAST; i++) 
  229.     if(!imagearray[i].loaded) 
  230.       W_LoadImage(&imagearray[i]);
  231. }
  232. EOF
  233.  
  234.  
  235. close C;
  236. close H;
  237.  
  238. print SCRIPT_OUT ");\n}\n";
  239. close SCRIPT_OUT;
  240. unlink("$0.bak");
  241. rename("$0","$0.bak") || print STDERR "Error renaming $0 to $0.bak: $!";
  242. rename("$0.out","$0") || print STDERR "Error renaming $0.out to $0: $!";
  243. chmod 0755, "$0";
  244.  
  245. sub wanted {
  246.   return unless /\.x[bp]m$/;
  247.   $x = $name;
  248.   $x =~ s/^$path//;
  249.   $x =~ s/\.x[bp]m$//;
  250.   return unless -f "$_";
  251.   $table{$x} = 1;
  252. }
  253.  
  254. sub print_lookup {
  255.   local($name) = @_;
  256.   local($alternate,$frames);
  257.   print SCRIPT_OUT ",\n" if $notfirst;
  258.   $notfirst = 1;
  259.   $alternate = $lookup{"${name}_alternate"};
  260.   $alternate = 'I_DEFAULT' unless $alternate;
  261.   $frames = $lookup{"${name}_frames"};
  262.   printf(SCRIPT_OUT "%-40s \'$alternate\'","'${file}_alternate',");
  263.   printf(SCRIPT_OUT ",\n%-40s '$frames'","'${file}_frames',") if $frames;
  264. }
  265.  
  266. # lookup is a table to lookup values that are different than 0 or filename.
  267. # <path>_frames and <path>_alternate are searched for and used.
  268. #
  269. # lookup is generated automatically when mkimgsrc is run and saved to this
  270. # file.  If it's a new image, I_DEFAULT is used.
  271. sub init_lookup {
  272.   %lookup = (
  273. '/Fed.bronco/AS_alternate',              'I_DEFAULT',
  274. '/Fed.bronco/AT_alternate',              'I_DEFAULT',
  275. '/Fed.bronco/BB_alternate',              'I_DEFAULT',
  276. '/Fed.bronco/CA_alternate',              'I_DEFAULT',
  277. '/Fed.bronco/DD_alternate',              'I_DEFAULT',
  278. '/Fed.bronco/SB_alternate',              'I_DEFAULT',
  279. '/Fed.bronco/SC_alternate',              'I_DEFAULT',
  280. '/Fed/AS_alternate',                     'I_FED_CA',
  281. '/Fed/AT_alternate',                     'I_IND_AT',
  282. '/Fed/BB_alternate',                     'I_FED_CA',
  283. '/Fed/CA_alternate',                     'I_DEFAULT',
  284. '/Fed/CL_alternate',                     'I_FED_CA',
  285. '/Fed/CV_alternate',                     'I_FED_CA',
  286. '/Fed/DD_alternate',                     'I_FED_CA',
  287. '/Fed/FR_alternate',                     'I_FED_CA',
  288. '/Fed/JS_alternate',                     'I_FED_SB',
  289. '/Fed/PT_alternate',                     'I_FED_CA',
  290. '/Fed/PU_alternate',                     'I_IND_PT',
  291. '/Fed/SB_alternate',                     'I_DEFAULT',
  292. '/Fed/SC_alternate',                     'I_FED_CA',
  293. '/Fed/UT_alternate',                     'I_FED_CA',
  294. '/Fed/WB_alternate',                     'I_FED_SB',
  295. '/Ind/AS_alternate',                     'I_FED_CA',
  296. '/Ind/AT_alternate',                     'I_FED_SB',
  297. '/Ind/BB_alternate',                     'I_FED_CA',
  298. '/Ind/CA_alternate',                     'I_FED_CA',
  299. '/Ind/CL_alternate',                     'I_FED_CA',
  300. '/Ind/CV_alternate',                     'I_FED_CA',
  301. '/Ind/DD_alternate',                     'I_FED_CA',
  302. '/Ind/FR_alternate',                     'I_FED_CA',
  303. '/Ind/JS_alternate',                     'I_FED_JS',
  304. '/Ind/PT_alternate',                     'I_FED_CA',
  305. '/Ind/PU_alternate',                     'I_FED_SB',
  306. '/Ind/SB_alternate',                     'I_FED_SB',
  307. '/Ind/SC_alternate',                     'I_FED_CA',
  308. '/Ind/UT_alternate',                     'I_FED_CA',
  309. '/Ind/WB_alternate',                     'I_FED_SB',
  310. '/Kli.bronco/AS_alternate',              'I_DEFAULT',
  311. '/Kli.bronco/AT_alternate',              'I_DEFAULT',
  312. '/Kli.bronco/BB_alternate',              'I_DEFAULT',
  313. '/Kli.bronco/CA_alternate',              'I_DEFAULT',
  314. '/Kli.bronco/DD_alternate',              'I_DEFAULT',
  315. '/Kli.bronco/SB_alternate',              'I_DEFAULT',
  316. '/Kli.bronco/SC_alternate',              'I_DEFAULT',
  317. '/Kli/AS_alternate',                     'I_FED_CA',
  318. '/Kli/AT_alternate',                     'I_IND_AT',
  319. '/Kli/BB_alternate',                     'I_FED_CA',
  320. '/Kli/CA_alternate',                     'I_FED_CA',
  321. '/Kli/CL_alternate',                     'I_FED_CA',
  322. '/Kli/CV_alternate',                     'I_FED_CA',
  323. '/Kli/DD_alternate',                     'I_FED_CA',
  324. '/Kli/FR_alternate',                     'I_FED_CA',
  325. '/Kli/JS_alternate',                     'I_FED_SB',
  326. '/Kli/PT_alternate',                     'I_FED_CA',
  327. '/Kli/PU_alternate',                     'I_IND_PU',
  328. '/Kli/SB_alternate',                     'I_FED_SB',
  329. '/Kli/SC_alternate',                     'I_FED_CA',
  330. '/Kli/UT_alternate',                     'I_FED_CA',
  331. '/Kli/WB_alternate',                     'I_FED_SB',
  332. '/Ori.bronco/AS_alternate',              'I_DEFAULT',
  333. '/Ori.bronco/AT_alternate',              'I_DEFAULT',
  334. '/Ori.bronco/BB_alternate',              'I_DEFAULT',
  335. '/Ori.bronco/CA_alternate',              'I_DEFAULT',
  336. '/Ori.bronco/DD_alternate',              'I_DEFAULT',
  337. '/Ori.bronco/SB_alternate',              'I_DEFAULT',
  338. '/Ori.bronco/SC_alternate',              'I_DEFAULT',
  339. '/Ori/AS_alternate',                     'I_FED_CA',
  340. '/Ori/AT_alternate',                     'I_IND_AT',
  341. '/Ori/BB_alternate',                     'I_FED_CA',
  342. '/Ori/CA_alternate',                     'I_FED_CA',
  343. '/Ori/CL_alternate',                     'I_FED_CA',
  344. '/Ori/CV_alternate',                     'I_FED_CA',
  345. '/Ori/DD_alternate',                     'I_FED_CA',
  346. '/Ori/FR_alternate',                     'I_FED_CA',
  347. '/Ori/JS_alternate',                     'I_FED_SB',
  348. '/Ori/PT_alternate',                     'I_FED_CA',
  349. '/Ori/PU_alternate',                     'I_IND_PU',
  350. '/Ori/SB_alternate',                     'I_FED_SB',
  351. '/Ori/SC_alternate',                     'I_FED_CA',
  352. '/Ori/UT_alternate',                     'I_FED_CA',
  353. '/Ori/WB_alternate',                     'I_FED_SB',
  354. '/Rom.bronco/AS_alternate',              'I_DEFAULT',
  355. '/Rom.bronco/AT_alternate',              'I_DEFAULT',
  356. '/Rom.bronco/BB_alternate',              'I_DEFAULT',
  357. '/Rom.bronco/CA_alternate',              'I_DEFAULT',
  358. '/Rom.bronco/DD_alternate',              'I_DEFAULT',
  359. '/Rom.bronco/SB_alternate',              'I_DEFAULT',
  360. '/Rom.bronco/SC_alternate',              'I_DEFAULT',
  361. '/Rom.starwars/AS_alternate',            'I_DEFAULT',
  362. '/Rom.starwars/BB_alternate',            'I_DEFAULT',
  363. '/Rom.starwars/CA_alternate',            'I_DEFAULT',
  364. '/Rom.starwars/DD_alternate',            'I_DEFAULT',
  365. '/Rom.starwars/SB_alternate',            'I_DEFAULT',
  366. '/Rom.starwars/SC_alternate',            'I_DEFAULT',
  367. '/Rom/AS_alternate',                     'I_FED_CA',
  368. '/Rom/AT_alternate',                     'I_IND_AT',
  369. '/Rom/BB_alternate',                     'I_FED_CA',
  370. '/Rom/CA_alternate',                     'I_FED_CA',
  371. '/Rom/CL_alternate',                     'I_FED_CA',
  372. '/Rom/CV_alternate',                     'I_FED_CA',
  373. '/Rom/DD_alternate',                     'I_FED_CA',
  374. '/Rom/FR_alternate',                     'I_FED_CA',
  375. '/Rom/JS_alternate',                     'I_FED_SB',
  376. '/Rom/PT_alternate',                     'I_FED_CA',
  377. '/Rom/PU_alternate',                     'I_IND_PU',
  378. '/Rom/SB_alternate',                     'I_FED_SB',
  379. '/Rom/SC_alternate',                     'I_FED_CA',
  380. '/Rom/UT_alternate',                     'I_FED_CA',
  381. '/Rom/WB_alternate',                     'I_FED_SB',
  382. '/cloak_alternate',                      'I_DEFAULT',
  383. '/dashboard_bg_alternate',               'I_DEFAULT',
  384. '/default_alternate',                    'I_DEFAULT',
  385. '/emph_planet_seq_alternate',            'I_DEFAULT',
  386. '/emph_player_seq_alternate',            'I_DEFAULT',
  387. '/emph_player_seql_alternate',           'I_DEFAULT',
  388. '/exp2_alternate',                       'I_DEFAULT',
  389. '/explosion_alternate',                  'I_DEFAULT',
  390. '/hull_alternate',                       'I_DEFAULT',
  391. '/intro/clock_alternate',                'I_DEFAULT',
  392. '/intro/fedshield_alternate',            'I_DEFAULT',
  393. '/intro/header_alternate',               'I_DEFAULT',
  394. '/intro/header1_alternate',              'I_DEFAULT',
  395. '/intro/header2_alternate',              'I_DEFAULT',
  396. '/intro/header3_alternate',              'I_DEFAULT',
  397. '/intro/header4_alternate',              'I_DEFAULT',
  398. '/intro/headerA_alternate',              'I_DEFAULT',
  399. '/intro/headerB_alternate',              'I_DEFAULT',
  400. '/intro/icon_alternate',                 'I_DEFAULT',
  401. '/intro/klishield_alternate',            'I_DEFAULT',
  402. '/intro/noentry_alternate',              'I_DEFAULT',
  403. '/intro/orishield_alternate',            'I_DEFAULT',
  404. '/intro/romshield_alternate',            'I_DEFAULT',
  405. '/intro/safe_alternate',                 'I_DEFAULT',
  406. '/newstats/flag_alert_alternate',        'I_DEFAULT',
  407. '/newstats/flag_army_alternate',         'I_DEFAULT',
  408. '/newstats/flag_beaming_alternate',      'I_DEFAULT',
  409. '/newstats/flag_bomb_alternate',         'I_DEFAULT',
  410. '/newstats/flag_cloak_alternate',        'I_DEFAULT',
  411. '/newstats/flag_down_alternate',         'I_DEFAULT',
  412. '/newstats/flag_etemp_alternate',        'I_DEFAULT',
  413. '/newstats/flag_fed_alternate',          'I_DEFAULT',
  414. '/newstats/flag_fighter_alternate',      'I_DEFAULT',
  415. '/newstats/flag_fuel_alternate',         'I_DEFAULT',
  416. '/newstats/flag_fuse_alternate',         'I_DEFAULT',
  417. '/newstats/flag_hull_alternate',         'I_DEFAULT',
  418. '/newstats/flag_kli_alternate',          'I_DEFAULT',
  419. '/newstats/flag_missile_alternate',      'I_DEFAULT',
  420. '/newstats/flag_ori_alternate',          'I_DEFAULT',
  421. '/newstats/flag_plasma_alternate',       'I_DEFAULT',
  422. '/newstats/flag_pressor_alternate',      'I_DEFAULT',
  423. '/newstats/flag_repair_alternate',       'I_DEFAULT',
  424. '/newstats/flag_rom_alternate',          'I_DEFAULT',
  425. '/newstats/flag_ship_fed_alternate',     'I_DEFAULT',
  426. '/newstats/flag_ship_kli_alternate',     'I_DEFAULT',
  427. '/newstats/flag_ship_ori_alternate',     'I_DEFAULT',
  428. '/newstats/flag_ship_rom_alternate',     'I_DEFAULT',
  429. '/newstats/flag_speed1_alternate',       'I_DEFAULT',
  430. '/newstats/flag_speed2_alternate',       'I_DEFAULT',
  431. '/newstats/flag_torp_alternate',         'I_DEFAULT',
  432. '/newstats/flag_tractor_alternate',      'I_DEFAULT',
  433. '/newstats/flag_up_alternate',           'I_DEFAULT',
  434. '/newstats/flag_war_alternate',          'I_DEFAULT',
  435. '/newstats/flag_wtemp_alternate',        'I_DEFAULT',
  436. '/newstats/status_template_alternate',   'I_DEFAULT',
  437. '/oldexp_alternate',                     'I_DEFAULT',
  438. '/planets/F/0000_alternate',             'I_BARREN',
  439. '/planets/F/0001_alternate',             'I_BARREN',
  440. '/planets/F/0010_alternate',             'I_BARREN',
  441. '/planets/F/0011_alternate',             'I_BARREN',
  442. '/planets/F/0100_alternate',             'I_BARREN',
  443. '/planets/F/0101_alternate',             'I_BARREN',
  444. '/planets/F/0110_alternate',             'I_BARREN',
  445. '/planets/F/0111_alternate',             'I_BARREN',
  446. '/planets/F/1000_alternate',             'I_BARREN',
  447. '/planets/F/1001_alternate',             'I_BARREN',
  448. '/planets/F/1010_alternate',             'I_BARREN',
  449. '/planets/F/1011_alternate',             'I_BARREN',
  450. '/planets/F/1100_alternate',             'I_BARREN',
  451. '/planets/F/1101_alternate',             'I_BARREN',
  452. '/planets/F/1110_alternate',             'I_BARREN',
  453. '/planets/F/1111_alternate',             'I_BARREN',
  454. '/planets/F/MOO_0000_alternate',         'I_MOOBARREN',
  455. '/planets/F/MOO_0001_alternate',         'I_MOOBARREN',
  456. '/planets/F/MOO_0010_alternate',         'I_MOOBARREN',
  457. '/planets/F/MOO_0011_alternate',         'I_MOOBARREN',
  458. '/planets/F/MOO_0100_alternate',         'I_BARREN',
  459. '/planets/F/MOO_0101_alternate',         'I_BARREN',
  460. '/planets/F/MOO_0110_alternate',         'I_BARREN',
  461. '/planets/F/MOO_0111_alternate',         'I_BARREN',
  462. '/planets/F/MOO_1000_alternate',         'I_MOOBARREN',
  463. '/planets/F/MOO_1001_alternate',         'I_MOOBARREN',
  464. '/planets/F/MOO_1010_alternate',         'I_MOOBARREN',
  465. '/planets/F/MOO_1011_alternate',         'I_MOOBARREN',
  466. '/planets/F/MOO_1100_alternate',         'I_BARREN',
  467. '/planets/F/MOO_1101_alternate',         'I_BARREN',
  468. '/planets/F/MOO_1110_alternate',         'I_BARREN',
  469. '/planets/F/MOO_1111_alternate',         'I_BARREN',
  470. '/planets/F/MOO_m0000_alternate',        'I_MBARRENXPM',
  471. '/planets/F/MOO_m0001_alternate',        'I_MBARRENXPM',
  472. '/planets/F/MOO_m0010_alternate',        'I_MBARRENXPM',
  473. '/planets/F/MOO_m0011_alternate',        'I_MBARRENXPM',
  474. '/planets/F/MOO_m0100_alternate',        'I_MBARRENXPM',
  475. '/planets/F/MOO_m0101_alternate',        'I_MBARRENXPM',
  476. '/planets/F/MOO_m0110_alternate',        'I_MBARRENXPM',
  477. '/planets/F/MOO_m0111_alternate',        'I_MBARRENXPM',
  478. '/planets/F/MOO_m1000_alternate',        'I_MBARRENXPM',
  479. '/planets/F/MOO_m1001_alternate',        'I_MBARRENXPM',
  480. '/planets/F/MOO_m1010_alternate',        'I_MBARRENXPM',
  481. '/planets/F/MOO_m1011_alternate',        'I_MBARRENXPM',
  482. '/planets/F/MOO_m1100_alternate',        'I_MBARRENXPM',
  483. '/planets/F/MOO_m1101_alternate',        'I_MBARRENXPM',
  484. '/planets/F/MOO_m1110_alternate',        'I_MBARRENXPM',
  485. '/planets/F/MOO_m1111_alternate',        'I_MBARRENXPM',
  486. '/planets/F/m0000_alternate',            'I_MBARRENXPM',
  487. '/planets/F/m0001_alternate',            'I_MBARRENXPM',
  488. '/planets/F/m0010_alternate',            'I_MBARRENXPM',
  489. '/planets/F/m0011_alternate',            'I_MBARRENXPM',
  490. '/planets/F/m0100_alternate',            'I_MBARRENXPM',
  491. '/planets/F/m0101_alternate',            'I_MBARRENXPM',
  492. '/planets/F/m0110_alternate',            'I_MBARRENXPM',
  493. '/planets/F/m0111_alternate',            'I_MBARRENXPM',
  494. '/planets/F/m1000_alternate',            'I_MBARRENXPM',
  495. '/planets/F/m1001_alternate',            'I_MBARRENXPM',
  496. '/planets/F/m1010_alternate',            'I_MBARRENXPM',
  497. '/planets/F/m1011_alternate',            'I_MBARRENXPM',
  498. '/planets/F/m1100_alternate',            'I_MBARRENXPM',
  499. '/planets/F/m1101_alternate',            'I_MBARRENXPM',
  500. '/planets/F/m1110_alternate',            'I_MBARRENXPM',
  501. '/planets/F/m1111_alternate',            'I_MBARRENXPM',
  502. '/planets/F_overlay/0000_alternate',     'I_BARREN_OVERLAY',
  503. '/planets/F_overlay/0001_alternate',     'I_BARREN_OVERLAY',
  504. '/planets/F_overlay/0010_alternate',     'I_BARREN_OVERLAY',
  505. '/planets/F_overlay/0011_alternate',     'I_BARREN_OVERLAY',
  506. '/planets/F_overlay/0100_alternate',     'I_BARREN_OVERLAY',
  507. '/planets/F_overlay/0101_alternate',     'I_BARREN_OVERLAY',
  508. '/planets/F_overlay/0110_alternate',     'I_BARREN_OVERLAY',
  509. '/planets/F_overlay/0111_alternate',     'I_BARREN_OVERLAY',
  510. '/planets/F_overlay/1010_alternate',     'I_BARREN_OVERLAY',
  511. '/planets/F_overlay/1011_alternate',     'I_BARREN_OVERLAY',
  512. '/planets/F_overlay/1110_alternate',     'I_BARREN_OVERLAY',
  513. '/planets/F_overlay/1111_alternate',     'I_BARREN_OVERLAY',
  514. '/planets/F_overlay/m0000_alternate',    'I_MBARREN_OVERLAY',
  515. '/planets/F_overlay/m0001_alternate',    'I_MBARREN_OVERLAY',
  516. '/planets/F_overlay/m0010_alternate',    'I_MBARREN_OVERLAY',
  517. '/planets/F_overlay/m0011_alternate',    'I_MBARREN_OVERLAY',
  518. '/planets/F_overlay/m0100_alternate',    'I_MBARREN_OVERLAY',
  519. '/planets/F_overlay/m0101_alternate',    'I_MBARREN_OVERLAY',
  520. '/planets/F_overlay/m0110_alternate',    'I_MBARREN_OVERLAY',
  521. '/planets/F_overlay/m0111_alternate',    'I_MBARREN_OVERLAY',
  522. '/planets/F_overlay/m1000_alternate',    'I_MBARREN_OVERLAY',
  523. '/planets/F_overlay/m1001_alternate',    'I_MBARREN_OVERLAY',
  524. '/planets/F_overlay/m1010_alternate',    'I_MBARREN_OVERLAY',
  525. '/planets/F_overlay/m1011_alternate',    'I_MBARREN_OVERLAY',
  526. '/planets/F_overlay/m1100_alternate',    'I_MBARREN_OVERLAY',
  527. '/planets/F_overlay/m1101_alternate',    'I_MBARREN_OVERLAY',
  528. '/planets/F_overlay/m1110_alternate',    'I_MBARREN_OVERLAY',
  529. '/planets/F_overlay/m1111_alternate',    'I_MBARREN_OVERLAY',
  530. '/planets/MOObarren_alternate',          'I_BARREN',
  531. '/planets/MOOmbarren_alternate',         'I_BARREN',
  532. '/planets/R/000_alternate',              'I_BARREN',
  533. '/planets/R/001_alternate',              'I_BARREN',
  534. '/planets/R/010_alternate',              'I_BARREN',
  535. '/planets/R/011_alternate',              'I_BARREN',
  536. '/planets/R/100_alternate',              'I_BARREN',
  537. '/planets/R/101_alternate',              'I_BARREN',
  538. '/planets/R/110_alternate',              'I_BARREN',
  539. '/planets/R/111_alternate',              'I_BARREN',
  540. '/planets/R/m000_alternate',             'I_MBARRENXPM',
  541. '/planets/R/m001_alternate',             'I_MBARRENXPM',
  542. '/planets/R/m010_alternate',             'I_MBARRENXPM',
  543. '/planets/R/m011_alternate',             'I_MBARRENXPM',
  544. '/planets/R/m100_alternate',             'I_MBARRENXPM',
  545. '/planets/R/m101_alternate',             'I_MBARRENXPM',
  546. '/planets/R/m110_alternate',             'I_MBARRENXPM',
  547. '/planets/R/m111_alternate',             'I_MBARRENXPM',
  548. '/planets/R_overlay/000_alternate',      'I_BARREN_OVERLAY',
  549. '/planets/R_overlay/001_alternate',      'I_BARREN_OVERLAY',
  550. '/planets/R_overlay/010_alternate',      'I_BARREN_OVERLAY',
  551. '/planets/R_overlay/011_alternate',      'I_BARREN_OVERLAY',
  552. '/planets/R_overlay/100_alternate',      'I_BARREN_OVERLAY',
  553. '/planets/R_overlay/101_alternate',      'I_BARREN_OVERLAY',
  554. '/planets/R_overlay/110_alternate',      'I_BARREN_OVERLAY',
  555. '/planets/R_overlay/111_alternate',      'I_BARREN_OVERLAY',
  556. '/planets/R_overlay/m000_alternate',     'I_MBARREN_OVERLAY',
  557. '/planets/R_overlay/m001_alternate',     'I_MBARREN_OVERLAY',
  558. '/planets/R_overlay/m010_alternate',     'I_MBARREN_OVERLAY',
  559. '/planets/R_overlay/m011_alternate',     'I_MBARREN_OVERLAY',
  560. '/planets/R_overlay/m100_alternate',     'I_MBARREN_OVERLAY',
  561. '/planets/R_overlay/m101_alternate',     'I_MBARREN_OVERLAY',
  562. '/planets/R_overlay/m110_alternate',     'I_MBARREN_OVERLAY',
  563. '/planets/R_overlay/m111_alternate',     'I_MBARREN_OVERLAY',
  564. '/planets/S/STND_alternate',             'I_BARREN',
  565. '/planets/S/THIN_alternate',             'I_BARREN',
  566. '/planets/S/TNTD_alternate',             'I_BARREN',
  567. '/planets/S/TOXC_alternate',             'I_BARREN',
  568. '/planets/S/mSTND_alternate',            'I_MBARRENXPM',
  569. '/planets/S/mTHIN_alternate',            'I_MBARRENXPM',
  570. '/planets/S/mTNTD_alternate',            'I_MBARRENXPM',
  571. '/planets/S/mTOXC_alternate',            'I_MBARRENXPM',
  572. '/planets/S_overlay/STND_alternate',     'I_BARREN_OVERLAY',
  573. '/planets/S_overlay/THIN_alternate',     'I_BARREN_OVERLAY',
  574. '/planets/S_overlay/TNTD_alternate',     'I_BARREN_OVERLAY',
  575. '/planets/S_overlay/TOXC_alternate',     'I_BARREN_OVERLAY',
  576. '/planets/S_overlay/mSTND_alternate',    'I_MBARREN_OVERLAY',
  577. '/planets/S_overlay/mTHIN_alternate',    'I_MBARREN_OVERLAY',
  578. '/planets/S_overlay/mTNTD_alternate',    'I_MBARREN_OVERLAY',
  579. '/planets/S_overlay/mTOXC_alternate',    'I_MBARREN_OVERLAY',
  580. '/planets/T/fedmplanet_alternate',       'I_MBARREN',
  581. '/planets/T/fedplanet_alternate',        'I_BARREN',
  582. '/planets/T/indmplanet_alternate',       'I_MBARREN',
  583. '/planets/T/indplanet_alternate',        'I_BARREN',
  584. '/planets/T/klimplanet_alternate',       'I_MBARREN',
  585. '/planets/T/kliplanet_alternate',        'I_BARREN',
  586. '/planets/T/orimplanet_alternate',       'I_MBARREN',
  587. '/planets/T/oriplanet_alternate',        'I_BARREN',
  588. '/planets/T/rommplanet_alternate',       'I_MBARREN',
  589. '/planets/T/romplanet_alternate',        'I_BARREN',
  590. '/planets/T_overlay/fedmplanet_alternate', 'I_MBARREN_OVERLAY',
  591. '/planets/T_overlay/fedplanet_alternate', 'I_BARREN_OVERLAY',
  592. '/planets/T_overlay/indmplanet_alternate', 'I_MBARREN_OVERLAY',
  593. '/planets/T_overlay/indplanet_alternate', 'I_BARREN_OVERLAY',
  594. '/planets/T_overlay/klimplanet_alternate', 'I_MBARREN_OVERLAY',
  595. '/planets/T_overlay/kliplanet_alternate', 'I_BARREN_OVERLAY',
  596. '/planets/T_overlay/orimplanet_alternate', 'I_MBARREN_OVERLAY',
  597. '/planets/T_overlay/oriplanet_alternate', 'I_BARREN_OVERLAY',
  598. '/planets/T_overlay/rommplanet_alternate', 'I_MBARREN_OVERLAY',
  599. '/planets/T_overlay/romplanet_alternate', 'I_BARREN_OVERLAY',
  600. '/planets/age0_alternate',               'I_DEFAULT',
  601. '/planets/age1_alternate',               'I_DEFAULT',
  602. '/planets/age2_alternate',               'I_DEFAULT',
  603. '/planets/age3_alternate',               'I_DEFAULT',
  604. '/planets/age4_alternate',               'I_DEFAULT',
  605. '/planets/asteroid_alternate',           'I_DEFAULT',
  606. '/planets/barren_alternate',             'I_DEFAULT',
  607. '/planets/barren_overlay_alternate',     'I_DEFAULT',
  608. '/planets/masteroid_alternate',          'I_DEFAULT',
  609. '/planets/mbarren_alternate',            'I_DEFAULT',
  610. '/planets/mbarren_overlay_alternate',    'I_DEFAULT',
  611. '/planets/mbarrenxpm_alternate',         'I_MBARREN',
  612. '/planets/mplan_noinfo_alternate',       'I_DEFAULT',
  613. '/planets/mwormhole_alternate',          'I_DEFAULT',
  614. '/planets/plan_noinfo_alternate',        'I_DEFAULT',
  615. '/planets/star_alternate',               'I_DEFAULT',
  616. '/planets/starm_alternate',              'I_DEFAULT',
  617. '/planets/wormhole_alternate',           'I_DEFAULT',
  618. '/rainbow_alternate',                    'I_DEFAULT',
  619. '/sbexplosion_alternate',                'I_DEFAULT',
  620. '/warpbeacon_alternate',                 'I_DEFAULT',
  621. '/warpflash_alternate',                  'I_DEFAULT',
  622. '/weapons/edrone_alternate',             'I_DEFAULT',
  623. '/weapons/edronecloud_alternate',        'I_DEFAULT',
  624. '/weapons/efighter_alternate',           'I_DEFAULT',
  625. '/weapons/efightercloud_alternate',      'I_DEFAULT',
  626. '/weapons/eplasmacloud_alternate',       'I_DEFAULT',
  627. '/weapons/eplasmatorp_alternate',        'I_DEFAULT',
  628. '/weapons/etorp_alternate',              'I_DEFAULT',
  629. '/weapons/etorpcloud_alternate',         'I_DEFAULT',
  630. '/weapons/kitchen_sink_alternate',       'I_DEFAULT',
  631. '/weapons/mdrone_alternate',             'I_DEFAULT',
  632. '/weapons/mdronecloud_alternate',        'I_DEFAULT',
  633. '/weapons/mfighter_alternate',           'I_DEFAULT',
  634. '/weapons/mfightercloud_alternate',      'I_DEFAULT',
  635. '/weapons/mplasmacloud_alternate',       'I_DEFAULT',
  636. '/weapons/mplasmatorp_alternate',        'I_DEFAULT',
  637. '/weapons/mtorp_alternate',              'I_DEFAULT',
  638. '/weapons/mtorpcloud_alternate',         'I_DEFAULT');
  639. }
  640.