Safe Haskell | None |
---|---|
Language | Haskell2010 |
Game.LambdaHack.Content.PlaceKind
Contents
Description
The type of kinds of rooms, halls and passages.
Synopsis
- data PlaceKind = PlaceKind {}
- makeData :: ContentData TileKind -> [PlaceKind] -> ContentData PlaceKind
- data Cover
- data Fence
- data PlaceEntry
- deadEndId :: ContentId PlaceKind
- validateSingle :: PlaceKind -> [Text]
- validateAll :: ContentData TileKind -> [PlaceKind] -> ContentData PlaceKind -> [Text]
Documentation
Parameters for the generation of small areas within a dungeon level.
Constructors
PlaceKind | |
Fields
|
makeData :: ContentData TileKind -> [PlaceKind] -> ContentData PlaceKind Source #
A method of filling the whole area (except for CVerbatim and CMirror, which are just placed in the middle of the area) by transforming a given corner.
Constructors
CAlternate | reflect every other corner, overlapping 1 row and column |
CStretch | fill symmetrically 4 corners and stretch their borders |
CReflect | tile separately and symmetrically quarters of the place |
CVerbatim | just build the given interior, without filling the area |
CMirror | build the given interior in one of 4 mirrored variants |
Instances
The choice of a fence type for the place.
Constructors
FWall | put a solid wall fence around the place |
FFloor | leave an empty space, like the room's floor |
FGround | leave an empty space, like the cave's ground |
FNone | skip the fence and fill all with the place proper |
Instances
data PlaceEntry Source #
Instances
Eq PlaceEntry Source # | |
Defined in Game.LambdaHack.Content.PlaceKind | |
Show PlaceEntry Source # | |
Defined in Game.LambdaHack.Content.PlaceKind Methods showsPrec :: Int -> PlaceEntry -> ShowS # show :: PlaceEntry -> String # showList :: [PlaceEntry] -> ShowS # | |
Generic PlaceEntry Source # | |
Defined in Game.LambdaHack.Content.PlaceKind Associated Types type Rep PlaceEntry :: Type -> Type | |
Binary PlaceEntry Source # | |
Defined in Game.LambdaHack.Content.PlaceKind | |
type Rep PlaceEntry Source # | |
Defined in Game.LambdaHack.Content.PlaceKind type Rep PlaceEntry = D1 ('MetaData "PlaceEntry" "Game.LambdaHack.Content.PlaceKind" "LambdaHack-0.9.5.0-4ovYxwv1jih9UUX4cyhTOG" 'False) (C1 ('MetaCons "PEntry" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (ContentId PlaceKind))) :+: (C1 ('MetaCons "PAround" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (ContentId PlaceKind))) :+: C1 ('MetaCons "PEnd" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (ContentId PlaceKind))))) |
Internal operations
validateSingle :: PlaceKind -> [Text] Source #
Catch invalid place kind definitions. In particular, verify that the top-left corner map is rectangular and not empty.
validateAll :: ContentData TileKind -> [PlaceKind] -> ContentData PlaceKind -> [Text] Source #
Validate all place kinds.