Make creature update an external function
This commit is contained in:
@@ -4,36 +4,16 @@ module Dodge.Creature.ArmourChase
|
||||
) where
|
||||
import Dodge.Data
|
||||
import Dodge.Default
|
||||
--import Dodge.Creature.State
|
||||
import Dodge.Creature.Update
|
||||
import Dodge.Creature.ChaseCrit
|
||||
--import Dodge.Creature.ChainUpdates
|
||||
import Dodge.Creature.ReaderUpdate
|
||||
import Dodge.Creature.Perception
|
||||
--import Dodge.Creature.Impulse
|
||||
import Dodge.Creature.Action
|
||||
import Dodge.Item.Equipment
|
||||
import Dodge.Item.Consumable
|
||||
--import Picture
|
||||
|
||||
import qualified Data.IntMap.Strict as IM
|
||||
import Control.Lens
|
||||
|
||||
flockArmourChaseCrit :: Creature
|
||||
flockArmourChaseCrit = defaultCreature
|
||||
{ _crUpdate = defaultImpulsive
|
||||
[ watchUpdateStrat []
|
||||
, const doStrategyActions
|
||||
, performActions
|
||||
, targetYouWhenCognizant
|
||||
, setTargetMv (\_ -> _targetCr . _crIntention)
|
||||
, flockACC
|
||||
, perceptionUpdate [0]
|
||||
, goToTarget
|
||||
, const overrideMeleeCloseTarget
|
||||
, const (crMeleeCooldown %~ max 0 . subtract 1)
|
||||
]
|
||||
, _crName = "armourChaseCrit"
|
||||
{ _crName = "armourChaseCrit"
|
||||
, _crHP = 300
|
||||
, _crInv = IM.fromList
|
||||
[(0,frontArmour)
|
||||
@@ -49,6 +29,7 @@ flockArmourChaseCrit = defaultCreature
|
||||
, _crGroup = ShieldGroup
|
||||
, _crMvType = defaultChaseMvType
|
||||
}
|
||||
& crType . humanoidAI .~ FlockArmourChaseAI
|
||||
armourChaseCrit :: Creature
|
||||
armourChaseCrit = chaseCrit
|
||||
{ _crName = "armourChaseCrit"
|
||||
|
||||
Reference in New Issue
Block a user