Broken implementation of window colours, move towards stencil ceilings
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
module Dodge.Wall.Create where
|
||||
module Dodge.Wall.Create (createWall) where
|
||||
|
||||
import Control.Lens
|
||||
import Dodge.Data.World
|
||||
|
||||
@@ -3,7 +3,7 @@ module Dodge.Wall.Delete (
|
||||
deleteWallID,
|
||||
) where
|
||||
|
||||
import Data.Foldable
|
||||
--import Data.Foldable
|
||||
import Control.Lens
|
||||
import qualified Data.IntSet as IS
|
||||
import Dodge.Data.World
|
||||
@@ -15,15 +15,15 @@ deleteWallID i w =
|
||||
w & cWorld . lWorld . walls %~ IM.delete i
|
||||
& deleteWallFromZones wl
|
||||
where
|
||||
--wl = _walls (_cWorld w) IM.! i
|
||||
wl = w ^?! cWorld . lWorld . walls . ix i
|
||||
|
||||
deleteWall :: Wall -> World -> World
|
||||
deleteWall wl =
|
||||
(cWorld . lWorld . walls %~ IM.delete i)
|
||||
. deleteWallFromZones wl
|
||||
where
|
||||
i = _wlID wl
|
||||
--deleteWall :: Wall -> World -> World
|
||||
--deleteWall wl =
|
||||
-- (cWorld . lWorld . walls %~ IM.delete i)
|
||||
-- . deleteWallFromZones wl
|
||||
-- where
|
||||
-- i = _wlID wl
|
||||
|
||||
deleteWallIDs :: IS.IntSet -> World -> World
|
||||
deleteWallIDs is w = foldl' (flip deleteWall) w $ IM.restrictKeys (w ^. cWorld . lWorld . walls) is
|
||||
deleteWallIDs is w = IS.foldl' (flip deleteWallID) w is
|
||||
--deleteWallIDs is w = foldl' (flip deleteWall) w $ IM.restrictKeys (w ^. cWorld . lWorld . walls) is
|
||||
|
||||
Reference in New Issue
Block a user