shithub: puzzles

Download patch

ref: aafb1b4983d4cd2eb2d3465b4ed9ad2d67888bf5
parent: b98d93ac553687bcebd2232e234975f4cb635d3f
author: Ian Jackson <ijackson@chiark.greenend.org.uk>
date: Sat Sep 30 15:50:48 EDT 2017

tracks: Make error clue background white

This makes them stand out more.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>

--- a/tracks.c
+++ b/tracks.c
@@ -2140,7 +2140,7 @@
     COL_GRID, COL_CLUE, COL_CURSOR,
     COL_TRACK, COL_TRACK_CLUE, COL_SLEEPER,
     COL_DRAGON, COL_DRAGOFF,
-    COL_ERROR, COL_FLASH,
+    COL_ERROR, COL_FLASH, COL_ERROR_BACKGROUND,
     NCOLOURS
 };
 
@@ -2157,6 +2157,7 @@
         ret[COL_CLUE             * 3 + i] = 0.0F;
         ret[COL_GRID             * 3 + i] = 0.75F;
         ret[COL_CURSOR           * 3 + i] = 0.6F;
+        ret[COL_ERROR_BACKGROUND * 3 + i] = 1.0F;
     }
 
     ret[COL_SLEEPER * 3 + 0] = 0.5F;
@@ -2519,7 +2520,7 @@
             ds->num_errors[i] = state->num_errors[i];
             draw_clue(dr, ds, w, state->numbers->numbers[i], i,
                       ds->num_errors[i] ? COL_ERROR : COL_CLUE,
-		      COL_BACKGROUND);
+		      ds->num_errors[i] ? COL_ERROR_BACKGROUND : COL_BACKGROUND);
         }
     }