Beispiel #1
0
 @Override
 public void b(NBTTagCompound nbttagcompound) {
   super.b(nbttagcompound);
   flow.writeToNBT(nbttagcompound);
   nbttagcompound.setByte("lDir", lastDir);
   nbttagcompound.setByte("pCol", paintColor);
 }
Beispiel #2
0
 @Override
 public void a(NBTTagCompound nbttagcompound) {
   super.a(nbttagcompound);
   flow.readFromNBT(nbttagcompound);
   lastDir = nbttagcompound.getByte("lDir");
   paintColor = nbttagcompound.getByte("pCol");
 }
Beispiel #3
0
 @Override
 public void setPartBounds(BlockMultipart blockmultipart, int i) {
   if (i == 29) {
     blockmultipart.a(0.25F, 0.25F, 0.25F, 0.75F, 0.75F, 0.75F);
   } else {
     super.setPartBounds(blockmultipart, i);
   }
 }
Beispiel #4
0
  @Override
  protected void readFromPacket(Packet211TileDesc packet211tiledesc) throws IOException {
    if (packet211tiledesc.subId == 10) {
      flow.contents.clear();
      int i = (int) packet211tiledesc.getUVLC();
      for (int j = 0; j < i; j++) {
        flow.contents.add(TubeItem.newFromPacket(packet211tiledesc));
      }

    } else {
      super.readFromPacket(packet211tiledesc);
      paintColor = (byte) packet211tiledesc.getByte();
    }
  }
Beispiel #5
0
 @Override
 public void onHarvestPart(EntityHuman entityhuman, int i) {
   if (i == 29) {
     CoreLib.dropItem(
         world, x, y, z, new ItemStack(RedPowerBase.blockMicro.id, 1, getExtendedID() << 8));
     flow.onRemove();
     if (CoverSides > 0) {
       replaceWithCovers();
     } else {
       deleteBlock();
     }
   } else {
     super.onHarvestPart(entityhuman, i);
   }
 }
Beispiel #6
0
 @Override
 protected void writeToPacket(Packet211TileDesc packet211tiledesc) {
   super.writeToPacket(packet211tiledesc);
   packet211tiledesc.addByte(paintColor);
 }
Beispiel #7
0
 @Override
 @SuppressWarnings("unchecked")
 public void addHarvestContents(ArrayList arraylist) {
   super.addHarvestContents(arraylist);
   arraylist.add(new ItemStack(RedPowerBase.blockMicro.id, 1, getExtendedID() << 8));
 }