Java Code Examples for cn.nukkit.block.Block#STILL_LAVA
The following examples show how to use
cn.nukkit.block.Block#STILL_LAVA .
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: PopulatorCaves.java From Jupiter with GNU General Public License v3.0 | 5 votes |
protected boolean isSuitableBlock(int block, int blockAbove, Biome biome) { if (!(biome instanceof CaveBiome)) { return false; } CaveBiome caveBiome = (CaveBiome) biome; if (block == caveBiome.getStoneBlock()) { return true; } if (block == Block.SAND || block == Block.GRAVEL) { return !(blockAbove == Block.WATER || blockAbove == Block.STILL_WATER || blockAbove == Block.LAVA || blockAbove == Block.STILL_LAVA); } if (block == caveBiome.getGroundBlock()) { return true; } if (block == caveBiome.getSurfaceBlock()) { return true; } // Few hardcoded cases if (block == Block.TERRACOTTA) { return true; } if (block == Block.SANDSTONE) { return true; } // TODO: add red sandstone case in Minecraft 1.8 return block == Block.SNOW; }
Example 2
Source File: PopulatorCaves.java From Nukkit with GNU General Public License v3.0 | 5 votes |
protected boolean isSuitableBlock(int block, int blockAbove, Biome biome) { if (!(biome instanceof CaveBiome)) { return false; } CaveBiome caveBiome = (CaveBiome) biome; if (block == caveBiome.getStoneBlock()) { return true; } if (block == Block.SAND || block == Block.GRAVEL) { return !(blockAbove == Block.WATER || blockAbove == Block.STILL_WATER || blockAbove == Block.LAVA || blockAbove == Block.STILL_LAVA); } if (block == caveBiome.getGroundBlock()) { return true; } if (block == caveBiome.getSurfaceBlock()) { return true; } // Few hardcoded cases if (block == Block.TERRACOTTA) { return true; } if (block == Block.SANDSTONE) { return true; } // TODO: add red sandstone case in Minecraft 1.8 return block == Block.SNOW; }
Example 3
Source File: PopulatorLava.java From Jupiter with GNU General Public License v3.0 | 4 votes |
private boolean canFlowInto(int x, int y, int z) { int id = this.level.getBlockIdAt(x, y, z); return id == Block.AIR || id == Block.LAVA || id == Block.STILL_LAVA; }
Example 4
Source File: PopulatorLava.java From Nukkit with GNU General Public License v3.0 | 4 votes |
private boolean canFlowInto(int x, int y, int z) { int id = this.level.getBlockIdAt(x, y, z); return id == Block.AIR || id == Block.LAVA || id == Block.STILL_LAVA; }
Example 5
Source File: AdvancedRouteFinder.java From Actaeon with MIT License | 4 votes |
private boolean canWalkOn(Block block){ return !(block.getId() == Block.LAVA || block.getId() == Block.STILL_LAVA); }
Example 6
Source File: PopulatorLava.java From Nukkit with GNU General Public License v3.0 | 4 votes |
private boolean canFlowInto(int x, int y, int z) { int id = this.level.getBlockIdAt(x, y, z); return id == Block.AIR || id == Block.LAVA || id == Block.STILL_LAVA; }