Move around ammo source checks
This commit is contained in:
@@ -17,14 +17,6 @@ import Data.Aeson.TH
|
||||
import Dodge.Data.Item.Use.Consumption.Ammo
|
||||
import Dodge.Data.Item.Use.Consumption.LoadAction
|
||||
|
||||
data HeldConsumption
|
||||
= LoadableAmmo
|
||||
{ _laAmmoType :: AmmoType
|
||||
, _laSourceType :: AmmoSourceType
|
||||
}
|
||||
| NoConsumption
|
||||
deriving (Eq, Show, Read) --Generic, Flat)
|
||||
|
||||
data ReloadStatus = ReloadStatus
|
||||
{ _iaMax :: Int
|
||||
, _iaLoaded :: Int
|
||||
@@ -54,11 +46,9 @@ newtype ItAmount = ItAmount {_getItAmount :: Int}
|
||||
-- deriving stock (Generic)
|
||||
-- deriving anyclass (Flat)
|
||||
|
||||
makeLenses ''HeldConsumption
|
||||
makeLenses ''LeftConsumption
|
||||
makeLenses ''ItAmount
|
||||
makeLenses ''ReloadStatus
|
||||
deriveJSON defaultOptions ''ReloadStatus
|
||||
deriveJSON defaultOptions ''HeldConsumption
|
||||
deriveJSON defaultOptions ''LeftConsumption
|
||||
deriveJSON defaultOptions ''ItAmount
|
||||
|
||||
@@ -34,25 +34,12 @@ data ProjectileUpdate
|
||||
| PJRemoteShellCollisionCheck
|
||||
deriving (Show, Eq, Ord, Read) --Generic, Flat)
|
||||
|
||||
data AmmoSourceType
|
||||
= BulletSource
|
||||
| ChargeSource
|
||||
| ChemfuelSource
|
||||
| BombSource
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data AmmoType
|
||||
= ProjectileAmmo
|
||||
| SmallBulletAmmo
|
||||
| LargeBulletAmmo
|
||||
| BulletAmmo
|
||||
| ElectricalAmmo
|
||||
| DroneAmmo
|
||||
| GasAmmo
|
||||
{ _amCreateGas :: GasCreate
|
||||
}
|
||||
| ForceFieldAmmo
|
||||
{ _amForceFieldType :: ForceFieldType
|
||||
}
|
||||
| GenericAmmo
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data ForceFieldType = DefaultForceField
|
||||
@@ -69,4 +56,3 @@ deriveJSON defaultOptions ''ProjectileUpdate
|
||||
deriveJSON defaultOptions ''GasCreate
|
||||
deriveJSON defaultOptions ''ForceFieldType
|
||||
deriveJSON defaultOptions ''AmmoType
|
||||
deriveJSON defaultOptions ''AmmoSourceType
|
||||
|
||||
Reference in New Issue
Block a user