public class LargeOakTrunkPlacer extends TrunkPlacer
Modifier and Type | Class and Description |
---|---|
(package private) static class |
LargeOakTrunkPlacer.BranchPosition |
Modifier and Type | Field and Description |
---|---|
static com.mojang.serialization.Codec<LargeOakTrunkPlacer> |
CODEC |
baseHeight, firstRandomHeight, secondRandomHeight
Constructor and Description |
---|
LargeOakTrunkPlacer(int baseHeight,
int firstRandomHeight,
int secondRandomHeight) |
Modifier and Type | Method and Description |
---|---|
List<FoliagePlacer.TreeNode> |
generate(ModifiableTestableWorld world,
Random random,
int trunkHeight,
BlockPos pos,
Set<BlockPos> set,
BlockBox blockBox,
TreeFeatureConfig treeFeatureConfig)
Generates the trunk blocks and return a list of tree nodes to place foliage around
|
private Direction.Axis |
getLogAxis(BlockPos branchStart,
BlockPos branchEnd) |
private int |
getLongestSide(BlockPos offset) |
protected TrunkPlacerType<?> |
getType() |
private boolean |
isHighEnough(int treeHeight,
int height) |
private void |
makeBranches(ModifiableTestableWorld world,
Random random,
int treeHeight,
BlockPos treePos,
List<LargeOakTrunkPlacer.BranchPosition> branches,
Set<BlockPos> set,
BlockBox blockBox,
TreeFeatureConfig config) |
private boolean |
makeOrCheckBranch(ModifiableTestableWorld world,
Random random,
BlockPos start,
BlockPos end,
boolean make,
Set<BlockPos> set,
BlockBox blockBox,
TreeFeatureConfig config) |
private float |
method_27396(int int2,
int int3) |
getHeight, method_27400, method_27401, method_27402, method_27404, method_28904
public static final com.mojang.serialization.Codec<LargeOakTrunkPlacer> CODEC
public LargeOakTrunkPlacer(int baseHeight, int firstRandomHeight, int secondRandomHeight)
protected TrunkPlacerType<?> getType()
getType
in class TrunkPlacer
public List<FoliagePlacer.TreeNode> generate(ModifiableTestableWorld world, Random random, int trunkHeight, BlockPos pos, Set<BlockPos> set, BlockBox blockBox, TreeFeatureConfig treeFeatureConfig)
generate
in class TrunkPlacer
private boolean makeOrCheckBranch(ModifiableTestableWorld world, Random random, BlockPos start, BlockPos end, boolean make, Set<BlockPos> set, BlockBox blockBox, TreeFeatureConfig config)
private int getLongestSide(BlockPos offset)
private Direction.Axis getLogAxis(BlockPos branchStart, BlockPos branchEnd)
private boolean isHighEnough(int treeHeight, int height)
private void makeBranches(ModifiableTestableWorld world, Random random, int treeHeight, BlockPos treePos, List<LargeOakTrunkPlacer.BranchPosition> branches, Set<BlockPos> set, BlockBox blockBox, TreeFeatureConfig config)
private float method_27396(int int2, int int3)