Tweak mouse over display
This commit is contained in:
@@ -101,7 +101,7 @@ intersectLinefromScreen cfig w a b =
|
||||
$ screenPolygon cfig (w ^. wCam)
|
||||
|
||||
drawCollisionTest :: World -> Picture
|
||||
drawCollisionTest w = fromMaybe mempty $ do
|
||||
drawCollisionTest w = concat $ do
|
||||
a <- w ^. input . heldWorldPos . at ButtonLeft
|
||||
b <- w ^. input . heldWorldPos . at ButtonRight
|
||||
return $
|
||||
@@ -166,7 +166,7 @@ drawCreatureDisplayTexts :: World -> Picture
|
||||
drawCreatureDisplayTexts w = foldMap (creatureDisplayText w) (w ^. cWorld . lWorld . creatures)
|
||||
|
||||
drawPathBetween :: World -> Picture
|
||||
drawPathBetween w = fromMaybe mempty $ do
|
||||
drawPathBetween w = concat $ do
|
||||
sp <- w ^. input . clickPos . at ButtonLeft
|
||||
ep <- w ^. input . clickPos . at ButtonRight
|
||||
let nodepos = (`getNodePos` w)
|
||||
@@ -178,7 +178,7 @@ drawPathBetween w = fromMaybe mempty $ do
|
||||
<> foldMap (color orange . arrow sp) (pointTowardsImpulse sp ep w)
|
||||
|
||||
drawWallsNearYou :: World -> Picture
|
||||
drawWallsNearYou w = fromMaybe mempty $ do
|
||||
drawWallsNearYou w = concat $ do
|
||||
p <- w ^? cWorld . lWorld . creatures . ix 0 . crPos
|
||||
return $ setLayer DebugLayer $ foldMap f $ wlsNearPoint p w
|
||||
where
|
||||
@@ -195,7 +195,7 @@ drawWallsNearCursor w =
|
||||
(a, b) = _wlLine wl
|
||||
|
||||
drawInspectWalls :: World -> Picture
|
||||
drawInspectWalls w = fromMaybe mempty $ do
|
||||
drawInspectWalls w = concat $ do
|
||||
a <- w ^. input . clickPos . at ButtonLeft
|
||||
b <- w ^. input . heldPos . at ButtonLeft
|
||||
return $
|
||||
@@ -215,7 +215,7 @@ drawInspectWall w wl =
|
||||
(a, b) = _wlLine wl
|
||||
|
||||
drawDoorPaths :: World -> Int -> Picture
|
||||
drawDoorPaths w drid = fromMaybe mempty $ do
|
||||
drawDoorPaths w drid = concat $ do
|
||||
paths <- w ^? cWorld . lWorld . doors . ix drid . drObstructs
|
||||
return $ foldMap' (drawPathEdge . (^. penPathEdge)) paths
|
||||
|
||||
|
||||
Reference in New Issue
Block a user