Open/Lock logic moved and game lost called

I moved the logic for opening or locking a door into maze, and was
actually able to piggyback off another method call to greatly reduce the
amount of code needed for this operation.  Ive also added the necessary
call to game lost when the maze is no longer solvable.