Class Preset
A preset combines corridor and wall dimensions, roof and snapshot flags, occupied-block policy, graph-generation controls, palettes, and decoration rules. Display metadata supplies the theme name, description, accent color, and author-assigned difficulty shown in chat panels.
Configured presets are read through PresetCodec and copied into saved maze records. Existing mazes therefore keep their original geometry and theme after configuration reloads. Serialization stores those frozen settings together with the saved graph for regeneration and recovery.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classCollects named settings before publishing an immutable, validated preset.static enumLabels the intended challenge of a theme for display.static enumSelects creation preflight rules for existing terrain. -
Method Summary
Modifier and TypeMethodDescriptionaccent()static Preset.BuilderStarts a named preset whose settings can be supplied without positional arguments.cap()doublestatic Stringcapitalized(String name) ceiling()booleanfloor()static PresetinthashCode()intheight()doublelight()intname()intstatic Presetbooleanroof()booleansnapshot()toString()wall()intint
-
Method Details
-
builder
Starts a named preset whose settings can be supplied without positional arguments.Palette values must be supplied before building. Optional geometry and decoration settings use the same neutral defaults as the configuration reader; theme-specific display metadata and difficulty belong in the preset's YAML configuration.
- Parameters:
name- the persistent preset identifier- Returns:
- a new independently mutable builder
-
capitalized
-
height
public int height() -
read
-
serialize
-
fromMap
-
name
-
pathWidth
public int pathWidth() -
wallThickness
public int wallThickness() -
wallHeight
public int wallHeight() -
roof
public boolean roof() -
snapshot
public boolean snapshot() -
placement
-
generation
-
floor
-
wall
-
ceiling
-
cap
-
capChance
public double capChance() -
lightSpacing
public int lightSpacing() -
light
-
entranceMarker
-
exitMarker
-
displayName
-
description
-
accent
-
difficulty
-
wallInlay
-
inlayChance
public double inlayChance() -
equals
-
hashCode
-
toString
-