Only display combinations for first items in list

This commit is contained in:
2024-09-08 21:00:16 +01:00
parent 4de15d2c21
commit db4a6a10de
16 changed files with 192 additions and 76 deletions
+58 -13
View File
@@ -1,18 +1,18 @@
/home/justin/Haskell/loop/src/Dodge/Combine.hs:37:1-20: warning: [-Wunused-top-binds]
Defined but not used: invertInventoryToMap
/home/justin/Haskell/loop/src/Dodge/Combine.hs:31:1-15: warning: [-Wunused-top-binds]
Defined but not used: invertInventory
|
37 | invertInventoryToMap =
| ^^^^^^^^^^^^^^^^^^^^
31 | invertInventory =
| ^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Combine.hs:43:1-14: warning: [-Wunused-top-binds]
Defined but not used: splitItAmounts
|
43 | splitItAmounts = concatMap f
| ^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Combine.hs:48:1-21: warning: [-Wunused-top-binds]
Defined but not used: groupSplitItemAmounts
/home/justin/Haskell/loop/src/Dodge/Combine.hs:53:1-18: warning: [-Wunused-top-binds]
Defined but not used: flatSplitItAmounts
|
48 | groupSplitItemAmounts = M.foldrWithKey f []
| ^^^^^^^^^^^^^^^^^^^^^
53 | flatSplitItAmounts = concatMap f
| ^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Combine.hs:58:1-11: warning: [-Wunused-top-binds]
Defined but not used: lookupItems
|
@@ -23,27 +23,72 @@
|
9 | import Data.Bifunctor
| ^^^^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Grammar.hs:3:1: warning: [-Wunused-imports]
/home/justin/Haskell/loop/src/Dodge/Render/HUD.hs:237:15-18: warning: [-Wunused-matches]
Defined but not used: cfig
|
237 | combineCounts cfig w = foldMap f . group
| ^^^^
/home/justin/Haskell/loop/src/Dodge/Render/HUD.hs:237:20: warning: [-Wunused-matches]
Defined but not used: w
|
237 | combineCounts cfig w = foldMap f . group
| ^
/home/justin/Haskell/loop/src/Dodge/Item/Amount.hs:3:1-19: warning: [-Wunused-imports]
The import of Control.Lens is redundant
|
3 | import Control.Lens
| ^^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Amount.hs:4:1-17: warning: [-Wunused-imports]
The import of Data.Maybe is redundant
|
4 | import Data.Maybe
| ^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Amount.hs:8:15-16: warning: [-Wunused-matches]
Defined but not used: it
|
8 | itStackAmount it = 1 -- fromMaybe 1 $ it ^? itUse . useAmount
| ^^
/home/justin/Haskell/loop/src/Dodge/Inventory/CheckSlots.hs:7:1-19: warning: [-Wunused-imports]
The import of Control.Lens is redundant
|
7 | import Control.Lens
| ^^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Inventory/CheckSlots.hs:8:1-17: warning: [-Wunused-imports]
The import of Data.Maybe is redundant
|
8 | import Data.Maybe
| ^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Inventory/CheckSlots.hs:28:14-15: warning: [-Wunused-matches]
Defined but not used: it
|
28 | findItemSlot it inv = maybe 0 ((+ 1) . fst) $ IM.lookupMax inv
| ^^
/home/justin/Haskell/loop/src/Dodge/Item/SlotsTaken.hs:5:1-19: warning: [-Wunused-imports]
The import of Control.Lens is redundant
|
5 | import Control.Lens
| ^^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Grammar.hs:3:1-22: warning: [-Wunused-imports]
The import of Dodge.Data.Item is redundant
|
3 | import Dodge.Data.Item
| ^^^^^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:20:1: warning: [-Wunused-top-binds]
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:20:1-15: warning: [-Wunused-top-binds]
Defined but not used: itemHeldAmmoPic
|
20 | itemHeldAmmoPic itm amit = itemSPic itm <> addAmmoClip itm amit
| ^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:23:1: warning: [-Wunused-top-binds]
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:23:1-11: warning: [-Wunused-top-binds]
Defined but not used: addAmmoClip
|
23 | addAmmoClip itm amit = fromMaybe mempty $ do
| ^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:23:17: warning: [-Wunused-matches]
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:23:17-20: warning: [-Wunused-matches]
Defined but not used: amit
|
23 | addAmmoClip itm amit = fromMaybe mempty $ do
| ^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:24:5: warning: [-Wunused-matches]
/home/justin/Haskell/loop/src/Dodge/Item/Draw/SPic.hs:24:5-7: warning: [-Wunused-matches]
Defined but not used: hit
|
24 | hit <- itm ^? itType . iyBase . ibtHeld