Add skin colors

This commit is contained in:
2022-06-04 12:25:16 +01:00
parent 2b9ad58f6f
commit 602a004e87
14 changed files with 68 additions and 37 deletions
+6 -8
View File
@@ -60,14 +60,13 @@ spawnerCrit = defaultCreature
{ --_crUpdate = stateUpdate $ spawnerAI chaseCrit
_crHP = 300
, _crPict = basicCrPict
, _crSkinColor = blue
, _crInv = IM.empty -- IM.fromList [(0,frontArmour)]
}
& crSkin . skinUpper .~ light4 blue
miniGunCrit :: Creature
miniGunCrit = defaultCreature
{ _crPict = basicCrPict
, _crSkinColor = red
, _crUpdate = defaultImpulsive [sentinelFireType (const shootTillEmpty)]
, _crActionPlan = ActionPlan
{ _crImpulse = []
@@ -84,10 +83,10 @@ miniGunCrit = defaultCreature
, _crHP = 500
, _crMvType = defaultAimMvType
}
& crSkin . skinUpper .~ light4 red
longCrit :: Creature
longCrit = defaultCreature
{ _crPict = basicCrPict
, _crSkinColor = red
-- , _crUpdate = stateUpdate sniperAI
, _crUpdate = defaultImpulsive [sentinelFireType $ const shootTillEmpty]
, _crActionPlan = ActionPlan
@@ -101,10 +100,10 @@ longCrit = defaultCreature
, _crRad = 10
, _crHP = 150
}
& crSkin . skinUpper .~ light4 red
multGunCrit :: Creature
multGunCrit = defaultCreature
{ _crPict = basicCrPict
, _crSkinColor = red
-- , _crUpdate = stateUpdate (twitchMissAI 300 350)
, _crInv = IM.fromList [(0,bangCaneX 4),(1,medkit 100)]
, _crInvSel = 0
@@ -131,6 +130,7 @@ multGunCrit = defaultCreature
, _crGoal = []
}
}
& crSkin . skinUpper .~ light4 red
where
drawwp = DoActionIfElse NoAction (const crIsAiming) (DoActionThen drawWeapon (WaitThen 50 NoAction))
reloadActions =
@@ -152,7 +152,6 @@ startCr = defaultCreature
, _crMvDir = pi/2
, _crID = 0
, _crPict = basicCrPict
, _crSkinColor = black
, _crUpdate = stateUpdate yourControl
, _crRad = 10
, _crMass = 10
@@ -164,6 +163,7 @@ startCr = defaultCreature
, _crFaction = PlayerFaction
, _crMvType = MvWalking yourDefaultSpeed
}
& crSkin . skinUpper .~ light4 black
{- | Items you start with. -}
startInvList :: [Item]
startInvList = [ ]
@@ -202,9 +202,7 @@ inventoryX c = case c of
[ blinkGun
, unsafeBlinkGun
, autoDetector WALLDETECTOR
, effectGun "GIBBER"
(\cr -> addGibsAt (_crSkinColor cr) (_crPos cr)
. addGibsAt (_crSkinColor cr) (_crPos cr))
, effectGun "GIBBER" addCrGibs
]
_ -> []