Defunction-ify item modules, requires more cleanup
This commit is contained in:
@@ -7,6 +7,7 @@ module Dodge.Item.Weapon.BulletGun.Rod
|
||||
, machineGun
|
||||
) where
|
||||
import Dodge.Data
|
||||
import Dodge.Default.Item
|
||||
import Dodge.Item.Weapon.BulletGun.Clip
|
||||
import Dodge.Item.Weapon.InventoryDisplay
|
||||
import Dodge.Particle.HitEffect
|
||||
@@ -41,9 +42,7 @@ import Data.Maybe
|
||||
|
||||
bangRod :: Item
|
||||
bangRod = defaultGun
|
||||
{ _itName = "BANGROD"
|
||||
, _itType = BANGROD
|
||||
, _itParams = BulletShooter
|
||||
{ _itParams = BulletShooter
|
||||
{ _muzVel = 0.8
|
||||
, _rifling = 1
|
||||
, _bore = 2
|
||||
@@ -79,6 +78,7 @@ bangRod = defaultGun
|
||||
, _laReloadTime = 20
|
||||
}
|
||||
}
|
||||
& itType . iyBase .~ BANGROD
|
||||
& itUse . useAim . aimWeight .~ 8
|
||||
& itUse . useAim . aimRange .~ 1
|
||||
& itUse . useAim . aimStance .~ OneHand
|
||||
@@ -90,8 +90,7 @@ baseAMRShape :: Shape
|
||||
baseAMRShape = colorSH orange $ upperPrismPoly 3 $ rectXH 30 2
|
||||
elephantGun :: Item
|
||||
elephantGun = bangRod
|
||||
& itName .~ "ELEPHANTGUN"
|
||||
& itType .~ ELEPHANTGUN
|
||||
& itType . iyBase .~ ELEPHANTGUN
|
||||
& itUse . useAim . aimStance .~ TwoHandTwist
|
||||
& itParams . gunBarrels .~ SingleBarrel 0.05
|
||||
& itDimension . dimSPic .~ (\it -> noPic $ baseAMRShape
|
||||
@@ -112,8 +111,7 @@ elephantGun = bangRod
|
||||
& itParams . torqueAfter .~ 0.1
|
||||
amr :: Item
|
||||
amr = elephantGun
|
||||
& itName .~ "ANTIMATERIELRIFLE"
|
||||
& itType .~ AMR
|
||||
& itType . iyBase .~ AMR
|
||||
& itConsumption . laMax .~ 15
|
||||
& itDimension . dimSPic .~ (\it -> noPic $ baseAMRShape
|
||||
<> makeTinClipAt 0 (V3 10 (-2) 0) it
|
||||
@@ -121,14 +119,12 @@ amr = elephantGun
|
||||
|
||||
autoAmr :: Item
|
||||
autoAmr = amr
|
||||
& itName .~ "AUTOAMR"
|
||||
& itType .~ AUTOAMR
|
||||
& itType . iyBase .~ AUTOAMR
|
||||
& itUse . useMods %~ ((ammoCheckI :) . tail)
|
||||
|
||||
sniperRifle :: Item
|
||||
sniperRifle = elephantGun
|
||||
& itName .~ "SNIPERRIFLE"
|
||||
& itType .~ SNIPERRIFLE
|
||||
& itType . iyBase .~ SNIPERRIFLE
|
||||
& itParams . gunBarrels .~ SingleBarrel 0
|
||||
& itUse . useAim . aimZoom .~ defaultItZoom {_itZoomMax = 0.5, _itZoomMin = 0.5}
|
||||
& itUse . heldScroll .~ zoomLongGun
|
||||
@@ -137,8 +133,7 @@ sniperRifle = elephantGun
|
||||
& itUse . useAim . aimZoom .~ defaultItZoom {_itZoomFac = 1}
|
||||
machineGun :: Item
|
||||
machineGun = bangRod
|
||||
& itName .~ "MACHINEGUN"
|
||||
& itType .~ MACHINEGUN
|
||||
& itType . iyBase .~ MACHINEGUN
|
||||
& itUse .~ (ruseAmmoParamsRate 25 NoHammer
|
||||
[ ammoCheckI
|
||||
, rateIncAB (torqueBeforeAtLeast 0.1 0.1) withTorqueAfter
|
||||
|
||||
Reference in New Issue
Block a user