Function for adding random lights to roomNGon

This commit is contained in:
2026-03-19 11:40:49 +00:00
parent d1c2870d63
commit 508b848204
20 changed files with 453 additions and 336 deletions
+3 -3
View File
@@ -33,7 +33,7 @@ import NewInt
placeSpot :: Int -> GenWorld -> Placement -> GenWorld
placeSpot rid w plmnt = case plmnt ^. plSpot of
PSRoomRand i f -> placeSpotRoomRand rid i f plmnt w
PSPos extract eff fallback -> placeSpotUsingLink w rid plmnt extract eff fallback
PSPos extract eff fallback -> placeSpotUsingRoomPos w rid plmnt extract eff fallback
_ -> placePlainPSSpot w rid plmnt shift
where
shift = _rmShift $ w ^?! genRooms . ix rid
@@ -62,7 +62,7 @@ placePlainPSSpot w rid plmnt shift = case plmnt ^. plType of
(w' & genRooms . ix rid . rmPmnts .:~ newplmnt)
-- this should be tidied up
placeSpotUsingLink ::
placeSpotUsingRoomPos ::
GenWorld ->
Int ->
Placement ->
@@ -70,7 +70,7 @@ placeSpotUsingLink ::
(RoomPos -> Room -> Room) ->
Maybe Placement ->
GenWorld
placeSpotUsingLink w rid plmnt extract eff fallback =
placeSpotUsingRoomPos w rid plmnt extract eff fallback =
case searchedPoss (w ^?! genRooms . ix rid . rmPos) of
Just (ps, rmposs) ->
placeSpot