Add PlasmaBalls

This commit is contained in:
2026-03-17 10:45:58 +00:00
parent 0ca3bf33c9
commit 902d8e0c00
9 changed files with 245 additions and 172 deletions
+25
View File
@@ -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