Move Proj datatype

This commit is contained in:
2022-07-23 19:12:32 +01:00
parent 9d92cbfb9e
commit 248dec79e4
2 changed files with 34 additions and 31 deletions
+32 -5
View File
@@ -1,8 +1,35 @@
--{-# LANGUAGE TemplateHaskell #-}
--{-# LANGUAGE StrictData #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE StrictData #-}
module Dodge.Data.Projectile where
--import Dodge.Data.Ammo
--import Geometry.Data
--import Control.Lens
import Dodge.Data.Payload
import Dodge.Data.Ammo
import Geometry.Data
import Control.Lens
data ProjectileType = ShellType
data Proj
= RemoteShell
{ _prjPos :: Point2
, _prjStartPos :: Point2
, _prjVel :: Point2
, _prjDraw :: ProjectileDraw
, _prjID :: Int
, _prjPayload :: Payload
, _prjMITID :: Maybe Int
}
| Shell
{ _prjPos :: Point2
, _prjStartPos :: Point2
, _prjVel :: Point2
, _prjAcc :: Point2
, _prjDir :: Float
, _prjSpin :: Float
, _prjDraw :: ProjectileDraw
, _prjID :: Int
, _prjPayload :: Payload
, _prjTimer :: Int
, _prjZ :: Float
, _prjUpdates :: [ProjectileUpdate]
, _prjMITID :: Maybe Int
}
makeLenses ''Proj