Add burst fire, tentative inventory locking

This commit is contained in:
2021-12-04 16:05:46 +00:00
parent 30abc318ae
commit cb670bdfd8
16 changed files with 108 additions and 18 deletions
+3
View File
@@ -126,6 +126,9 @@ wheelEvent y w = case (_carteDisplay w, _inventoryMode w) of
| rbDown -> w & carteZoom %~ min 0.75 . max 0.05 . ((1+y*0.1) * )
| otherwise -> w & selLocation %~ (`mod` numLocs) . (+ yi)
(_, TopInventory)
-- functions that modify the inventory should be centralised so that
-- this lock can be sensibly applied, perhaps
| _crInvLock (_creatures w IM.! (_yourID w)) -> w
| rbDown -> case yourItem w ^? _Just . itScroll of
Nothing -> closeObjScrollDir y w
Just f -> w & creatures . ix 0 . crInv . ix (_crInvSel $ you w) %~ f y (you w)