Add fields to determine an item's inventory position/whether it is held
This commit is contained in:
@@ -14,7 +14,7 @@ import Geometry
|
||||
|
||||
renderInfoListAt :: Float -> Float -> Configuration -> World -> (Point2,[String]) -> Picture
|
||||
renderInfoListAt x y cfig w (p,ss) = renderListAt x y cfig (zip ss (repeat yellow))
|
||||
<> winScale cfig (color yellow $ lConnect (V2 (x-hw) (hh-20-y)) (worldPosToScreen w p))
|
||||
<> winScale cfig (color yellow $ lConnect (V2 (x-hw) (hh-25-y)) (worldPosToScreen w p))
|
||||
<> listCursorNSW x y cfig 0 yellow 19 (length ss)
|
||||
where
|
||||
hw = halfWidth cfig
|
||||
|
||||
@@ -108,9 +108,12 @@ drawPathing cfig w
|
||||
|
||||
crDisplayInfo :: Configuration -> World -> Creature -> Maybe (Point2,[String])
|
||||
crDisplayInfo cfig w cr
|
||||
| _crID cr == 0 = Nothing
|
||||
| crOnScreen = Just (_crPos cr, catMaybes
|
||||
[fmap show $ ap ^? crGoal
|
||||
,fmap show $ ap ^? crStrategy
|
||||
-- [fmap show $ ap ^? crGoal
|
||||
-- ,fmap show $ ap ^? crStrategy
|
||||
[fmap show $ cr ^? crPos
|
||||
,fmap show $ cr ^? crOldPos
|
||||
,fmap show $ ap ^? crAction
|
||||
,fmap show $ ap ^? crImpulse
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user