Commit before changing links

This commit is contained in:
2021-11-11 22:51:02 +00:00
parent 8c45a02e46
commit d63c2ac943
11 changed files with 40 additions and 33 deletions
+5 -5
View File
@@ -25,6 +25,7 @@ data PSType = PutCrit {_unPutCrit :: Creature}
| PutDoor Color (World -> Bool) [(Point2,Point2)]
| RandPS (State StdGen PSType)
| PutForeground Shape
| PutWorldUpdate (PlacementSpot -> World -> World)
| PutNothing
| PutID { _putID :: Int}
-- maybe there is a monadic implementation of this?
@@ -34,12 +35,11 @@ data PlacementSpot
, _psLinkShift :: (Point2,Float) -> (Point2,Float)
, _psFallback :: Maybe Placement
}
| PSRoomRand
{ _psRoomRandPointNum :: Int }
| PSRoomRand { _psRoomRandPointNum :: Int }
data Placement = Placement
{ _placementSpot :: PlacementSpot
, _psType :: PSType
, _idPlacement :: Int -> Maybe Placement
{ _plSpot :: PlacementSpot
, _plType :: PSType
, _plIDCont :: Int -> Maybe Placement
}
| PlacementUsingPos Point3 (Point3 -> Placement) -- allows a placement to use a shifted position
| RandomPlacement {_unRandomPlacement :: State StdGen Placement}