Simplify placements

This commit is contained in:
2025-09-23 17:22:31 +01:00
parent 4074c40083
commit 6984a34c19
3 changed files with 80 additions and 82 deletions
+2 -2
View File
@@ -86,7 +86,7 @@ doInPlacements w =
doRoomInPlacements :: GenWorld -> Room -> (GenWorld, Room)
doRoomInPlacements w rm = foldr f (w, rm) $ _rmInPmnt rm
where
f plf (w', r') = fst $ placeSpot (w', r') (plf (w'))
f plf (w', r') = placeSpot (w', r') (plf (w'))
--doOutPlacements :: GenWorld -> GenWorld
--doOutPlacements w =
@@ -109,7 +109,7 @@ doIndividualPlacements gw =
in gw' & genRooms .~ rms
doRoomPlacements :: GenWorld -> Room -> (GenWorld, Room)
doRoomPlacements w rm = foldl' (\wr -> fst . placeSpot wr) (w, rm & rmPmnts .~ mempty)
doRoomPlacements w rm = foldl' (\wr -> placeSpot wr) (w, rm & rmPmnts .~ mempty)
$ _rmPmnts rm
setupWorldBounds :: World -> World