Continue placement refactor
This commit is contained in:
@@ -49,16 +49,12 @@ data PlacementSpot = PS
|
||||
, _psRot :: Float
|
||||
, _psType :: PSType
|
||||
}
|
||||
data Placement
|
||||
= SimplePlacement {_placementSpot :: PlacementSpot }
|
||||
| IDPlacement {_placementSpot :: PlacementSpot, _idPlacement :: Int -> Placement }
|
||||
-- | GroupedPlacement
|
||||
-- {_groupPlacementID :: Int
|
||||
-- ,_groupUpdate :: World -> [Placement] -> World
|
||||
-- ,_placementSpot :: PlacementSpot
|
||||
-- }
|
||||
data Placement = Placement
|
||||
{ _placementSpot :: PlacementSpot
|
||||
, _idPlacement :: Int -> Maybe Placement
|
||||
}
|
||||
sPS :: Point2 -> Float -> PSType -> Placement
|
||||
sPS p a = SimplePlacement . PS p a
|
||||
sPS p a pt = Placement (PS p a pt) (const Nothing)
|
||||
makeLenses ''PSType
|
||||
makeLenses ''PlacementSpot
|
||||
makeLenses ''Placement
|
||||
|
||||
Reference in New Issue
Block a user