Package buildcraft.core.network

Examples of buildcraft.core.network.PacketPayload$StreamWriter


  }

  // Network
  @Override
  public PacketPayload getPacketPayload() {
    PacketPayload payload = new PacketPayload(new PacketPayload.StreamWriter() {
      @Override
      public void writeData(ByteBuf data) {
        data.writeFloat(animationSpeed);
        tankManager.writeData(data);
      }
View Full Code Here


  }

  /* NETWORK */
  @Override
  public PacketPayload getPacketPayload() {
    PacketPayload payload = new PacketPayload(new PacketPayload.StreamWriter() {
      @Override
      public void writeData(ByteBuf data) {
        tankManager.writeData(data);
      }
    });
View Full Code Here

    }
  }

  @Override
  public PacketPayload getPacketPayload() {
    PacketPayload payload = new PacketPayload(new PacketPayload.StreamWriter() {
      @Override
      public void writeData(ByteBuf data) {
        box.writeToStream(data);
        data.writeBoolean(done);
        Utils.writeUTF(data, currentPattern.getUniqueTag());
View Full Code Here

    }
  }

  @Override
  public PacketPayload getPacketPayload() {
    PacketPayload payload = new PacketPayload(new PacketPayload.StreamWriter() {
      @Override
      public void writeData(ByteBuf buf) {
        buf.writeInt(aimY);
        buf.writeFloat((float) tubeY);
        buf.writeBoolean(powered);
View Full Code Here

    return payload;
  }

  @Override
  public void handleUpdatePacket(PacketUpdate packet) throws IOException {
    PacketPayload payload = packet.payload;
    ByteBuf data = payload.stream;
    aimY = data.readInt();
    tubeY = data.readFloat();
    powered = data.readBoolean();
View Full Code Here

  public void setFilter(final int slot, final Fluid filter) {

    refinery.setFilter(slot, filter);

    if (refinery.getWorldObj().isRemote) {
      PacketPayload payload = new PacketPayload(new PacketPayload.StreamWriter() {
        @Override
        public void writeData(ByteBuf data) {
          data.writeByte(slot);
          data.writeShort(filter != null ? filter.getID() : -1);
        }
View Full Code Here

TOP

Related Classes of buildcraft.core.network.PacketPayload$StreamWriter

Copyright © 2018 www.massapicom. 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.