Function: 5x5-play-solution

5x5-play-solution is a byte-compiled function defined in 5x5.el.gz.

Signature

(5x5-play-solution SOLUTION BEST)

Documentation

Play a solution on an empty grid.

This destroys the current game in progress because it is an animated attempt.

Source Code

;; Defined in /usr/src/emacs/lisp/play/5x5.el.gz
(defun 5x5-play-solution (solution best)
  "Play a solution on an empty grid.
This destroys the current game in progress because it is an
animated attempt."
  (5x5-new-game)
  (let ((inhibit-quit t))
    (dotimes (y 5x5-grid-size)
      (dotimes (x 5x5-grid-size)
        (setq 5x5-y-pos y
              5x5-x-pos x)
        (if (5x5-cell solution y x)
            (5x5-flip-current))
        (5x5-draw-grid (list 5x5-grid solution best))
        (5x5-position-cursor)
        (sit-for 5x5-animate-delay))))
  5x5-grid)