Implement targeting launcher shells using separate item

This commit is contained in:
2024-09-29 16:24:26 +01:00
parent 7d72fa3c5d
commit 88c3e02459
36 changed files with 747 additions and 610 deletions
+9 -1
View File
@@ -20,10 +20,16 @@ import Dodge.Data.Payload
data ProjectileDraw = DrawShell | DrawRemoteShell | DrawDrone | DrawBlankProjectile
deriving (Show, Eq, Ord, Enum, Bounded, Read) --Generic, Flat)
data ProjectileHoming
= NoHoming
| HomeUsingRemoteScreen {_phRemoteID :: NewInt ItmInt}
| HomeUsingTargeting {_phTargetingID :: NewInt ItmInt}
deriving (Show, Eq, Ord, Read) --Generic, Flat)
data ProjectileUpdate
= ThrustPU {_pjuStart :: Int, _pjuEnd :: Int}
| StartSpinPU {_pjuTime :: Int, _pjuCID :: Int, _pjuSpinAmound :: Int}
| RemoteDirectionPU {_pjuStart :: Int, _pjuEnd :: Int, _pjuControllerID :: Maybe (NewInt ItmInt)}
| RemoteDirectionPU {_pjuStart :: Int, _pjuEnd :: Int, _pjuControllerID :: ProjectileHoming}
| ReduceSpinPU {_pjuReduceSpin :: Float}
| DestroyPU {_pjuScreenID :: Maybe (NewInt ItmInt), _pjuTimer :: Int}
| TimePU
@@ -50,7 +56,9 @@ data GasCreate = CreatePoisonGas | CreateFlame
makeLenses ''ProjectileUpdate
makeLenses ''AmmoType
makeLenses ''ProjectileHoming
deriveJSON defaultOptions ''GasFuel
deriveJSON defaultOptions ''ProjectileHoming
deriveJSON defaultOptions ''ProjectileDraw
deriveJSON defaultOptions ''ProjectileUpdate
deriveJSON defaultOptions ''GasCreate