Start refactor storing items in single intmap, done turrets
More checks required
This commit is contained in:
@@ -39,7 +39,7 @@ tryPutItemInInv cid flit w = do
|
||||
( i
|
||||
, w
|
||||
& cWorld . lWorld . floorItems %~ IM.delete (flit ^. flIt . itID . unNInt)
|
||||
& cWorld . lWorld . creatures . ix cid . crInv %~ IM.insert i it
|
||||
& cWorld . lWorld . creatures . ix cid . crInv . at i ?~ it
|
||||
& updateItLocation i
|
||||
-- I forget whether using "at" rather than "IM.insert" here caused problems
|
||||
-- & cWorld . lWorld . creatures . ix cid . crInv . at i ?~ it
|
||||
|
||||
Reference in New Issue
Block a user