Skip to content
Snippets Groups Projects
Commit f1ae288b authored by Michael Leuschel's avatar Michael Leuschel
Browse files

do not allow changing cells from Puzzle

parent 43a43055
No related branches found
No related tags found
No related merge requests found
......@@ -84,10 +84,10 @@ OPERATIONS
SetCurPos(x,y) = PRE x:DOM & y:DOM THEN
curx, cury := x,y // change current position
END;
SetBoard(val) = PRE val:RAN THEN
SetBoard(val) = PRE val:RAN & cury /: dom(PuzzleBoard(curx)) THEN
Board(curx)(cury) := val // Set the Value at the current position
END;
ClearCurPos = BEGIN
ClearCurPos = PRE cury /: dom(PuzzleBoard(curx)) THEN
Board(curx) := {cury} <<| Board(curx) // clear the value at the current position
END;
res <-- GetPossibleVals = BEGIN
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment