Simplify shockwave damages
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
- Indestructible walls may still produce sparks, dust etc
|
||||
-}
|
||||
module Dodge.Wall.Damage (
|
||||
damageBlocksBy,
|
||||
-- damageBlocksBy,
|
||||
damageWall,
|
||||
) where
|
||||
|
||||
@@ -36,8 +36,3 @@ maybeDestroyDoor :: Int -> World -> World
|
||||
maybeDestroyDoor drid w = case w ^? cWorld . lWorld . doors . ix drid of
|
||||
Just dr | _drHP dr < 1 -> destroyDoor dr w
|
||||
_ -> w
|
||||
|
||||
damageBlocksBy :: Int -> Wall -> World -> World
|
||||
damageBlocksBy x wl = case wl ^? wlStructure . wsBlock of
|
||||
Just blid -> cWorld . lWorld . blocks . ix blid . blHP -~ x
|
||||
Nothing -> id
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
module Dodge.Wall.Draw where
|
||||
module Dodge.Wall.Draw (drawWall) where
|
||||
|
||||
import Dodge.Data.Wall
|
||||
import Picture.Base
|
||||
|
||||
Reference in New Issue
Block a user