Tweak gibs
This commit is contained in:
@@ -36,7 +36,8 @@ flockArmourChaseCrit = defaultCreature
|
||||
]
|
||||
, _crName = "armourChaseCrit"
|
||||
, _crHP = 300
|
||||
, _crPict = basicCrPict green
|
||||
, _crPict = basicCrPict
|
||||
, _crSkinColor = green
|
||||
, _crInv = IM.fromList
|
||||
[(0,frontArmour)
|
||||
,(1,medkit 200)
|
||||
|
||||
@@ -21,7 +21,8 @@ import qualified Data.IntMap.Strict as IM
|
||||
|
||||
autoCrit :: Creature
|
||||
autoCrit = defaultCreature
|
||||
{ _crPict = basicCrPict red
|
||||
{ _crPict = basicCrPict
|
||||
, _crSkinColor = red
|
||||
, _crUpdate = defaultImpulsive [sentinelAI]
|
||||
, _crActionPlan = ActionPlan
|
||||
{ _crImpulse = []
|
||||
|
||||
@@ -26,7 +26,8 @@ smallChaseCrit :: Creature
|
||||
smallChaseCrit = chaseCrit
|
||||
{ _crHP = 1
|
||||
, _crRad = 4
|
||||
, _crPict = basicCrPict green
|
||||
, _crPict = basicCrPict
|
||||
, _crSkinColor = green
|
||||
, _crInv = IM.fromList [(0,medkit 200)]
|
||||
, _crCorpse = setDepth 5 $ color (greyN 0.5) $ circleSolid 4
|
||||
}
|
||||
@@ -52,7 +53,8 @@ chaseCrit = defaultCreature
|
||||
]
|
||||
, _crName = "chaseCrit"
|
||||
, _crHP = 150
|
||||
, _crPict = basicCrPict green
|
||||
, _crPict = basicCrPict
|
||||
, _crSkinColor = green
|
||||
, _crInv = IM.fromList [(0,medkit 200)]
|
||||
, _crMeleeCooldown = 0
|
||||
, _crFaction = ColorFaction green
|
||||
|
||||
@@ -24,7 +24,8 @@ import Control.Lens
|
||||
|
||||
launcherCrit :: Creature
|
||||
launcherCrit = defaultCreature
|
||||
{ _crPict = basicCrPict red
|
||||
{ _crPict = basicCrPict
|
||||
, _crSkinColor = red
|
||||
, _crUpdate = defaultImpulsive
|
||||
[ performActions
|
||||
, watchUpdateStrat
|
||||
|
||||
@@ -22,7 +22,8 @@ import Control.Lens
|
||||
|
||||
ltAutoCrit :: Creature
|
||||
ltAutoCrit = defaultCreature
|
||||
{ _crPict = basicCrPict red
|
||||
{ _crPict = basicCrPict
|
||||
, _crSkinColor = red
|
||||
, _crUpdate = defaultImpulsive
|
||||
[ performActions
|
||||
, watchUpdateStrat
|
||||
|
||||
@@ -29,12 +29,11 @@ import ShapePicture
|
||||
import Control.Lens
|
||||
import qualified Data.IntMap.Strict as IM
|
||||
import qualified Data.Vector as V
|
||||
basicCrPict :: Color -- ^ Creature color
|
||||
-> Creature
|
||||
basicCrPict :: Creature
|
||||
-> Configuration
|
||||
-> World
|
||||
-> SPic
|
||||
basicCrPict col cr cfig w =
|
||||
basicCrPict cr cfig w =
|
||||
drawCrEquipment cr
|
||||
<>
|
||||
(basicCrShape col cr
|
||||
@@ -45,6 +44,7 @@ basicCrPict col cr cfig w =
|
||||
]
|
||||
)
|
||||
where
|
||||
col = _crSkinColor cr
|
||||
targetingPic = IM.elems $ IM.mapMaybeWithKey f $ _crInv cr
|
||||
f invid it = fmap (\g -> g invid it cr cfig w) (it ^? itTargeting . tgDraw)
|
||||
|
||||
@@ -240,8 +240,6 @@ shoulderSH = translateSHz 20
|
||||
--waistSH :: Shape -> Shape
|
||||
--waistSH = translateSHz 10
|
||||
|
||||
light4 :: Color -> Color
|
||||
light4 = light . light . light . light
|
||||
|
||||
--drawAwakeLevel
|
||||
-- :: Creature
|
||||
|
||||
@@ -26,7 +26,8 @@ import Control.Monad.State
|
||||
|
||||
pistolCrit :: Creature
|
||||
pistolCrit = defaultCreature
|
||||
{ _crPict = basicCrPict red
|
||||
{ _crPict = basicCrPict
|
||||
, _crSkinColor = red
|
||||
, _crUpdate = defaultImpulsive
|
||||
[ performActions
|
||||
, watchUpdateStrat
|
||||
|
||||
@@ -24,7 +24,8 @@ import Control.Lens
|
||||
|
||||
spreadGunCrit :: Creature
|
||||
spreadGunCrit = defaultCreature
|
||||
{ _crPict = basicCrPict red
|
||||
{ _crPict = basicCrPict
|
||||
, _crSkinColor = red
|
||||
, _crUpdate = defaultImpulsive
|
||||
[performActions
|
||||
,watchUpdateStrat
|
||||
|
||||
@@ -76,7 +76,9 @@ checkDeath cr w
|
||||
where
|
||||
removecr
|
||||
| _crID cr == 0 = (creatures . ix (_crID cr) . crUpdate .~ const id)
|
||||
. addGibsAt (_crPos cr)
|
||||
. (creatures . ix (_crID cr) . crPict .~ const mempty)
|
||||
. addGibsAt (_crSkinColor cr) (_crPos cr)
|
||||
. addGibsAt (_crSkinColor cr) (_crPos cr)
|
||||
| otherwise = creatures . at (_crID cr) .~ Nothing
|
||||
addCorpse = IM.insertNewKey
|
||||
$ uncurryV translate (_crOldPos cr)
|
||||
|
||||
@@ -30,7 +30,8 @@ swarmCrit = defaultCreature
|
||||
, _crHP = 1
|
||||
, _crRad = 2
|
||||
, _crMass = 2
|
||||
, _crPict = basicCrPict yellow
|
||||
, _crPict = basicCrPict
|
||||
, _crSkinColor = yellow
|
||||
, _crCorpse = setDepth 5 $ color (greyN 0.5) $ circleSolid 2
|
||||
, _crFaction = ColorFaction yellow
|
||||
, _crMeleeCooldown = 0
|
||||
|
||||
Reference in New Issue
Block a user