Add connector between terminal button and temrinal display
This commit is contained in:
@@ -389,17 +389,21 @@ drawTerminalDisplay w cfig tid = fold $ do
|
||||
drawTerminalCursorLink :: World -> Config -> Terminal -> Picture
|
||||
drawTerminalCursorLink w cfig tm = fold $ do
|
||||
j <- elemIndex (tm ^. tmButtonID) $ w ^. hud . closeButtons
|
||||
return . translateScreenPos cfig (invDP ^. ldpPos)
|
||||
$ selSecDrawCursor invDP
|
||||
lp <- selNumPos cfig invDP (w^. hud . diSections) 5 j
|
||||
let rp = screenPosAbs cfig (secondColumnLDP ^. ldpPos) - V2 5 10
|
||||
lcol <- selSecSelCol 5 j (w ^. hud . diSections)
|
||||
return $ translateScreenPos cfig (invDP ^. ldpPos)
|
||||
(selSecDrawCursor invDP
|
||||
(BoundaryCursor [North,South,East,West])
|
||||
(w ^. hud . diSections)
|
||||
(Just (5,j))
|
||||
(Just (5,j)))
|
||||
<> lConnectCol (lp + V2 155 0) rp lcol white white
|
||||
|
||||
lnkMidPosInvSelsCol :: Config -> World -> Int -> Color -> [Int] -> Picture
|
||||
lnkMidPosInvSelsCol cfig w i col = fromMaybe mempty . foldMap f
|
||||
where
|
||||
f j = do
|
||||
sss <- w ^? hud . diSections
|
||||
let sss = w ^. hud . diSections
|
||||
combinesss <- w ^? hud . subInventory . ciSections
|
||||
lp <- selNumPos cfig invDP sss 0 j
|
||||
rp <- selNumPos cfig secondColumnLDP combinesss 0 i
|
||||
|
||||
Reference in New Issue
Block a user