diff --git a/src/Util.hs b/src/Util.hs index 21da383..ad1d6d1 100644 --- a/src/Util.hs +++ b/src/Util.hs @@ -81,6 +81,13 @@ convertTileToImg mat = fromLists conversion _ -> error "unexpected number if neighbouring walls" ) + Offi + | any + (\(rr, cc) -> M.safeGet (irow + rr) (icol + cc) mat == Just Door) + ((,) <$> [-1 .. 1] <*> [-1 .. 1]) -> + Just ImgEmpty + | otherwise -> + Nothing _ -> Nothing