Update generate tree to match upstream

This commit is contained in:
dordsor21 2020-12-16 17:20:33 +00:00
parent 3a3bf7382d
commit 61fd8c0de5
No known key found for this signature in database
GPG Key ID: 1E53E88969FFCF0B

View File

@ -301,6 +301,9 @@ public class BukkitWorld extends AbstractWorld {
public boolean generateTree(TreeGenerator.TreeType type, EditSession editSession, BlockVector3 pt) {
World world = getWorld();
TreeType bukkitType = toBukkitTreeType(type);
if (bukkitType == TreeType.CHORUS_PLANT) {
pt = pt.add(0, 1, 0); // bukkit skips the feature gen which does this offset normally, so we have to add it back
}
return type != null && world.generateTree(BukkitAdapter.adapt(world, pt), bukkitType,
new EditSessionBlockChangeDelegate(editSession));
}