Table of Contents

Class Curve

Namespace
Shard.WorldGen
Assembly
Shard.WorldGen.dll

A piecewise-linear curve defined by (input, output) control points, with clamped ends (inputs below the first / above the last point return that point's output). Ported from the v2 generator's NodeFunction; used by amplitude/offset/curve density nodes. Pass Evaluate(double) as the function argument to those nodes.

public sealed class Curve
Inheritance
Curve
Inherited Members

Methods

AddPoint(double, double)

Add a control point (ignored if one already exists at the same input). Returns this for chaining.

public Curve AddPoint(double input, double output)

Parameters

input double
output double

Returns

Curve

Evaluate(double)

public double Evaluate(double input)

Parameters

input double

Returns

double