Unify block wall types

This commit is contained in:
2021-10-28 00:05:57 +01:00
parent 74e19008b4
commit 686a9fc3ee
9 changed files with 38 additions and 187 deletions
-16
View File
@@ -57,24 +57,8 @@ initialWorld = defaultWorld
, _menuLayers = [TerminalScreen 300 rezText']
}
zonedBlockWalls :: World -> [String]
zonedBlockWalls = concatMap f . IM.toList . _znObjects . _wallsZone
where
f (x,ys) = map (show x ++) $ map g $ IM.toList ys
g (y,zs) = show y
testStringInit :: World -> [String]
testStringInit _ = []
--testStringInit w = map (show . _blWallIDs) . IM.elems $ _blocks w
--testStringInit w = (map (f w) . filter g . IM.elems $ _walls w)
-- ++ map (show . fst) (IM.toList $ _znObjects $ _wallsZone w)
-- ++ zonedBlockWalls w
where
g Block{} = True
g _ = False
f w' wl = show (_wlID wl) ++ " : " ++ show blid ++ show (_blWallIDs $ (_blocks w') IM.! blid)
where
blid = _wlBlockID wl
--testStringInit = mapMaybe f . IM.elems . flattenIMIMIM . _znObjects . _wallsZone
-- where
-- f dr | _wlColor dr == V4 0 1 0 1 = Just . show $ _wlLine dr