aboutsummaryrefslogtreecommitdiff
path: root/malloc.c
diff options
context:
space:
mode:
authorSimon Tatham <anakin@pobox.com>2014-12-28 12:19:50 +0000
committerSimon Tatham <anakin@pobox.com>2014-12-28 13:15:31 +0000
commit546fbe6774ce4c8b630f33a341963a77e1e151e4 (patch)
treee0550e349109c69e898d61722d8188f73922344c /malloc.c
parent822243de1bc1fc6d26b2f2d0f45616c8f6183058 (diff)
downloadpuzzles-546fbe6774ce4c8b630f33a341963a77e1e151e4.zip
puzzles-546fbe6774ce4c8b630f33a341963a77e1e151e4.tar.gz
puzzles-546fbe6774ce4c8b630f33a341963a77e1e151e4.tar.bz2
puzzles-546fbe6774ce4c8b630f33a341963a77e1e151e4.tar.xz
Error-highlight loops in Net.
Loops are detected using the same dsf technique I ended up using in Slant, and highlighted in red (whether or not the connected component they belong to is currently powered). Should make life a little bit easier for someone who's filled in most of the grid to a nice uniform cyan and finds one piece left over - now they have some idea where to start looking for their mistake. We also take care not to generate any loops in the starting position, on grounds of politeness (don't accuse the user of a mistake before they've even had a chance to make one). Loop detection does not contribute to the code that decides whether the puzzle is complete, because there's no need - if all squares are connected together, then there can't be any loops anyway, by graph theory.
Diffstat (limited to 'malloc.c')
0 files changed, 0 insertions, 0 deletions