Skip to main content

RoofHole

A class in Root.Township, Alta.Caves.PluginParts.

Cave generator part that carves a sloping passage linking a cave layer to the next one, using the shape curves of a RoomFixPlugin. Roof holes start at the biggest room, floor holes at the second biggest.

Constructors​

MemberWhat it is
RoofHole()Use ScriptableObject.CreateInstance instead of new; Unity loads the saved ones from assets.

Fields​

4 private and internal fields
MemberWhat it is
private bool isRoofBacking field for IsRoof.
private float noiseScaleBacking field for NoiseScale.
private float noiseValueVariationBacking field for NoiseValueVariation.
private RoomFixPlugin roomFixPluginBacking field for RoomFixPlugin.

Properties​

MemberWhat it is
bool IsRoof { get; }True for a hole in the roof, aimed along the generator's entrance direction. False for a floor hole in a seeded random direction.
float NoiseScale { get; }Noise scale setting (default 0.1). Not read by RoofHoleInstance.
float NoiseValueVariation { get; }Noise variation setting (default 0.1). Not read by RoofHoleInstance.
RoomFixPlugin RoomFixPlugin { get; }The room fix plugin that supplies the room positions, step sizes and shape curves.

Methods​

MemberWhat it is
override IPartInstance GetInstance(PluginInstance plugin)Creates the RoofHoleInstance that does the work.

Used in​

Members of other types that take, return or hold a RoofHole: