public abstract class SurfaceChunkGenerator<T extends class_5284> extends ChunkGenerator
| Modifier and Type | Field and Description |
|---|---|
private static BlockState |
AIR |
private int |
bedrockCeilingHeight |
private int |
bedrockFloorHeight |
protected BlockState |
defaultBlock |
protected BlockState |
defaultFluid |
private static float[] |
field_16649 |
private int |
horizontalNoiseResolution |
private OctavePerlinNoiseSampler |
interpolationNoise |
private OctavePerlinNoiseSampler |
lowerInterpolatedNoise |
private int |
noiseSizeX |
private int |
noiseSizeY |
private int |
noiseSizeZ |
protected ChunkRandom |
random |
private NoiseSampler |
surfaceDepthNoise |
private OctavePerlinNoiseSampler |
upperInterpolatedNoise |
private int |
verticalNoiseResolution |
biomeSource| Constructor and Description |
|---|
SurfaceChunkGenerator(BiomeSource biomeSource,
long seed,
T config,
int horizontalNoiseResolution,
int verticalNoiseResolution,
int worldHeight,
boolean useSimplexNoise) |
| Modifier and Type | Method and Description |
|---|---|
protected double |
bottomInterpolationStart() |
protected void |
buildBedrock(Chunk chunk,
Random random) |
void |
buildSurface(ChunkRegion region,
Chunk chunk) |
protected abstract double |
computeNoiseFalloff(double depth,
double scale,
int y) |
protected abstract double[] |
computeNoiseRange(int x,
int z) |
protected BlockState |
getBlockState(double density,
int y) |
BlockView |
getColumnSample(int x,
int z) |
int |
getHeight(int x,
int z,
Heightmap.Type heightmapType) |
int |
getNoiseSizeY() |
private static double |
method_16571(int int2,
int int3,
int int4) |
private static double |
method_16572(int int2,
int int3,
int int4) |
void |
populateNoise(WorldAccess world,
StructureAccessor accessor,
Chunk chunk)
Generates the base shape of the chunk out of the basic block states as decided by this chunk generator's config.
|
private int |
sampleHeightmap(int x,
int z,
BlockState[] states,
Predicate<BlockState> predicate) |
private double |
sampleNoise(int x,
int y,
int z,
double horizontalScale,
double verticalScale,
double horizontalStretch,
double verticalStretch) |
protected abstract void |
sampleNoiseColumn(double[] buffer,
int x,
int z) |
protected void |
sampleNoiseColumn(double[] buffer,
int x,
int z,
double horizontalScale,
double verticalScale,
double horizontalStretch,
double verticalStretch,
int topInterpolationFactor,
int topEndValue) |
protected double[] |
sampleNoiseColumn(int x,
int z) |
protected double |
topInterpolationStart() |
addStructureReferences, carve, create, generateFeatures, getBiomeSource, getConfig, getDecorationBiome, getEntitySpawnList, getHeightInGround, getHeightOnGround, getMaxY, getSeaLevel, getSpawnHeight, getStructureConfig, hasStructure, hasStructure, locateStructure, populateBiomes, populateEntities, setStructureStarts, spawnEntitiesprivate static final float[] field_16649
private static final BlockState AIR
private final int verticalNoiseResolution
private final int horizontalNoiseResolution
private final int noiseSizeX
private final int noiseSizeY
private final int noiseSizeZ
protected final ChunkRandom random
private final OctavePerlinNoiseSampler lowerInterpolatedNoise
private final OctavePerlinNoiseSampler upperInterpolatedNoise
private final OctavePerlinNoiseSampler interpolationNoise
private final NoiseSampler surfaceDepthNoise
protected final BlockState defaultBlock
protected final BlockState defaultFluid
private final int bedrockFloorHeight
private final int bedrockCeilingHeight
public SurfaceChunkGenerator(BiomeSource biomeSource, long seed, T config, int horizontalNoiseResolution, int verticalNoiseResolution, int worldHeight, boolean useSimplexNoise)
private double sampleNoise(int x,
int y,
int z,
double horizontalScale,
double verticalScale,
double horizontalStretch,
double verticalStretch)
protected double[] sampleNoiseColumn(int x,
int z)
protected void sampleNoiseColumn(double[] buffer,
int x,
int z,
double horizontalScale,
double verticalScale,
double horizontalStretch,
double verticalStretch,
int topInterpolationFactor,
int topEndValue)
protected abstract double[] computeNoiseRange(int x,
int z)
protected abstract double computeNoiseFalloff(double depth,
double scale,
int y)
protected double topInterpolationStart()
protected double bottomInterpolationStart()
public int getHeight(int x,
int z,
Heightmap.Type heightmapType)
getHeight in class ChunkGeneratorpublic BlockView getColumnSample(int x, int z)
getColumnSample in class ChunkGeneratorprivate int sampleHeightmap(int x,
int z,
@Nullable
BlockState[] states,
@Nullable
Predicate<BlockState> predicate)
protected BlockState getBlockState(double density, int y)
protected abstract void sampleNoiseColumn(double[] buffer,
int x,
int z)
public int getNoiseSizeY()
public void buildSurface(ChunkRegion region, Chunk chunk)
buildSurface in class ChunkGeneratorpublic void populateNoise(WorldAccess world, StructureAccessor accessor, Chunk chunk)
populateNoise in class ChunkGeneratorprivate static double method_16572(int int2,
int int3,
int int4)
private static double method_16571(int int2,
int int3,
int int4)