Separate out concrete part of world
This commit is contained in:
@@ -8,9 +8,9 @@ import qualified IntMapHelp as IM
|
||||
|
||||
createWall :: Wall -> World -> (Int,World)
|
||||
createWall wl w = (wlid
|
||||
, w & walls %~ IM.insert wlid newwl
|
||||
, w & cWorld . walls %~ IM.insert wlid newwl
|
||||
& insertWallInZones newwl
|
||||
)
|
||||
where
|
||||
newwl = wl {_wlID = wlid}
|
||||
wlid = IM.newKey $ _walls w
|
||||
wlid = IM.newKey $ _walls (_cWorld w)
|
||||
|
||||
Reference in New Issue
Block a user