I know the algorithm Simon Tatham's version uses is hyperlocal (it never requires more than a distance of 2 deduction), and given the way the screen scrolls the bottom row will always have at least two rows above it fully visible, so I actually don't think it'd take any modification at all.
In any event, thanks for replying. This really is a neat idea and game. :)