Move sparks into dedicated datatype

This commit is contained in:
2022-07-18 12:15:05 +01:00
parent 13f2255ba7
commit 5495d33389
16 changed files with 99 additions and 104 deletions
+1 -1
View File
@@ -59,7 +59,7 @@ applyIndividualDamage' cr w dm = case _dmType dm of
applyPiercingDamage :: Creature -> Damage -> World -> World
applyPiercingDamage cr dm
| crIsArmouredFrom p cr = colSpark 8 (brightX 10 1.5 orange) p1 (argV (p1 -.- p))
| crIsArmouredFrom p cr = colSpark (brightX 10 1.5 orange) p1 (argV (p1 -.- p))
| otherwise = damageHP cr $ _dmAmount dm
where
p = _dmAt dm