Skip to content

API reference / @jsprismarine/chunkgen / FeaturePatchOutOfRangeError

Class: FeaturePatchOutOfRangeError ​

Defined in: FeaturePatch.ts:39

Raised when a feature pass offers a patch to a chunk it is not allowed to write into.

features has a block write radius of 1, so the only legal targets are the eight neighbors. Its own chunk is not one of them: a feature's writes into its own chunk apply as they happen, the way Java's do, so that features inside a chunk still see each other. A patch aimed at (0, 0) means the caller routed a write that should have landed immediately, and a patch from further out means a feature reached past the write radius the step table gives it.

Extends ​

  • RangeError

Constructors ​

Constructor ​

new FeaturePatchOutOfRangeError(dx, dz): FeaturePatchOutOfRangeError

Defined in: FeaturePatch.ts:42

Parameters ​

dx ​

number

dz ​

number

Returns ​

FeaturePatchOutOfRangeError

Overrides ​

RangeError.constructor

Properties ​

dx ​

readonly dx: number

Defined in: FeaturePatch.ts:43


dz ​

readonly dz: number

Defined in: FeaturePatch.ts:44


name ​

name: string = 'FeaturePatchOutOfRangeError'

Defined in: FeaturePatch.ts:40

Overrides ​

RangeError.name