Split bullet spawning and bouncing/penetration

This commit is contained in:
2022-07-19 15:33:49 +01:00
parent 8ee4d2e0f2
commit 3031f2478c
12 changed files with 32 additions and 25 deletions
+9 -1
View File
@@ -118,6 +118,9 @@ itemCombinations =
hd = HELD
eq = EQUIP
-- so there are two requirements for a module combination: the module slot must
-- exist on the item, and the item must be in the given list below
-- these two requirements should probably be combined
moduleCombinations :: [( ModuleSlot, [Item], [([ItemBaseType],ItemModuleType)] )]
moduleCombinations =
[ ( ModRifleMag
@@ -147,9 +150,14 @@ moduleCombinations =
]
)
, ( ModBullet
, bulletWeapons
, [amod [cr BOUNCEMODULE] BOUNCEBUL
,amod [cr PENMODULE] PENBUL
]
)
, ( ModBulletSpawn
, bulletWeapons
, [amod [cr INCENDIARYMODULE] INCENDBUL
,amod [cr BOUNCEMODULE] BOUNCEBUL
,amod [cr STATICMODULE] STATICBUL
,amod [cr CONCUSSMODULE] CONCUSBUL
]
+3
View File
@@ -61,6 +61,7 @@ data CraftType
| FRAGMODULE
| FLASHMODULE
| BOUNCEMODULE
| PENMODULE
--
| TELEPORTMODULE
| TIMEMODULE
@@ -184,6 +185,7 @@ data ItemModuleType
| MAGNETMAG
| INCENDBUL
| BOUNCEBUL
| PENBUL
| STATICBUL
| CONCUSBUL
| TARGCR
@@ -209,6 +211,7 @@ data Detector
data ModuleSlot
= ModBullet
| ModBulletSpawn
| ModRifleMag
| ModAutoMag
| ModTarget
+1
View File
@@ -19,6 +19,7 @@ moduleModification imt = case imt of
MAGNETMAG -> itUse . useDelay . rateMax .~ 4
INCENDBUL -> itConsumption . laAmmoType . amBullet . buSpawn .~ BulBall IncBall
BOUNCEBUL -> itConsumption . laAmmoType . amBullet . buEffect .~ BounceBullet
PENBUL -> itConsumption . laAmmoType . amBullet . buEffect .~ PenetrateBullet
STATICBUL -> itConsumption . laAmmoType . amBullet . buSpawn .~ BulBall TeslaBall
CONCUSBUL -> itConsumption . laAmmoType . amBullet . buSpawn .~ BulBall ConcBall
TARGCR -> itTargeting .~ targetRBCreature