aboutsummaryrefslogtreecommitdiff
path: root/tracks.c (follow)
Commit message (Collapse)AuthorAge
* Tracks: fix further completion-checking loopholes.Simon Tatham2016-02-26
| | | | | | | | | | | | A user pointed out that Tracks could sometimes flash for completion when there wasn't even a full path from A to B! And it looks as if that wasn't even a mistake I introduced with the loop-checking revamp this week. Now I _think_ it's complete: we set ret=FALSE in check_completion wherever we also produce an error highlight, and also whenever there is no path connecting A with B. And if there is a path connecting A with B, then any square not on the path becomes an error highlight.
* Tracks: tighten up a small loophole in completion checking.Simon Tatham2016-02-24
| | | | | | | | If you had a single connected path linking the source to the destination but _also_ had a spurious edge elsewhere in the grid, then the spurious edge would be highlighted as an error, but it wouldn't inhibit declaring the game complete and showing the victory flash.
* Tracks: use the new findloop for loop detection.Simon Tatham2016-02-24
| | | | | | | Tracks's previous loop detector was very basic, and only bothered to highlight one loop, even if the player managed to create more than one at a time. Now we highlight all of them.
* Fix premature completion flash in Tracks.Simon Tatham2015-10-23
| | | | | | | | | | | | | Commit 44e2690ab loosened check_completion's idea of what made a square count as 'having track in it' for purposes of checking violations of the row/column counts. Unfortunately, that loosened notion also applied to the check for the game being complete - so the game would announce a win as soon as you had every square shaded, even if you hadn't actually laid all the exact track positions down. Now we separately count up the number of track-ish squares and the number of fully completed ones, and use the former for error checking and the latter for completion checking.
* Highlight clue errors in Tracks in some more situations.Jonas Kölker2015-10-21
| | | | | | | | | - Count any square as having a track either if the square is marked as such (rendered as a different background), or if at least one adjacent edge is marked as containing a segment of train track (rendered as train tracks if they're placed, else as an '='). - Do the same counting in rows and columns.
* New puzzle from James Harvey: 'Tracks'.Simon Tatham2015-02-08