Add damage origins

This commit is contained in:
2026-04-24 20:34:20 +01:00
parent 011286ccb5
commit e0e346aade
43 changed files with 535 additions and 449 deletions
+3 -1
View File
@@ -36,6 +36,7 @@ module Dodge.Base.Collide (
crHeight,
) where
import AesonHelp
import Control.Applicative
import Data.Foldable
import qualified Data.IntMap.Strict as IM
@@ -195,7 +196,8 @@ crHeight cr = case cr ^. crHP of
SlimeCrit {_slimeRad = r} -> min 15 r
BeeCrit {} -> 10
HiveCrit {} -> 25
_ -> error "Need to define crHeight for this crType"
BarrelCrit{} -> 20
_ -> error $ "Need to define crHeight for this crType:\n" <> unlines (prettyShort (cr ^. crType))
CrIsCorpse{} -> Just 5
CrDestroyed{} -> Nothing