Add debug to copy to clipboard any clicked-on creature
This commit is contained in:
@@ -29,7 +29,6 @@ import Dodge.Creature.Radius
|
||||
import Dodge.Data.Equipment.Misc
|
||||
import Dodge.Data.AimStance
|
||||
import Control.Lens
|
||||
import Data.List (find)
|
||||
import Data.Maybe
|
||||
import Dodge.Base.Collide
|
||||
import Dodge.Data.World
|
||||
@@ -81,12 +80,9 @@ crStratConMatches strat cr = strat == _apStrategy (_crActionPlan cr)
|
||||
-- this equality check might be slow...
|
||||
|
||||
crAwayFromPost :: Creature -> Bool
|
||||
crAwayFromPost cr = case find sentinelGoal . _apGoal $ _crActionPlan cr of
|
||||
Just (SentinelAt p _) -> dist p (cr ^. crPos . _xy) > 15
|
||||
crAwayFromPost cr = case _apGoal $ _crActionPlan cr of
|
||||
SentinelAt p _ -> dist p (cr ^. crPos . _xy) > 15
|
||||
_ -> False
|
||||
where
|
||||
sentinelGoal (SentinelAt _ _) = True
|
||||
sentinelGoal _ = False
|
||||
|
||||
crInAimStance :: AimStance -> Creature -> Bool
|
||||
crInAimStance as cr = cr ^? crStance . posture == Just Aiming
|
||||
|
||||
Reference in New Issue
Block a user