Package net.minecraft.world.gen.feature
Class TreeFeature
java.lang.Object
net.minecraft.world.gen.feature.Feature<TreeFeatureConfig>
net.minecraft.world.gen.feature.TreeFeature
public class TreeFeature extends Feature<TreeFeatureConfig>
-
Field Summary
Fields inherited from class net.minecraft.world.gen.feature.Feature
BAMBOO, BASALT_COLUMNS, BASALT_PILLAR, BLOCK_PILE, BLUE_ICE, BONUS_CHEST, CHORUS_PLANT, CORAL_CLAW, CORAL_MUSHROOM, CORAL_TREE, DECORATED, DECORATED_FLOWER, DELTA_FEATURE, DESERT_WELL, DISK, EMERALD_ORE, END_GATEWAY, END_ISLAND, END_SPIKE, FILL_LAYER, FLOWER, FOREST_ROCK, FOSSIL, FREEZE_TOP_LAYER, GLOWSTONE_BLOB, HUGE_BROWN_MUSHROOM, HUGE_FUNGUS, HUGE_RED_MUSHROOM, ICE_PATCH, ICE_SPIKE, ICEBERG, KELP, LAKE, MONSTER_ROOM, NETHER_FOREST_VEGETATION, NETHERRACK_REPLACE_BLOBS, NO_OP, NO_SURFACE_ORE, ORE, RANDOM_BOOLEAN_SELECTOR, RANDOM_PATCH, RANDOM_RANDOM_SELECTOR, RANDOM_SELECTOR, SEA_PICKLE, SEAGRASS, SIMPLE_BLOCK, SIMPLE_RANDOM_SELECTOR, SPRING_FEATURE, TREE, TWISTING_VINES, VINES, VOID_START_PLATFORM, WEEPING_VINES -
Constructor Summary
Constructors Constructor Description TreeFeature(com.mojang.serialization.Codec<TreeFeatureConfig> codec) -
Method Summary
Modifier and Type Method Description static booleancanReplace(TestableWorld testableWorld, BlockPos pos)static booleancanTreeReplace(TestableWorld world, BlockPos pos)private booleangenerate(ModifiableTestableWorld world, Random random, BlockPos pos, Set<BlockPos> logPositions, Set<BlockPos> leavesPositions, BlockBox box, TreeFeatureConfig config)booleangenerate(ServerWorldAccess serverWorldAccess, StructureAccessor structureAccessor, ChunkGenerator chunkGenerator, Random random, BlockPos blockPos, TreeFeatureConfig treeFeatureConfig)static booleanisAirOrLeaves(TestableWorld world, BlockPos pos)private static booleanisDirtOrGrass(TestableWorld world, BlockPos pos)private static booleanisReplaceablePlant(TestableWorld world, BlockPos pos)private static booleanisVine(TestableWorld world, BlockPos pos)private static booleanisWater(TestableWorld world, BlockPos pos)private intmethod_29963(TestableWorld testableWorld, int int2, BlockPos blockPos, TreeFeatureConfig treeFeatureConfig)private VoxelSetplaceLogsAndLeaves(WorldAccess world, BlockBox box, Set<BlockPos> logs, Set<BlockPos> leaves)protected voidsetBlockState(ModifiableWorld world, BlockPos pos, BlockState state)static voidsetBlockStateWithoutUpdatingNeighbors(ModifiableWorld world, BlockPos pos, BlockState state)Methods inherited from class net.minecraft.world.gen.feature.Feature
configure, isDirt, isStone, method_27368, method_27370, method_28627
-
Constructor Details
-
Method Details
-
canTreeReplace
-
isVine
-
isWater
-
isAirOrLeaves
-
isDirtOrGrass
-
isReplaceablePlant
-
setBlockStateWithoutUpdatingNeighbors
public static void setBlockStateWithoutUpdatingNeighbors(ModifiableWorld world, BlockPos pos, BlockState state) -
canReplace
-
generate
private boolean generate(ModifiableTestableWorld world, Random random, BlockPos pos, Set<BlockPos> logPositions, Set<BlockPos> leavesPositions, BlockBox box, TreeFeatureConfig config) -
method_29963
private int method_29963(TestableWorld testableWorld, int int2, BlockPos blockPos, TreeFeatureConfig treeFeatureConfig) -
setBlockState
- Overrides:
setBlockStatein classFeature<TreeFeatureConfig>
-
generate
public final boolean generate(ServerWorldAccess serverWorldAccess, StructureAccessor structureAccessor, ChunkGenerator chunkGenerator, Random random, BlockPos blockPos, TreeFeatureConfig treeFeatureConfig)- Specified by:
generatein classFeature<TreeFeatureConfig>
-
placeLogsAndLeaves
-