Improve creature turning wrt inertia
This commit is contained in:
@@ -133,12 +133,19 @@ isAnimate :: Creature -> Bool
|
||||
{-# INLINE isAnimate #-}
|
||||
isAnimate cr = case _crActionPlan cr of
|
||||
Inanimate -> False
|
||||
SlimeIntelligence -> False
|
||||
SlimeIntelligence -> True
|
||||
ActionPlan{} -> True
|
||||
|
||||
hasAutoDoorBody :: Creature -> Bool
|
||||
hasAutoDoorBody cr = case cr ^. crHP of
|
||||
HP {} -> True
|
||||
CrIsCorpse {} -> True
|
||||
CrDestroyed {} -> False
|
||||
hasAutoDoorBody cr = crittype && notdestroyed
|
||||
where
|
||||
notdestroyed = case cr ^. crHP of
|
||||
HP {} -> True
|
||||
CrIsCorpse {} -> True
|
||||
CrDestroyed {} -> False
|
||||
crittype = case cr ^. crType of
|
||||
SlimeCrit {} -> False
|
||||
BeeCrit {} -> False
|
||||
HiveCrit {} -> False
|
||||
_ -> True
|
||||
|
||||
|
||||
Reference in New Issue
Block a user