classpublicPriority 3
RandomCoordinateDoubleSupplier
com.hypixel.hytale.server.worldgen.util.function.RandomCoordinateDoubleSupplier
implements ICoordinateDoubleSupplier
3
Methods
3
Public Methods
1
Fields
1
Constructors
Constructors
public
RandomCoordinateDoubleSupplier(IDoubleRange range)Methods
Public Methods (3)
public
double apply(int seed, int x, int y)@Override
public
double apply(int seed, int x, int y, int z)@Override
public
IDoubleRange getRange()Fields
Protected Fields (1)
protected
IDoubleRange rangeInheritance
Parent
Current
Interface
Child
Use mouse wheel to zoom, drag to pan. Click nodes to navigate.
Related Classes
Used By
Source Code
package com.hypixel.hytale.server.worldgen.util.function;
import com.hypixel.hytale.math.util.HashUtil;
import com.hypixel.hytale.procedurallib.supplier.IDoubleRange;
public class RandomCoordinateDoubleSupplier implements ICoordinateDoubleSupplier {
protected final IDoubleRange range;
public RandomCoordinateDoubleSupplier(IDoubleRange range) {
this.range = range;
}
public IDoubleRange getRange() {
return this.range;
}
@Override
public double apply(int seed, int x, int y) {
return this.range.getValue(HashUtil.random((long)seed, (long)x, (long)y));
}
@Override
public double apply(int seed, int x, int y, int z) {
return this.range.getValue(HashUtil.random((long)seed, (long)x, (long)y, (long)z));
}
}