Randomise volleygun muzzle order

This commit is contained in:
2024-12-21 19:10:34 +00:00
parent 17cb1d8ff8
commit 84821a1531
9 changed files with 326 additions and 297 deletions
+1
View File
@@ -49,6 +49,7 @@ volleyGun i =
& itType .~ HELD (VOLLEYGUN i)
& itAmmoSlots .~ IM.fromList (zip [0..i-1] $ repeat BulletAmmo)
& itUse . heldParams . weaponRepeat .~ [1..i-1]
& itUse . heldUseEffect .~ (RandomiseMuzzleFrames i)
rifle :: Item
rifle =
+15 -7
View File
@@ -6,11 +6,10 @@ module Dodge.Item.Held.Stick (
smg,
) where
import Dodge.SoundLogic.ExternallyGeneratedSounds
import Dodge.Base
import Dodge.Data.Item
import Dodge.Default.Item
--import Dodge.Reloading.Action
import Dodge.SoundLogic.ExternallyGeneratedSounds
import Geometry
import LensHelp
@@ -21,9 +20,18 @@ bangStick i =
& itUse . heldParams . torqueAfter .~ 0.18 + 0.02 * fromIntegral i
& itType .~ HELD (BANGSTICK i)
& itUse . heldDelay . rateMax .~ 8
& itUse . heldAim . aimMuzzles
.~ [Muzzle (V2 10 0) a 0.01 0 DefaultFlareType MuzzleShootBullet (UseExactly 1) 0
| a <- spreadAroundCenter i baseStickSpread]
& itUse . heldAim . aimMuzzles
.~ [ Muzzle
(V2 10 0)
a
0.01
0
DefaultFlareType
MuzzleShootBullet
(UseExactly 1)
0
| a <- spreadAroundCenter i baseStickSpread
]
baseStickSpread :: Float
baseStickSpread = 0.2
@@ -48,13 +56,13 @@ autoPistol :: Item
autoPistol =
pistol
& itUse . heldTriggerType .~ AutoTrigger
& itUse . heldParams . bulGunSound ?~ (tap1S,0)
& itUse . heldParams . bulGunSound ?~ (tap1S, 0)
& itType .~ HELD AUTOPISTOL
machinePistol :: Item
machinePistol =
autoPistol
& itUse . heldDelay .~ WarmUpNoDelay {_warmTime = 0, _warmMax = 50, _warmSound = crankSlowS}
& itUse . heldDelay .~ WarmUpNoDelay{_warmTime = 0, _warmMax = 50, _warmSound = crankSlowS}
& itType .~ HELD MACHINEPISTOL
& itUse . heldParams . recoil .~ 20