Add PlasmaBalls
This commit is contained in:
@@ -40,8 +40,10 @@ module Dodge.Data.LWorld (
|
||||
module Dodge.Data.Wall,
|
||||
module Dodge.Data.WorldEffect,
|
||||
module Dodge.Data.PulseLaser,
|
||||
module Dodge.Data.PlasmaBall,
|
||||
) where
|
||||
|
||||
import Dodge.Data.PlasmaBall
|
||||
import ShapePicture.Data
|
||||
import Dodge.Data.PulseLaser
|
||||
import Dodge.Data.Equipment.Misc
|
||||
@@ -101,6 +103,7 @@ data LWorld = LWorld
|
||||
, _debris :: [Debris]
|
||||
, _projectiles :: IM.IntMap Projectile
|
||||
, _bullets :: [Bullet]
|
||||
, _plasmaBalls :: [PlasmaBall]
|
||||
, _radarSweeps :: [RadarSweep]
|
||||
, _energyBalls :: [EnergyBall]
|
||||
, _flames :: [Flame]
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
{-# LANGUAGE StrictData #-}
|
||||
{-# LANGUAGE TemplateHaskell #-}
|
||||
|
||||
module Dodge.Data.PlasmaBall (
|
||||
module Dodge.Data.PlasmaBall
|
||||
) where
|
||||
|
||||
import Control.Lens
|
||||
import Data.Aeson
|
||||
import Data.Aeson.TH
|
||||
import Geometry.Data
|
||||
|
||||
data PlasmaBall = PBall
|
||||
{ _pbType :: PlasmaBallType
|
||||
, _pbVel :: Point2
|
||||
, _pbPos :: Point2
|
||||
}
|
||||
deriving (Show, Eq, Ord, Read) --Generic, Flat)
|
||||
|
||||
data PlasmaBallType = DefaultPlasma
|
||||
deriving (Show, Eq, Ord, Read) --Generic, Flat)
|
||||
|
||||
makeLenses ''PlasmaBall
|
||||
deriveJSON defaultOptions ''PlasmaBallType
|
||||
deriveJSON defaultOptions ''PlasmaBall
|
||||
@@ -18,10 +18,10 @@ data PulseLaser = PulseLaser
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data PulseBall = PulseBall
|
||||
{ _pbVel :: Point2
|
||||
, _pbPos :: Point2
|
||||
, _pbTimer :: Int
|
||||
, _pbID :: Int
|
||||
{ _pzbVel :: Point2
|
||||
, _pzbPos :: Point2
|
||||
, _pzbTimer :: Int
|
||||
, _pzbID :: Int
|
||||
}
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user