Package: gravitywars / 1.102-34

010_data_paths.diff Patch series | download
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
Index: gravitywars-1.102/GravityWars101.c
===================================================================
--- gravitywars-1.102.orig/GravityWars101.c	2006-05-16 06:32:02.000000000 +0200
+++ gravitywars-1.102/GravityWars101.c	2006-05-16 06:34:01.000000000 +0200
@@ -59,27 +59,31 @@
   short baselevel;
   char filename[128];
   
-  char firstlevel[20]="levels/level01";
+  char firstlevel[80]="levels/level01";
   char buf[128];
-  
+
   levelnum=1;
   
   if (readlink(arg[0],buf,128)==-1) 
     strcpy(buf,arg[0]);
-  
+
+/*  
   n=strlen(buf);
   while(n>=0)                       
     if (buf[n--]=='/') break;
   if (n<0) {
-    strcpy(gamename,"./");
-    gamenamelen=2;
+    strcpy(gamename,"/");
+    gamenamelen=1;
   }  
   else {
     strcpy(gamename,buf);
     gamename[n+2]=0;
     gamenamelen=strlen(gamename);
   }
-  
+*/
+
+	strcpy(gamename,"/usr/share/games/gravitywars/");
+	gamenamelen=strlen(gamename);
 
   if (n_args>1) {
     n=0;