Class TreeGrower
java.lang.Object
net.minecraft.world.level.block.grower.TreeGrower
-
Field Summary
Modifier and TypeFieldDescriptionstatic final TreeGrower
static final TreeGrower
static final TreeGrower
static final TreeGrower
static final com.mojang.serialization.Codec<TreeGrower>
static final TreeGrower
private final Optional<ResourceKey<ConfiguredFeature<?,
?>>> private static final Map<String,
TreeGrower> static final TreeGrower
static final TreeGrower
private final Optional<ResourceKey<ConfiguredFeature<?,
?>>> private final String
static final TreeGrower
private final float
private final Optional<ResourceKey<ConfiguredFeature<?,
?>>> private final Optional<ResourceKey<ConfiguredFeature<?,
?>>> private final Optional<ResourceKey<ConfiguredFeature<?,
?>>> static final TreeGrower
private final Optional<ResourceKey<ConfiguredFeature<?,
?>>> -
Constructor Summary
ConstructorDescriptionTreeGrower
(String p_304522_, float p_304600_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304738_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304561_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304433_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304821_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304558_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304488_) TreeGrower
(String p_304408_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304634_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304477_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304753_) -
Method Summary
Modifier and TypeMethodDescriptionprivate ResourceKey<ConfiguredFeature<?,
?>> getConfiguredFeature
(RandomSource p_304525_, boolean p_304410_) private ResourceKey<ConfiguredFeature<?,
?>> getConfiguredMegaFeature
(RandomSource p_304575_) boolean
growTree
(ServerLevel p_304396_, ChunkGenerator p_304672_, BlockPos p_304643_, BlockState p_304439_, RandomSource p_304893_) private boolean
hasFlowers
(LevelAccessor p_304555_, BlockPos p_304465_) private static boolean
isTwoByTwoSapling
(BlockState p_304497_, BlockGetter p_304772_, BlockPos p_304920_, int p_304941_, int p_304932_)
-
Field Details
-
GROWERS
-
CODEC
-
OAK
-
SPRUCE
-
MANGROVE
-
AZALEA
-
BIRCH
-
JUNGLE
-
ACACIA
-
CHERRY
-
DARK_OAK
-
name
-
secondaryChance
private final float secondaryChance -
megaTree
-
secondaryMegaTree
-
tree
-
secondaryTree
-
flowers
-
secondaryFlowers
-
-
Constructor Details
-
TreeGrower
public TreeGrower(String p_304408_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304634_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304477_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304753_) -
TreeGrower
public TreeGrower(String p_304522_, float p_304600_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304738_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304561_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304433_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304821_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304558_, Optional<ResourceKey<ConfiguredFeature<?, ?>>> p_304488_)
-
-
Method Details
-
getConfiguredFeature
@Nullable private ResourceKey<ConfiguredFeature<?,?>> getConfiguredFeature(RandomSource p_304525_, boolean p_304410_) -
getConfiguredMegaFeature
@Nullable private ResourceKey<ConfiguredFeature<?,?>> getConfiguredMegaFeature(RandomSource p_304575_) -
growTree
public boolean growTree(ServerLevel p_304396_, ChunkGenerator p_304672_, BlockPos p_304643_, BlockState p_304439_, RandomSource p_304893_) -
isTwoByTwoSapling
private static boolean isTwoByTwoSapling(BlockState p_304497_, BlockGetter p_304772_, BlockPos p_304920_, int p_304941_, int p_304932_) -
hasFlowers
-