summaryrefslogtreecommitdiff
path: root/games/xrobots/files/patch-actions.c
blob: 0b9bf78e407da921b501215da236f1978a8b59ff (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
--- actions.c.orig	2013-10-13 01:20:18.000000000 +1100
+++ actions.c	2013-10-13 01:26:21.000000000 +1100
@@ -66,6 +66,7 @@
   Cardinal *num_params;
 {
   /* do nothing */
+  return NULL;
 }
 
 
@@ -169,11 +170,11 @@
   int diff_x, diff_y;
   int num_wasted;
 
-  if(!game_active) return;
+  if(!game_active) return NULL;
 
   if(get_next_position(&diff_x, &diff_y, event->x, event->y,
                         params, *num_params))
-	return;
+	return NULL;
 
   last_human_x = human_x;
   last_human_y = human_y;
@@ -210,14 +211,14 @@
   int diff_x, diff_y;
   int num_wasted;
 
-  if(!game_active) return;
+  if(!game_active) return NULL;
 
   if(get_next_position(&diff_x, &diff_y, event->x, event->y,
                         params, *num_params))
-	return;
+	return NULL;
 
   if(! can_go(human_x+diff_x,human_y+diff_y) ) 
-	return;
+	return NULL;
 
   while( can_go(human_x+diff_x,human_y+diff_y) ) {
     last_human_x = human_x;
@@ -261,7 +262,7 @@
   int tmp_human_x, tmp_human_y;
   int num_wasted;
 
-  if(!game_active) return;
+  if(!game_active) return NULL;
 
   while(direction = determine_direction(event->x,event->y)) {
     if(direction == STILL) break;