16 lines
424 B
Haskell
16 lines
424 B
Haskell
module Dodge.Item.SlotsTaken (
|
|
itSlotsTaken,
|
|
) where
|
|
|
|
import Control.Lens
|
|
import Dodge.Data.Item
|
|
import Dodge.Module
|
|
|
|
itSlotsTaken :: Item -> Int
|
|
itSlotsTaken it = moduleSizes it + ceiling (_itInvSize it)
|
|
|
|
--itSlotsTaken :: Item -> Int
|
|
--itSlotsTaken it = case it ^? itUse . useAmount of
|
|
-- Nothing -> moduleSizes it + ceiling (_itInvSize it)
|
|
-- Just i -> moduleSizes it + ceiling (_itInvSize it * fromIntegral i)
|