Move towards inputs in terminal
This commit is contained in:
@@ -4,6 +4,7 @@ module Dodge.Render.HUD
|
||||
) where
|
||||
import Dodge.Data
|
||||
import Dodge.Combine
|
||||
import Dodge.Clock
|
||||
import Dodge.Base
|
||||
--import Dodge.Combine.Combinations
|
||||
import Dodge.Inventory
|
||||
@@ -15,6 +16,7 @@ import Geometry
|
||||
import Padding
|
||||
import ListHelp
|
||||
|
||||
import qualified Data.Vector as V
|
||||
--import Data.Foldable
|
||||
import Data.Maybe
|
||||
import qualified Data.IntMap.Strict as IM
|
||||
@@ -81,9 +83,10 @@ subInventoryDisplay subinv cfig w = case subinv of
|
||||
, invHead cfig "TWEAK"
|
||||
, listTextPicturesAt subInvX 60 cfig $ map text (ammoTweakStrings it)
|
||||
]
|
||||
DisplayTerminal {_termParams = tp} -> pictures
|
||||
[ invHead cfig (_termTitle tp)
|
||||
DisplayTerminal {_termParams = tp,_termID = tid} -> pictures
|
||||
[ invHead cfig (_termTitle tp ++ ":T" ++ show tid)
|
||||
, renderListAt subInvX 60 cfig
|
||||
. displayTermInput tp
|
||||
. (++ (map (\(str,_) -> (str,white)) (_termOptions tp)))
|
||||
. reverse
|
||||
. take (_termMaxLines tp)
|
||||
@@ -118,6 +121,9 @@ subInventoryDisplay subinv cfig w = case subinv of
|
||||
]
|
||||
InspectInventory -> invHead cfig "INSPECT"
|
||||
where
|
||||
displayTermInput tp = case _termInput tp of
|
||||
Nothing -> id
|
||||
Just (s,_) -> (++ [('>':s++clockCycle 10 (V.fromList ["_",""]) w,white)])
|
||||
closeobjectcursor = case selectedCloseObject w of
|
||||
Nothing -> mempty
|
||||
Just (i,co) -> listCursorNS clObjFloatIn 0 cfig (selNumPos i w) (closeObjectCol co) topInvW (invSelSize i w)
|
||||
|
||||
Reference in New Issue
Block a user