Пример #1
0
 public boolean contains(BlockPos pos) {
   BlockPos from = cluster.getFrom();
   if (pos.getX() < from.getX() || pos.getY() < from.getY() || pos.getZ() < from.getZ()) {
     return false;
   }
   BlockPos to = cluster.getTo();
   if (pos.getX() >= to.getX() || pos.getY() >= to.getY() || pos.getZ() >= to.getZ()) {
     return false;
   }
   return true;
 }
Пример #2
0
 @Override
 public boolean isSideSolid(BlockPos pos, EnumFacing side, boolean _default) {
   return contains(pos) ? cluster.getWorld().isSideSolid(pos, side, _default) : _default;
 }
Пример #3
0
 @Override
 public WorldType getWorldType() {
   return cluster.getWorld().getWorldType();
 }
Пример #4
0
 @Override
 public int getStrongPower(BlockPos pos, EnumFacing direction) {
   return contains(pos) ? cluster.getWorld().getStrongPower(pos, direction) : 0;
 }
Пример #5
0
 @Override
 public Biome getBiomeGenForCoords(BlockPos pos) {
   return cluster.getWorld().getBiomeGenForCoords(pos); // no idea what this does or what to return
 }
Пример #6
0
 @Override
 public boolean isAirBlock(BlockPos pos) {
   return contains(pos) ? cluster.getWorld().isAirBlock(pos) : true;
 }
Пример #7
0
 @Override
 public IBlockState getBlockState(BlockPos pos) {
   return contains(pos) ? cluster.getWorld().getBlockState(pos) : Blocks.AIR.getDefaultState();
 }
Пример #8
0
 @Override
 public int getCombinedLight(BlockPos pos, int lightValue) {
   return contains(pos) ? cluster.getWorld().getCombinedLight(pos, lightValue) : 200;
 }
Пример #9
0
 @Override
 public TileEntity getTileEntity(BlockPos pos) {
   return contains(pos) ? cluster.getWorld().getTileEntity(pos) : null;
 }