Add a base to blocks
This commit is contained in:
@@ -38,14 +38,6 @@ invisibleWall ps =
|
||||
midWall :: [Point2] -> Placement
|
||||
midWall = heightWallPS (PS 0 0) 50
|
||||
|
||||
--singleBlock :: Point2 -> [Placement]
|
||||
--singleBlock a =
|
||||
-- [ sPS a 0 $
|
||||
-- PutBlock defaultBlock baseBlockPane $
|
||||
-- reverse $
|
||||
-- square 10
|
||||
-- ]
|
||||
|
||||
{-
|
||||
Places a line of blocks between two points.
|
||||
-}
|
||||
@@ -66,17 +58,6 @@ Width 7, also extends out from each point by 7.
|
||||
crystalLine :: Point2 -> Point2 -> Placement
|
||||
crystalLine a = sps0 . PutLineBlock defaultCrystalWall 7 a
|
||||
|
||||
--crystalLine a b = sps0 $ PutWall ps defaultCrystalWall
|
||||
-- where
|
||||
-- ps =
|
||||
-- [ a +.+ left +.+ up
|
||||
-- , (a +.+ left) -.- up
|
||||
-- , (b -.- left) -.- up
|
||||
-- , (b -.- left) +.+ up
|
||||
-- ]
|
||||
-- left = 7 *.* normalizeV (a-.-b)
|
||||
-- up = vNormal left
|
||||
--
|
||||
--{- Places an unbreakable wall between two points.
|
||||
--Depth 15, does not extend wider than points.
|
||||
-- -}
|
||||
@@ -92,14 +73,9 @@ crystalLine a = sps0 . PutLineBlock defaultCrystalWall 7 a
|
||||
-- left = 15 *.* normalizeV (a -.- b)
|
||||
-- up = vNormal left
|
||||
|
||||
--windowLineType :: Point2 -> Point2 -> PSType
|
||||
--windowLineType = PutLineBlock defaultWindow 8
|
||||
|
||||
baseBlockPane :: Wall
|
||||
baseBlockPane = defaultWall & wlOpacity .~ Opaque 17
|
||||
|
||||
-- & wlPathFlag .~ S.fromList [WallBlockVisibility, WallNotAutoOpen]
|
||||
|
||||
-- TODO find home for this
|
||||
{- Replaces instances of a given 'PutID' with 'PSType's drawn from a list. -}
|
||||
replacePutID ::
|
||||
@@ -132,19 +108,6 @@ subZipWith f g xs ys =
|
||||
isPutID :: Int -> Placement -> Bool
|
||||
isPutID i ps = Just i == ps ^? plType . putID
|
||||
|
||||
--putBlockRect' :: Float -> Float -> Placement
|
||||
--putBlockRect' w h =
|
||||
-- ps0jPushPS (aline tl tr) $
|
||||
-- ps0jPushPS (aline tr br) $
|
||||
-- ps0jPushPS (aline br bl) $
|
||||
-- sps0 (aline bl tl)
|
||||
-- where
|
||||
-- tl = V2 (- w) h
|
||||
-- tr = V2 w h
|
||||
-- br = V2 w (- h)
|
||||
-- bl = V2 (- w) (- h)
|
||||
-- aline = PutLineBlock baseBlockPane 9
|
||||
|
||||
putBlockRect :: Float -> Float -> Float -> Float -> [Placement]
|
||||
putBlockRect a x b y = uncurry blockLine <$> loopPairs (rectNSWE b y a x)
|
||||
|
||||
@@ -154,13 +117,6 @@ putBlockV a x b y = uncurry blockLine <$>
|
||||
, (V2 x b, V2 a b)
|
||||
]
|
||||
|
||||
--putBlockC :: Float -> Float -> Float -> Float -> [Placement]
|
||||
--putBlockC a x b y =
|
||||
-- [ blockLine (V2 a b) (V2 a y)
|
||||
-- , blockLine (V2 x b) (V2 a b)
|
||||
-- , blockLine (V2 a y) (V2 x y)
|
||||
-- ]
|
||||
|
||||
putBlockN :: Float -> Float -> Float -> Float -> [Placement]
|
||||
putBlockN a x b y = uncurry blockLine <$>
|
||||
[ (V2 a b, V2 a y)
|
||||
|
||||
Reference in New Issue
Block a user