Remove duplicated selection/manipulation positions
Needs more testing to make sure it all works properly
This commit is contained in:
@@ -27,14 +27,14 @@ yourSelectedItem w = do
|
||||
|
||||
yourRootItem :: World -> Maybe Item
|
||||
yourRootItem w = do
|
||||
i <- w ^? hud . manObject . imRootSelectedItem
|
||||
i <- w ^? hud . manObject . hiRootSelectedItem
|
||||
--revise1 i <- you w ^? crManipulation . manObject . imRootSelectedItem
|
||||
j <- _crInv (you w) ^? ix i
|
||||
w ^? cWorld . lWorld . items . ix j
|
||||
|
||||
yourRootItemDT :: World -> Maybe (DTree OItem)
|
||||
yourRootItemDT w = do
|
||||
i <- w^?hud. manObject . imRootSelectedItem . unNInt
|
||||
i <- w^?hud. manObject . hiRootSelectedItem . unNInt
|
||||
invIMDT ((\k -> w ^?! cWorld . lWorld . items . ix k) <$> you w ^. crInv) ^? ix i
|
||||
|
||||
yourInv :: World -> NewIntMap InvInt Item
|
||||
|
||||
Reference in New Issue
Block a user