This commit is contained in:
2022-06-14 12:48:48 +01:00
parent 79aab975c8
commit e1f3a774b2
2 changed files with 10 additions and 15 deletions
+6 -13
View File
@@ -16,8 +16,8 @@ import Picture
import qualified Data.IntMap.Strict as IM
{- | A passage with a switch that opens forward access while closing backwards access. -}
airlock :: RandomGen g => State g Room
--airlock = takeOne [airlock0,airlock90,airlockCrystal,airlockZ]
airlock = takeOne [airlockCrystal]
airlock = takeOne [airlock0,airlock90,airlockCrystal,airlockZ]
--airlock = takeOne [airlockCrystal]
{- | Straight airlock -}
airlock0 :: Room
airlock0 = defaultRoom
@@ -129,13 +129,9 @@ airlock90 = defaultRoom
col = dim $ dim $ bright red
pss = (V2 0 0 ,) <$> arcStepwise 3 (negate $ pi/2) (V2 0 0) (V2 0 55)
airlockCrystal
:: Room
airlockCrystal :: Room
airlockCrystal = defaultRoom
{ _rmPolys =
[ rectNSWE 140 0 0 40
, orderPolygon $ map toV2 [ (39,20) , (150,60) , (150,80) , (39,120) ]
]
{ _rmPolys = [ rectNSWE 140 0 0 40 , switchcutout ]
, _rmLinks = muout[(V2 20 130,0) ] ++ muin[(V2 20 0 ,pi) ]
, _rmPath = [ ]
, _rmPmnts =
@@ -144,13 +140,10 @@ airlockCrystal = defaultRoom
, crystalLine (V2 0 70) (V2 40 70)
, mntLS vShape (V2 150 70) (V3 110 70 70)
]
, _rmBound =
[ rectNSWE 120 20 0 40
, orderPolygon $ map toV2 [ (39,20) , (150,60) , (150,80) , (39,120) ]
]
, _rmBound = [ rectNSWE 120 20 0 40 , switchcutout ]
}
where
--cond w = or $ M.lookup (DoorNumOpen n) (_worldState w)
switchcutout = orderPolygon $ map toV2 [ (39,20) , (150,60) , (150,80) , (39,120) ]
cond btid w' = _btState (_buttons w' IM.! btid) == BtOn
col = dim $ dim $ bright red
pss :: [(Point2,Point2)]