Start to migrate all old level generation to MetaTrees

This commit is contained in:
2022-06-12 19:31:57 +01:00
parent 617765d5d4
commit dbba78ef05
9 changed files with 57 additions and 93 deletions
+2 -2
View File
@@ -1,4 +1,4 @@
{-# LANGUAGE TupleSections #-}
--{-# LANGUAGE TupleSections #-}
module Dodge.Room.GlassLesson where
import Dodge.UseAll
import Dodge.RoomLink
@@ -54,6 +54,6 @@ glassLesson = do
]
]
glassLessonRunPast :: RandomGen g => State g (MetaTree Room)
glassLessonRunPast = (f <$> glassLesson) >>= rToOnward "glassLessonRunPast"
glassLessonRunPast = glassLesson >>= rToOnward "glassLessonRunPast" . f
where
f (Node r rs) = Node r $ return (cleatLabel 0 $ door & rmConnectsTo .~ S.member (OnEdge West)) : rs