Examples of CocoaPlantSize


Examples of org.bukkit.material.CocoaPlant.CocoaPlantSize

        if (height > 5 && random.nextInt(5) == 0) {
            for (int y = 0; y < 2; y++) {
                for (int i = 0; i < 4; i++) {         // rotate the 4 trunk faces
                    if (random.nextInt(4 - y) == 0) { // higher it is, more chances there is
                        final BlockFace face = getCocoaFace(i);
                        final CocoaPlantSize size = getCocoaSize(random.nextInt(3));
                        final Block block = delegate.getBlockState(loc.getWorld(), sourceX, sourceY + height - 5 + y, sourceZ)
                                .getBlock().getRelative(face);
                        delegate.setTypeAndData(loc.getWorld(), block.getX(), block.getY(), block.getZ(),
                                Material.COCOA, new CocoaPlant(size, face.getOppositeFace()));
                    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.