This commit is contained in:
2021-12-11 19:44:48 +00:00
parent c847955b7c
commit 7116129a37
15 changed files with 21 additions and 41 deletions
+2 -2
View File
@@ -33,7 +33,6 @@ tryMeleeAttack cr tcr
| _crMeleeCooldown cr == 0
&& dist (_crPos tcr) cpos < _crRad cr + _crRad tcr + 5
&& abs (_crDir cr - argV (_crPos tcr -.- cpos)) < pi/4
-- = cr & crActionPlan . crStrategy .~ StrategyActions MeleeStrike meleeActions
= cr & crActionPlan . crImpulse .~ [Melee $ _crID tcr]
| otherwise = cr
where
@@ -117,7 +116,8 @@ reloadOverride cr
where
reloadActions =
[ holsterWeapon
, WaitThen 1 $ DoActionWhileInterrupt NoAction crIsReloading (DoImpulses [ChangeStrategy WatchAndWait])
, 1 `WaitThen`
DoActionWhileInterrupt NoAction crIsReloading (DoImpulses [ChangeStrategy WatchAndWait])
]
overrideInternal :: (Creature -> Bool) -> (Creature -> Creature) -> Creature -> Creature