Cleanup
This commit is contained in:
@@ -131,7 +131,7 @@ subInventoryDisplay subinv cfig w = case subinv of
|
||||
selcursor' ct = fromMaybe mempty $ ct 0 0 cfig curpos itcol (determineInvSelCursorWidth w) cury <$ it
|
||||
selcursor = selcursor' selcursortype
|
||||
selcursortype
|
||||
| ButtonRight `M.member` _mouseButtons (_cWorld w) = listCursorNESW
|
||||
| ButtonRight `M.member` _mouseButtons w = listCursorNESW
|
||||
| otherwise = listCursorNSW
|
||||
curpos = invSelPos w
|
||||
cury = fromMaybe 1 $ augmentedInvSizes w IM.!? crSel (you w)
|
||||
@@ -140,7 +140,7 @@ subInventoryDisplay subinv cfig w = case subinv of
|
||||
_ -> mempty
|
||||
equipcursors = IM.foldMapWithKey (f yellow) (_crInvEquipped cr)
|
||||
f col invid epos = listTextPictureAt 144 0 cfig (selNumPos invid w) . color col $ text $ eqPosText epos
|
||||
rboptions = if ButtonRight `M.member` _mouseButtons (_cWorld w)
|
||||
rboptions = if ButtonRight `M.member` _mouseButtons w
|
||||
then drawRBOptions cfig w (_rbOptions (_cWorld w))
|
||||
else mempty
|
||||
|
||||
@@ -257,7 +257,7 @@ topCursorTypeWidth ctype width cfig w i
|
||||
determineInvSelCursorWidth :: World -> Int
|
||||
determineInvSelCursorWidth w = case _rbOptions (_cWorld w) of
|
||||
NoRightButtonOptions -> topInvW
|
||||
EquipOptions {} -> if ButtonRight `M.member` _mouseButtons (_cWorld w)
|
||||
EquipOptions {} -> if ButtonRight `M.member` _mouseButtons w
|
||||
then 47
|
||||
else topInvW
|
||||
|
||||
|
||||
@@ -23,6 +23,6 @@ fixedCoordPictures u = case _menuLayers u of
|
||||
|
||||
customMouseCursor :: Configuration -> World -> Picture
|
||||
customMouseCursor cfig w = winScale cfig
|
||||
. uncurryV translate (_mousePos (_cWorld w))
|
||||
. uncurryV translate (_mousePos w)
|
||||
. color white
|
||||
$ pictures [ line [V2 (-5) 0,V2 5 0] , line [V2 0 (-5),V2 0 5] ]
|
||||
|
||||
Reference in New Issue
Block a user