aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Tatham <anakin@pobox.com>2005-06-04 09:59:03 +0000
committerSimon Tatham <anakin@pobox.com>2005-06-04 09:59:03 +0000
commit454e566df616ad3f9ed644e8c51526f1da0d8202 (patch)
treec92f827d5a29859268996bc1d9d2b763269f2412
parent402408125eb8db989b125e3059f873b9a833632a (diff)
downloadpuzzles-454e566df616ad3f9ed644e8c51526f1da0d8202.zip
puzzles-454e566df616ad3f9ed644e8c51526f1da0d8202.tar.gz
puzzles-454e566df616ad3f9ed644e8c51526f1da0d8202.tar.bz2
puzzles-454e566df616ad3f9ed644e8c51526f1da0d8202.tar.xz
James Harvey requested that puzzles not use DEBUG as a preprocessor
symbol for enabling diagnostics, presumably because in his Palm port it means something else as well. He sent this patch to switch Net and Netslide over to using GENERATION_DIAGNOSTICS, in the fashion of the newer games. [originally from svn r5908]
-rw-r--r--net.c8
-rw-r--r--netslide.c8
2 files changed, 8 insertions, 8 deletions
diff --git a/net.c b/net.c
index 33af6c6..8a4f706 100644
--- a/net.c
+++ b/net.c
@@ -1229,7 +1229,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
OFFSET(x2, y2, x1, y1, d1, params);
d2 = F(d1);
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("picked (%d,%d,%c) <-> (%d,%d,%c)\n",
x1, y1, "0RU3L567D9abcdef"[d1], x2, y2, "0RU3L567D9abcdef"[d2]);
#endif
@@ -1256,7 +1256,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
xydp = find234(possibilities, &xyd1, NULL);
if (xydp) {
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("T-piece; removing (%d,%d,%c)\n",
xydp->x, xydp->y, "0RU3L567D9abcdef"[xydp->direction]);
#endif
@@ -1283,7 +1283,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
xydp = find234(possibilities, &xyd1, NULL);
if (xydp) {
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("Loop avoidance; removing (%d,%d,%c)\n",
xydp->x, xydp->y, "0RU3L567D9abcdef"[xydp->direction]);
#endif
@@ -1318,7 +1318,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
if (index(params, tiles, x3, y3))
continue; /* this would create a loop */
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("New frontier; adding (%d,%d,%c)\n",
x2, y2, "0RU3L567D9abcdef"[d]);
#endif
diff --git a/netslide.c b/netslide.c
index b0d975f..0ab3e34 100644
--- a/netslide.c
+++ b/netslide.c
@@ -417,7 +417,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
OFFSET(x2, y2, x1, y1, d1, params);
d2 = F(d1);
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("picked (%d,%d,%c) <-> (%d,%d,%c)\n",
x1, y1, "0RU3L567D9abcdef"[d1], x2, y2, "0RU3L567D9abcdef"[d2]);
#endif
@@ -444,7 +444,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
xydp = find234(possibilities, &xyd1, NULL);
if (xydp) {
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("T-piece; removing (%d,%d,%c)\n",
xydp->x, xydp->y, "0RU3L567D9abcdef"[xydp->direction]);
#endif
@@ -471,7 +471,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
xydp = find234(possibilities, &xyd1, NULL);
if (xydp) {
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("Loop avoidance; removing (%d,%d,%c)\n",
xydp->x, xydp->y, "0RU3L567D9abcdef"[xydp->direction]);
#endif
@@ -506,7 +506,7 @@ static char *new_game_desc(game_params *params, random_state *rs,
if (index(params, tiles, x3, y3))
continue; /* this would create a loop */
-#ifdef DEBUG
+#ifdef GENERATION_DIAGNOSTICS
printf("New frontier; adding (%d,%d,%c)\n",
x2, y2, "0RU3L567D9abcdef"[d]);
#endif