Remove temporary light sources as separate entity
This commit is contained in:
@@ -134,7 +134,7 @@ data LWorld = LWorld
|
||||
, _foregroundShapes :: IM.IntMap ForegroundShape
|
||||
, _corpses :: IM.IntMap Corpse
|
||||
, _lightSources :: IM.IntMap LightSource
|
||||
, _tempLightSources :: [TempLightSource]
|
||||
-- , _tempLightSources :: [TempLightSource]
|
||||
, _lights :: [LSParam]
|
||||
, _seenLocations :: IM.IntMap (WdP2, String)
|
||||
, _selLocation :: Int
|
||||
|
||||
@@ -13,18 +13,18 @@ import Geometry
|
||||
data LightSourceDraw = DefaultLightSourceDraw
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data TLSIntensity
|
||||
= ConstantIntensity
|
||||
| TLSFade Point3 Int
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
--data TLSIntensity
|
||||
-- = ConstantIntensity
|
||||
-- | TLSFade Point3 Int
|
||||
-- deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
--
|
||||
--data TLSUpdate
|
||||
-- = DestroyTLS
|
||||
-- | TimerTLS
|
||||
-- | IntensityTLS TLSIntensity
|
||||
-- deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data TLSUpdate
|
||||
= DestroyTLS
|
||||
| TimerTLS
|
||||
| IntensityTLS TLSIntensity
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data LSParam = LSParam
|
||||
data LSParam = LSParam -- LSPosRadCol
|
||||
{ _lsPos :: !Point3
|
||||
, _lsRad :: !Float
|
||||
, _lsCol :: !Point3
|
||||
@@ -39,19 +39,19 @@ data LightSource = LS
|
||||
}
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data TempLightSource = TLS
|
||||
{ _tlsParam :: LSParam
|
||||
, _tlsUpdate :: TLSUpdate --TempLightSource -> Maybe TempLightSource
|
||||
, _tlsTime :: Int
|
||||
}
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
--data TempLightSource = TLS
|
||||
-- { _tlsParam :: LSParam
|
||||
-- , _tlsUpdate :: TLSUpdate --TempLightSource -> Maybe TempLightSource
|
||||
-- , _tlsTime :: Int
|
||||
-- }
|
||||
-- deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
makeLenses ''LSParam
|
||||
makeLenses ''LightSource
|
||||
makeLenses ''TempLightSource
|
||||
--makeLenses ''TempLightSource
|
||||
deriveJSON defaultOptions ''LightSourceDraw
|
||||
deriveJSON defaultOptions ''TLSIntensity
|
||||
deriveJSON defaultOptions ''TLSUpdate
|
||||
--deriveJSON defaultOptions ''TLSIntensity
|
||||
--deriveJSON defaultOptions ''TLSUpdate
|
||||
deriveJSON defaultOptions ''LSParam
|
||||
deriveJSON defaultOptions ''LightSource
|
||||
deriveJSON defaultOptions ''TempLightSource
|
||||
--deriveJSON defaultOptions ''TempLightSource
|
||||
|
||||
Reference in New Issue
Block a user