Tweak turret health
This commit is contained in:
@@ -8,7 +8,8 @@ module Dodge.Room.LasTurret (
|
||||
keyCardRoomRunPast,
|
||||
lasSensorTurretTest,
|
||||
healthTest,
|
||||
lasCenRunClose,
|
||||
lasRunYinYangCenter,
|
||||
lasRunYinYang,
|
||||
lasCenRunClose',
|
||||
lasCenRunClose1,
|
||||
lasCenRunCloseLongCor,
|
||||
@@ -147,8 +148,56 @@ lasCenSensEdge n = do
|
||||
, treePost [door, cleatLabel 0 corridor]
|
||||
]
|
||||
|
||||
lasCenRunClose :: (RandomGen g) => State g (MetaTree Room String)
|
||||
lasCenRunClose = do
|
||||
lasRunYinYang :: (RandomGen g) => State g (MetaTree Room String)
|
||||
lasRunYinYang = do
|
||||
npoly <- takeOne [6,8,10,12]
|
||||
thelight <- mntLightLnkCond $ rprBool $ const . isInLnk
|
||||
thelight1 <- mntLightLnkCond $ rprBool $ const . isOutLnk
|
||||
thelight2 <- mntLightLnkCond $ rprBool $ const . (\rp -> PolyEdge ((npoly + 1) `div` 4) `S.member`
|
||||
(fold $ rp ^? rpType . rplsType))
|
||||
thelight3 <- mntLightLnkCond $ rprBool $ const . (\rp -> PolyEdge (3*(npoly + 1) `div` 4) `S.member`
|
||||
(fold $ rp ^? rpType . rplsType))
|
||||
r <- shuffleLinks =<<
|
||||
(roomNgon npoly 250
|
||||
<&> rmPmnts
|
||||
.~
|
||||
[angwall a | a <- [0,pi/8..pi-pi/9]] <>
|
||||
[bngwall a | a <- [0,pi/8..pi-pi/9]] <>
|
||||
[ awall 0 (rectWH 15 5)
|
||||
, putLasTurret 0.02 & plSpot . psPos .~ negate offxy
|
||||
, putLasTurret 0.02 & plSpot . psPos .~ offxy
|
||||
-- , awall (V2 0 50) (square 10)
|
||||
, thelight
|
||||
, thelight1
|
||||
, thelight2
|
||||
, thelight3
|
||||
]
|
||||
<&> rmPath %~ (addNodesCrossingCirc 0 30
|
||||
. flip (foldr ($)) [apath a | a <- [0,pi/8..pi-2*pi/9]]
|
||||
. flip (foldr ($)) [bpath a | a <- [0,pi/8..pi-2*pi/9]]
|
||||
)
|
||||
<&> rmLinks %~ setInLinksByType (PolyEdge 0)
|
||||
<&> rmLinks %~ setOutLinksByType (PolyEdge (npoly `div` 2))
|
||||
)
|
||||
rToOnward "lasCenRunClose" $ return $ cleatOnward r
|
||||
where
|
||||
awall x v = heightWallPS (PS x 0) 30 v
|
||||
--angwall a = awall (V2 0 100 + rotateV a (V2 0 100)) (fmap (rotateV (pi/4 + a/2)) $ rectWH 5 (25 - a*10/pi ))
|
||||
rf = 0.8
|
||||
offxy = V2 0 (-100)
|
||||
angwall a = awall (V2 0 100 + rotateV a (V2 0 100)) (fmap (rotateV (pi/4 + a*rf)) $ rectWH 5 (23 - a*13/pi ))
|
||||
apath a' = addNodesCrossing $ (\x -> (x + f (V2 0 100),x - f (V2 0 100))) (V2 0 100 + rotateV a (V2 0 100))
|
||||
where
|
||||
a = a' + pi/16
|
||||
f = rotateV (pi/4 + a *0.8)
|
||||
bngwall a = awall (V2 0 (-100) + rotateV a (V2 0 (-100))) (fmap (rotateV (pi/4 + a*rf)) $ rectWH 5 (23 - a*13/pi ))
|
||||
bpath a' = addNodesCrossing $ (\x -> (x + f (V2 0 100),x - f (V2 0 100))) (V2 0 (-100) + rotateV a (V2 0 (-100)))
|
||||
where
|
||||
a = a' + pi/16
|
||||
f = rotateV (pi/4 + a *0.8)
|
||||
|
||||
lasRunYinYangCenter :: (RandomGen g) => State g (MetaTree Room String)
|
||||
lasRunYinYangCenter = do
|
||||
npoly <- takeOne [6,8,10,12]
|
||||
thelight <- mntLightLnkCond $ rprBool $ const . isInLnk
|
||||
thelight1 <- mntLightLnkCond $ rprBool $ const . isOutLnk
|
||||
|
||||
Reference in New Issue
Block a user