Java Code Examples for cn.nukkit.block.Block#LEAVES2
The following examples show how to use
cn.nukkit.block.Block#LEAVES2 .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: PopulatorTallGrass.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 2
Source File: ObjectTree.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private boolean overridable(int id) { switch (id) { case Block.AIR: case Block.SAPLING: case Block.LOG: case Block.LEAVES: case Block.SNOW_LAYER: case Block.LOG2: case Block.LEAVES2: return true; default: return false; } }
Example 3
Source File: PopulatorFlower.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 4
Source File: PopulatorTallSugarcane.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2) { break; } } return y == 0 ? -1 : ++y; }
Example 5
Source File: PopulatorGrass.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 6
Source File: PopulatorLilyPad.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 7
Source File: PopulatorSugarcane.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2) { break; } } return y == 0 ? -1 : ++y; }
Example 8
Source File: PopulatorCactus.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 9
Source File: PopulatorDeadBush.java From Nukkit with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 10
Source File: PopulatorTallGrass.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 11
Source File: ObjectTree.java From Nukkit with GNU General Public License v3.0 | 5 votes |
protected boolean overridable(int id) { switch (id) { case Block.AIR: case Block.SAPLING: case Block.LOG: case Block.LEAVES: case Block.SNOW_LAYER: case Block.LOG2: case Block.LEAVES2: return true; default: return false; } }
Example 12
Source File: PopulatorFlower.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 13
Source File: PopulatorTallSugarcane.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2) { break; } } return y == 0 ? -1 : ++y; }
Example 14
Source File: PopulatorGrass.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 15
Source File: PopulatorLilyPad.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 16
Source File: PopulatorSugarcane.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2) { break; } } return y == 0 ? -1 : ++y; }
Example 17
Source File: PopulatorCactus.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }
Example 18
Source File: PopulatorDeadBush.java From Jupiter with GNU General Public License v3.0 | 5 votes |
private int getHighestWorkableBlock(int x, int z) { int y; for (y = 127; y >= 0; --y) { int b = this.level.getBlockIdAt(x, y, z); if (b != Block.AIR && b != Block.LEAVES && b != Block.LEAVES2 && b != Block.SNOW_LAYER) { break; } } return y == 0 ? -1 : ++y; }