Start unifying heldUse and heldMods

This commit is contained in:
2024-09-15 10:54:24 +01:00
parent cde7bc9aef
commit 6f372109d9
33 changed files with 585 additions and 270 deletions
+88 -83
View File
@@ -1,94 +1,99 @@
/home/justin/Haskell/loop/src/Dodge/Default/Item/Use/AimParams.hs:16:26-45: error:
• Couldn't match expected type Muzzle
with actual type Int -> Muzzle
• Probable cause: Muzzle is applied to too few arguments
In the expression: Muzzle (V2 20 0) 0 0
In the _aimMuzzles field of a record
In the expression:
AimParams
{_aimWeight = 0, _aimTurnSpeed = 1, _aimRange = 0,
_aimZoom = defaultItZoom, _aimStance = OneHand,
_aimHandlePos = V2 3 0, _aimMuzzles = [Muzzle (V2 20 0) 0 0]}
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:(32,25)-(316,68): warning: [-Wincomplete-patterns]
Pattern match(es) are non-exhaustive
In a case alternative:
Patterns not matched:
FireRemoteShellMod
ExplodeRemoteShellMod
DoNothingMod
ForceFieldMod
...
|
16 | , _aimMuzzles = [Muzzle (V2 20 0) 0 0]
| ^^^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:345:12-14: warning: [-Wunused-matches]
Defined but not used: eff
32 | heldEffect effecttype = case effecttype of
| ^^^^^^^^^^^^^^^^^^...
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:325:5-18: warning: [-Wunused-local-binds]
Defined but not used: directedTelPos
|
345 | useAllAmmo eff item cr w = error "use all ammo"
| ^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:345:16-19: warning: [-Wunused-matches]
Defined but not used: item
325 | directedTelPos _ cr w = (p, a)
| ^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:335:1-9: warning: [-Wmissing-signatures]
Top-level binding with no type signature:
gasEffect :: [(LabelDoubleTree ComposeLinkType Item
-> Creature -> World -> World)
-> LabelDoubleTree ComposeLinkType Item
-> Creature
-> World
-> World]
-> LabelDoubleTree ComposeLinkType Item
-> Creature
-> World
-> World
|
345 | useAllAmmo eff item cr w = error "use all ammo"
| ^^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:345:21-22: warning: [-Wunused-matches]
335 | gasEffect = foldl' (&) (overNozzles useGasParams)
| ^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:337:1-15: warning: [-Wmissing-signatures]
Top-level binding with no type signature:
bulletGunEffect :: [(LabelDoubleTree ComposeLinkType Item
-> Creature -> World -> World)
-> LabelDoubleTree ComposeLinkType Item
-> Creature
-> World
-> World]
-> LabelDoubleTree ComposeLinkType Item
-> Creature
-> World
-> World
|
337 | bulletGunEffect = foldl' (&) shootBullet
| ^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:(342,13)-(644,9): warning: [-Wincomplete-patterns]
Pattern match(es) are non-exhaustive
In a case alternative:
Patterns not matched:
TractorMod
FireRemoteShellMod
ExplodeRemoteShellMod
DoNothingMod
...
|
342 | useMod hm = case hm of
| ^^^^^^^^^^...
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:649:5-26: warning: [-Wunused-local-binds]
Defined but not used: increasecycleLasCircle
|
649 | increasecycleLasCircle it = it & itParams . lasCycle %~ (flip mod 2000 . (+ 1))
| ^^^^^^^^^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:651:5-14: warning: [-Wunused-local-binds]
Defined but not used: fLasCircle
|
651 | fLasCircle it = [it & itParams . lasCycle +~ x | x <- [0, 50 .. 1999]]
| ^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:656:5-18: warning: [-Wunused-local-binds]
Defined but not used: directedTelPos
|
656 | directedTelPos _ cr w = (p, a)
| ^^^^^^^^^^^^^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:703:16-18: warning: [-Wunused-matches]
Defined but not used: itm
|
703 | usePjCreationX itm cr = undefined
| ^^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:703:20-21: warning: [-Wunused-matches]
Defined but not used: cr
|
345 | useAllAmmo eff item cr w = error "use all ammo"
| ^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:345:24: warning: [-Wunused-matches]
Defined but not used: w
|
345 | useAllAmmo eff item cr w = error "use all ammo"
| ^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:671:17-19: warning: [-Wunused-matches]
Defined but not used: eff
|
671 | duplicateLoaded eff it cr w = error "duplicateLoaded"
| ^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:671:21-22: warning: [-Wunused-matches]
703 | usePjCreationX itm cr = undefined
| ^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:778:17-18: warning: [-Wunused-matches]
Defined but not used: it
|
671 | duplicateLoaded eff it cr w = error "duplicateLoaded"
| ^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:671:24-25: warning: [-Wunused-matches]
778 | fireRemoteShell it cr w = undefined
| ^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:778:20-21: warning: [-Wunused-matches]
Defined but not used: cr
|
671 | duplicateLoaded eff it cr w = error "duplicateLoaded"
| ^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:671:27: warning: [-Wunused-matches]
778 | fireRemoteShell it cr w = undefined
| ^^
/home/justin/Haskell/loop/src/Dodge/HeldUse.hs:778:23: warning: [-Wunused-matches]
Defined but not used: w
|
671 | duplicateLoaded eff it cr w = error "duplicateLoaded"
| ^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:681:21: warning: [-Wunused-matches]
Defined but not used: n
|
681 | duplicateNumBarrels n eff itm cr w = error "duplicateNumBarrels"
| ^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:681:23-25: warning: [-Wunused-matches]
Defined but not used: eff
|
681 | duplicateNumBarrels n eff itm cr w = error "duplicateNumBarrels"
| ^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:681:27-29: warning: [-Wunused-matches]
Defined but not used: itm
|
681 | duplicateNumBarrels n eff itm cr w = error "duplicateNumBarrels"
| ^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:681:31-32: warning: [-Wunused-matches]
Defined but not used: cr
|
681 | duplicateNumBarrels n eff itm cr w = error "duplicateNumBarrels"
| ^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:681:34: warning: [-Wunused-matches]
Defined but not used: w
|
681 | duplicateNumBarrels n eff itm cr w = error "duplicateNumBarrels"
| ^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:697:24-26: warning: [-Wunused-matches]
Defined but not used: eff
|
697 | duplicateLoadedBarrels eff itm cr = error "duplicateLoadedBarrels"
| ^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:697:28-30: warning: [-Wunused-matches]
Defined but not used: itm
|
697 | duplicateLoadedBarrels eff itm cr = error "duplicateLoadedBarrels"
| ^^^
/home/justin/Haskell/loop/src/Dodge/Item/Weapon/TriggerType.hs:697:32-33: warning: [-Wunused-matches]
Defined but not used: cr
|
697 | duplicateLoadedBarrels eff itm cr = error "duplicateLoadedBarrels"
| ^^
778 | fireRemoteShell it cr w = undefined
| ^