Add support for group placements
This commit is contained in:
@@ -9,7 +9,7 @@ import Control.Lens
|
||||
import Control.Monad.State
|
||||
import System.Random
|
||||
|
||||
data PSType = PutCrit Creature
|
||||
data PSType = PutCrit {_unPutCrit :: Creature}
|
||||
| PutLS LightSource Picture
|
||||
| PutButton Button
|
||||
| PutFlIt Item
|
||||
@@ -34,10 +34,12 @@ data Placement
|
||||
= SinglePlacement {_placementSpot :: PlacementSpot }
|
||||
| GroupedPlacement
|
||||
{_groupPlacementID :: Int
|
||||
,_groupPlacementFunc :: [PlacementSpot] -> PlacementSpot -> PlacementSpot
|
||||
,_groupPlacementFunc :: [PSType] -> PSType -> World -> World
|
||||
,_placementSpot :: PlacementSpot
|
||||
}
|
||||
|
||||
sPS p a = SinglePlacement . PS p a
|
||||
|
||||
makeLenses ''PSType
|
||||
makeLenses ''PlacementSpot
|
||||
makeLenses ''Placement
|
||||
|
||||
Reference in New Issue
Block a user