Cleanup
This commit is contained in:
+2
-1
@@ -12,6 +12,7 @@ import Geometry
|
||||
import LensHelp
|
||||
import Color
|
||||
|
||||
import qualified Data.IntMap.Strict as IM
|
||||
import Control.Monad.State
|
||||
import System.Random
|
||||
|
||||
@@ -35,7 +36,7 @@ sparkDam
|
||||
-> World
|
||||
sparkDam sk sp ep mayEiCrWl = case mayEiCrWl of
|
||||
(hitp,Left cr) -> creatures . ix (_crID cr) . crState . csDamage .:~ thedam hitp
|
||||
(hitp,Right wl) -> wallDamages . ix (_wlID wl) .:~ thedam hitp
|
||||
(hitp,Right wl) -> wallDamages %~ IM.insertWith (++) (_wlID wl) [thedam hitp]
|
||||
where
|
||||
thedam hitp = Damage (_skDamageType sk) 1 sp hitp ep NoDamageEffect
|
||||
|
||||
|
||||
Reference in New Issue
Block a user