Make chasms remove RoomPos within their boundaries

This commit is contained in:
2025-10-07 10:43:15 +01:00
parent 4cc5477f07
commit e9178f9643
12 changed files with 280 additions and 256 deletions
+14 -2
View File
@@ -1,6 +1,5 @@
module Dodge.Room.Tutorial where
import Dodge.Room.Pillar
import Dodge.Item.Held.Utility
import Control.Monad
import qualified Data.IntMap.Strict as IM
@@ -39,12 +38,25 @@ import TreeHelp
--import Data.List (intersperse)
testf = PSPos (\x _ -> f x) (\_ -> id) Nothing
where
f x = case _rpType x of
NotLink{} -> Just (PS (_rpPos x) (_rpDir x), x)
_ -> Nothing
tutAnoTree :: State LayoutVars MTRS
tutAnoTree = do
foldMTRS
[ tToBTree "TutStartRez" . return . cleatOnward <$> tutRezBox
, corDoor
, tToBTree "x" . return . cleatOnward <$> roomPillarsSquare
, tToBTree "test" . return . cleatOnward <$> (roomRectAutoLinks 100 100
<&> rmPmnts <>~
[sps0 $ PutChasm $ rectNSWE 70 30 30 70
, Placement testf (PutFlIt led) Nothing Nothing (const $ const Nothing)
]
<&> rmPos .~[RoomPos 35 0 mempty (NotLink False) mempty]
-- <&> rmPos .~[]
)
, corDoor
, tutHub
, tutLight