aboutsummaryrefslogtreecommitdiffstats
path: root/games/xbomber/files/patch-ac
blob: 4b5ec3c345263474de8042f549e94b223cf59902 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
--- xbomber.c.orig  Sat Jun 20 11:09:35 1998
+++ xbomber.c   Sat Aug 12 03:09:36 2000
@@ -1599,7 +1599,7 @@
   /* Get -color switch: */
 
   use_color = 0;
-  strcpy(graphicsset, "./pixmaps");
+  strcpy(graphicsset, DATADIR "/pixmaps");
   
   if (argc >= 2)
     {
@@ -1683,7 +1683,7 @@
          
          for (i = 0; i < NUM_SOUNDS; i++)
        {
-         sprintf(file, "sounds/%s.au", sound_names[i]);
+         sprintf(file, DATADIR "/sounds/%s.au", sound_names[i]);
          
          fi = fopen(file, "r");
          if (fi != NULL)
@@ -1720,7 +1720,7 @@
          
          for (i = 0; i < NUM_NSOUNDS; i++)
        {
-         sprintf(file, "sounds/numbers/%s.au", nsound_names[i]);
+         sprintf(file, DATADIR "/sounds/numbers/%s.au", nsound_names[i]);
          
          fi = fopen(file, "r");
          if (fi != NULL)
@@ -2096,23 +2096,23 @@
   
   /* Make cursor: */
   
-  ret = XReadBitmapFile(display[pln], window[pln], "bitmaps/cursor.xbm",
+  ret = XReadBitmapFile(display[pln], window[pln], DATADIR "/bitmaps/cursor.xbm",
            &tempint1, &tempint2, &cursor_pixmap[pln],
            &tempint3, &tempint4);
   
   if (ret != BitmapSuccess)
     {
-      perror("bitmaps/cursor.xbm");
+      perror(DATADIR "/bitmaps/cursor.xbm");
       exit(1);
     }
   
-  ret = XReadBitmapFile(display[pln], window[pln], "bitmaps/cursor-mask.xbm",
+  ret = XReadBitmapFile(display[pln], window[pln], DATADIR "/bitmaps/cursor-mask.xbm",
            &tempint1, &tempint2, &cursor_mask[pln],
            &tempint3, &tempint4);
   
   if (ret != BitmapSuccess)
     {
-      perror("bitmaps/cursor-mask.xbm");
+      perror(DATADIR "/bitmaps/cursor-mask.xbm");
       exit(1);
     }
   
@@ -2149,7 +2149,7 @@
                                black[pln],
                                has_color[pln]));
          
-         sprintf(file, "bitmaps/%s.xbm", object_names[i]);
+         sprintf(file, DATADIR "/bitmaps/%s.xbm", object_names[i]);
          
          ret = XReadBitmapFile(display[pln], window[pln], file, 
                    &tempint1, &tempint2,
@@ -2863,7 +2863,7 @@
   
   /* Load level layout on top of this: */
   
-  sprintf(filename, "levels/level%.2d.dat", level);
+  sprintf(filename, DATADIR "/levels/level%.2d.dat", level);
   
   fi = fopen(filename, "r");
   if (fi == NULL)
@@ -3303,7 +3303,7 @@
     {
       c = '.';
       
-      sprintf(file, "pixmaps/%s.ppm", object_names[i]);
+      sprintf(file, DATADIR "/pixmaps/%s.ppm", object_names[i]);
       
       fi = fopen(file, "r");
       if (fi == NULL)