Cleanup
This commit is contained in:
@@ -24,17 +24,14 @@ import RandomHelp
|
||||
import Shape
|
||||
|
||||
makeDoorDebris :: Door -> World -> World
|
||||
--makeDoorDebris dr w = w & makeDebris mt col p
|
||||
makeDoorDebris dr w = w & makeDebris mt p
|
||||
where
|
||||
p2a = lerpP2A (dr ^. drZeroPos) (dr ^. drOnePos) (dr ^. drLerp)
|
||||
p = centroid . fmap fst $ (dr ^. drFootPrint) & each . each %~ shiftPointBy p2a
|
||||
--(mt, col) = fromMaybe (Stone, greyN 0.5) $ do
|
||||
mt = fromMaybe Stone $ do
|
||||
wlids <- w ^? cWorld . lWorld . doors . ix (_drID dr) . drFootPrint
|
||||
((wlid,_),_) <- IM.minViewWithKey wlids
|
||||
wl <- w ^? cWorld . lWorld . walls . ix wlid
|
||||
--return (_wlMaterial wl, _wlColor wl)
|
||||
return $ wl ^. wlMaterial
|
||||
|
||||
makeBlockDebris :: Block -> World -> World
|
||||
|
||||
Reference in New Issue
Block a user