Start simplifying/removing Wall records

This commit is contained in:
2025-10-23 18:11:01 +01:00
parent fc7c4d6468
commit 819f0d37ea
18 changed files with 230 additions and 243 deletions
+6 -2
View File
@@ -29,19 +29,23 @@ data PushSource
data Door = Door
{ _drID :: Int
, _drTrigger :: WdBl
, _drMech :: DrWdWd
, _drUpdate :: DoorUpdate
, _drZeroPos :: (Point2,Float)
, _drOnePos :: (Point2,Float)
, _drLerp :: Float
, _drFootPrint :: IM.IntMap (Point2,Point2)
, _drHP :: Int
, _drSpeed :: Float
, _drPushedBy :: PushSource
, _drPushes :: Maybe Int
, _drMounts :: [MountedObject]
}
data DoorUpdate = DoorDoNothing | DoorLerp {_drLerpSpeed :: Float}
makeLenses ''Door
makeLenses ''DoorUpdate
--deriveJSON defaultOptions ''DoorStatus
deriveJSON defaultOptions ''DoorUpdate
deriveJSON defaultOptions ''PushSource
deriveJSON defaultOptions ''Door
-2
View File
@@ -22,13 +22,11 @@ data Wall = Wall
, _wlColor :: Color
, _wlOpacity :: Opacity
, _wlPathFlag :: S.Set WallFlag
, _wlPathable :: Bool
, _wlPenetrable :: Bool
, _wlBouncy :: Bool
, _wlWalkable :: Bool
, _wlTouchThrough :: Bool
, _wlFireThrough :: Bool
, _wlReflect :: Bool
, _wlUnshadowed :: Bool
, _wlRotateTo :: Bool
, _wlStructure :: WallStructure
-3
View File
@@ -60,12 +60,9 @@ data WdP2f
= WdP2f0
| WdP2fDoorPosition Int
data DrWdWd = DrWdId | DoorLerp
deriveJSON defaultOptions ''ItCrWdWd
deriveJSON defaultOptions ''WdWd
deriveJSON defaultOptions ''WdP2
deriveJSON defaultOptions ''MdWdWd
deriveJSON defaultOptions ''WdBl
deriveJSON defaultOptions ''WdP2f
deriveJSON defaultOptions ''DrWdWd