Skip to content

API reference Obsidian.API.World.Generator.Noise

BaseNoise class

A worldgen noise from the worldgen/noise registry, backed by vanilla's BaseNoise.NormalNoise.

public class BaseNoise : INoise, IRegistryResource

In Obsidian.API.

Remarks

Registry instances are unseeded. World generation binds a seeded copy per world with BaseNoise.Bind; sampling an unbound instance lazily binds it as if the world seed were 0.

Constructors

public BaseNoise();

Properties

public required ImmutableArray<double> Amplitudes { get; init; }public required double FirstOctave { get; init; }

Key

public required string Key { get; init; }

Registry key (e.g. minecraft:temperature). Vanilla seeds each noise from a hash of this key.

public double MaxValue { get; }public double MinValue { get; }public string Type { get; }

Methods

Bind(IPositionalRandomFactory)

public BaseNoise Bind(IPositionalRandomFactory worldRandom);

Returns a copy of this noise seeded the way vanilla seeds registry noises for a world; a noise the server seeded already is returned as it is.

Bind(IRandomSource)

public BaseNoise Bind(IRandomSource random);

Returns a copy of this noise seeded from random; a noise the server seeded already is returned as it is.

Bind(NormalNoise)

public BaseNoise Bind(NormalNoise noise);

Returns a copy of this noise backed by noise. Used for vanilla's legacy special cases, where the sampled noise doesn't match the registry parameters.

public void Create();public double GetValue(double x, double y, double z);

On this page