implement proxy

This commit is contained in:
Sen 2025-06-03 01:22:38 +02:00
parent 13d017e583
commit 97ba13b28c
Signed by: sen
GPG key ID: 3AC50A6F47D1B722
165 changed files with 14880 additions and 3 deletions

View file

@ -11,11 +11,13 @@ repositories {
dependencies {
implementation("io.netty:netty-all:4.0.23.Final")
implementation("com.google.guava:guava:17.0")
implementation("com.google.code.gson:gson:2.2.4")
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
languageVersion = JavaLanguageVersion.of(8)
}
}

View file

@ -0,0 +1,68 @@
package net.minecraft.network.handshake.client;
import java.io.IOException;
import proxy.network.EnumConnectionState;
import proxy.network.NetHandlerHandshake;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C00Handshake implements Packet<NetHandlerHandshake>
{
private int protocolVersion;
private String ip;
private int port;
private EnumConnectionState requestedState;
public C00Handshake()
{
}
public C00Handshake(int version, String ip, int port, EnumConnectionState requestedState)
{
this.protocolVersion = version;
this.ip = ip;
this.port = port;
this.requestedState = requestedState;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.protocolVersion = buf.readVarIntFromBuffer();
this.ip = buf.readStringFromBuffer(255);
this.port = buf.readUnsignedShort();
this.requestedState = EnumConnectionState.getById(buf.readVarIntFromBuffer());
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.protocolVersion);
buf.writeString(this.ip);
buf.writeShort(this.port);
buf.writeVarIntToBuffer(this.requestedState.getId());
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(NetHandlerHandshake handler)
{
handler.processHandshake(this);
}
public EnumConnectionState getRequestedState()
{
return this.requestedState;
}
public int getProtocolVersion()
{
return this.protocolVersion;
}
}

View file

@ -0,0 +1,50 @@
package net.minecraft.network.login.client;
import java.io.IOException;
import proxy.network.NetHandlerLoginServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C00PacketLoginStart implements Packet<NetHandlerLoginServer>
{
private String profile;
public C00PacketLoginStart()
{
}
public C00PacketLoginStart(String profileIn)
{
this.profile = profileIn;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.profile = buf.readStringFromBuffer(16);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.profile);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(NetHandlerLoginServer handler)
{
handler.processLoginStart(this);
}
public String getProfile()
{
return this.profile;
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.login.client;
import java.io.IOException;
import proxy.network.NetHandlerLoginServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C01PacketEncryptionResponse implements Packet<NetHandlerLoginServer>
{
private byte[] secretKeyEncrypted = new byte[0];
private byte[] verifyTokenEncrypted = new byte[0];
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.secretKeyEncrypted = buf.readByteArray();
this.verifyTokenEncrypted = buf.readByteArray();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByteArray(this.secretKeyEncrypted);
buf.writeByteArray(this.verifyTokenEncrypted);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(NetHandlerLoginServer handler)
{
handler.processEncryptionResponse(this);
}
}

View file

@ -0,0 +1,51 @@
package net.minecraft.network.login.server;
import java.io.IOException;
import proxy.network.NetHandlerPlayServer.ProxyLoginHandler;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ChatComponent;
public class S00PacketDisconnect implements Packet<ProxyLoginHandler>
{
private ChatComponent reason;
public S00PacketDisconnect()
{
}
public S00PacketDisconnect(ChatComponent reasonIn)
{
this.reason = reasonIn;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.reason = buf.readChatComponent();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeChatComponent(this.reason);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(ProxyLoginHandler handler)
{
handler.handleDisconnect(this);
}
public ChatComponent func_149603_c()
{
return this.reason;
}
}

View file

@ -0,0 +1,42 @@
package net.minecraft.network.login.server;
import java.io.IOException;
import proxy.network.NetHandlerPlayServer.ProxyLoginHandler;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S01PacketEncryptionRequest implements Packet<ProxyLoginHandler>
{
private String hashedServerId;
private byte[] publicKey;
private byte[] verifyToken;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.hashedServerId = buf.readStringFromBuffer(20);
this.publicKey = buf.readByteArray();
this.verifyToken = buf.readByteArray();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.hashedServerId);
buf.writeByteArray(this.publicKey);
buf.writeByteArray(this.verifyToken);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(ProxyLoginHandler handler)
{
handler.handleEncryptionRequest(this);
}
}

View file

@ -0,0 +1,61 @@
package net.minecraft.network.login.server;
import java.io.IOException;
import java.util.UUID;
import proxy.network.NetHandlerPlayServer.ProxyLoginHandler;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S02PacketLoginSuccess implements Packet<ProxyLoginHandler>
{
private UUID id;
private String name;
public S02PacketLoginSuccess()
{
}
public S02PacketLoginSuccess(UUID id, String name)
{
this.id = id;
this.name = name;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
String s = buf.readStringFromBuffer(36);
this.name = buf.readStringFromBuffer(16);
this.id = UUID.fromString(s);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.id == null ? "" : this.id.toString());
buf.writeString(this.name);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(ProxyLoginHandler handler)
{
handler.handleLoginSuccess(this);
}
public UUID getId()
{
return this.id;
}
public String getName()
{
return this.name;
}
}

View file

@ -0,0 +1,50 @@
package net.minecraft.network.login.server;
import java.io.IOException;
import proxy.network.NetHandlerPlayServer.ProxyLoginHandler;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S03PacketEnableCompression implements Packet<ProxyLoginHandler>
{
private int compressionTreshold;
public S03PacketEnableCompression()
{
}
public S03PacketEnableCompression(int compressionTresholdIn)
{
this.compressionTreshold = compressionTresholdIn;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.compressionTreshold = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.compressionTreshold);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(ProxyLoginHandler handler)
{
handler.handleEnableCompression(this);
}
public int getCompressionTreshold()
{
return this.compressionTreshold;
}
}

View file

@ -0,0 +1,50 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C00PacketKeepAlive implements Packet<INetHandlerPlayServer>
{
private int key;
public C00PacketKeepAlive()
{
}
public C00PacketKeepAlive(int key)
{
this.key = key;
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processKeepAlive(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.key = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.key);
}
public int getKey()
{
return this.key;
}
}

View file

@ -0,0 +1,55 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C01PacketChatMessage implements Packet<INetHandlerPlayServer>
{
private String message;
public C01PacketChatMessage()
{
}
public C01PacketChatMessage(String messageIn)
{
if (messageIn.length() > 100)
{
messageIn = messageIn.substring(0, 100);
}
this.message = messageIn;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.message = buf.readStringFromBuffer(100);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.message);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processChatMessage(this);
}
public String getMessage()
{
return this.message;
}
}

View file

@ -0,0 +1,63 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C02PacketUseEntity implements Packet<INetHandlerPlayServer>
{
private int entityId;
private C02PacketUseEntity.Action action;
private float hitX;
private float hitY;
private float hitZ;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.action = (C02PacketUseEntity.Action)buf.readEnumValue(C02PacketUseEntity.Action.class);
if (this.action == C02PacketUseEntity.Action.INTERACT_AT)
{
this.hitX = buf.readFloat();
this.hitY = buf.readFloat();
this.hitZ = buf.readFloat();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeEnumValue(this.action);
if (this.action == C02PacketUseEntity.Action.INTERACT_AT)
{
buf.writeFloat(this.hitX);
buf.writeFloat(this.hitY);
buf.writeFloat(this.hitZ);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processUseEntity(this);
}
public static enum Action
{
INTERACT,
ATTACK,
INTERACT_AT;
}
}

View file

@ -0,0 +1,118 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C03PacketPlayer implements Packet<INetHandlerPlayServer>
{
protected double x;
protected double y;
protected double z;
protected float yaw;
protected float pitch;
protected boolean onGround;
protected boolean moving;
protected boolean rotating;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processPlayer(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.onGround = buf.readUnsignedByte() != 0;
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.onGround ? 1 : 0);
}
public static class C04PacketPlayerPosition extends C03PacketPlayer
{
public C04PacketPlayerPosition()
{
this.moving = true;
}
public void readPacketData(PacketBuffer buf) throws IOException
{
this.x = buf.readDouble();
this.y = buf.readDouble();
this.z = buf.readDouble();
super.readPacketData(buf);
}
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeDouble(this.x);
buf.writeDouble(this.y);
buf.writeDouble(this.z);
super.writePacketData(buf);
}
}
public static class C05PacketPlayerLook extends C03PacketPlayer
{
public C05PacketPlayerLook()
{
this.rotating = true;
}
public void readPacketData(PacketBuffer buf) throws IOException
{
this.yaw = buf.readFloat();
this.pitch = buf.readFloat();
super.readPacketData(buf);
}
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeFloat(this.yaw);
buf.writeFloat(this.pitch);
super.writePacketData(buf);
}
}
public static class C06PacketPlayerPosLook extends C03PacketPlayer
{
public C06PacketPlayerPosLook()
{
this.moving = true;
this.rotating = true;
}
public void readPacketData(PacketBuffer buf) throws IOException
{
this.x = buf.readDouble();
this.y = buf.readDouble();
this.z = buf.readDouble();
this.yaw = buf.readFloat();
this.pitch = buf.readFloat();
super.readPacketData(buf);
}
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeDouble(this.x);
buf.writeDouble(this.y);
buf.writeDouble(this.z);
buf.writeFloat(this.yaw);
buf.writeFloat(this.pitch);
super.writePacketData(buf);
}
}
}

View file

@ -0,0 +1,53 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class C07PacketPlayerDigging implements Packet<INetHandlerPlayServer>
{
private BlockPos position;
private byte facing;
private C07PacketPlayerDigging.Action status;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.status = (C07PacketPlayerDigging.Action)buf.readEnumValue(C07PacketPlayerDigging.Action.class);
this.position = buf.readBlockPos();
this.facing = (byte)buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeEnumValue(this.status);
buf.writeBlockPos(this.position);
buf.writeByte(this.facing);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processPlayerDigging(this);
}
public static enum Action
{
START_DESTROY_BLOCK,
ABORT_DESTROY_BLOCK,
STOP_DESTROY_BLOCK,
DROP_ALL_ITEMS,
DROP_ITEM,
RELEASE_USE_ITEM;
}
}

View file

@ -0,0 +1,53 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
import proxy.util.ItemStack;
public class C08PacketPlayerBlockPlacement implements Packet<INetHandlerPlayServer>
{
private BlockPos position;
private int placedBlockDirection;
private ItemStack stack;
private float facingX;
private float facingY;
private float facingZ;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.position = buf.readBlockPos();
this.placedBlockDirection = buf.readUnsignedByte();
this.stack = buf.readItemStackFromBuffer();
this.facingX = (float)buf.readUnsignedByte() / 16.0F;
this.facingY = (float)buf.readUnsignedByte() / 16.0F;
this.facingZ = (float)buf.readUnsignedByte() / 16.0F;
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.position);
buf.writeByte(this.placedBlockDirection);
buf.writeItemStackToBuffer(this.stack);
buf.writeByte((int)(this.facingX * 16.0F));
buf.writeByte((int)(this.facingY * 16.0F));
buf.writeByte((int)(this.facingZ * 16.0F));
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processPlayerBlockPlacement(this);
}
}

View file

@ -0,0 +1,36 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C09PacketHeldItemChange implements Packet<INetHandlerPlayServer>
{
private int slotId;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.slotId = buf.readShort();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeShort(this.slotId);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processHeldItemChange(this);
}
}

View file

@ -0,0 +1,32 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C0APacketAnimation implements Packet<INetHandlerPlayServer>
{
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.handleAnimation(this);
}
}

View file

@ -0,0 +1,53 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C0BPacketEntityAction implements Packet<INetHandlerPlayServer>
{
private int entityID;
private C0BPacketEntityAction.Action action;
private int auxData;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityID = buf.readVarIntFromBuffer();
this.action = (C0BPacketEntityAction.Action)buf.readEnumValue(C0BPacketEntityAction.Action.class);
this.auxData = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityID);
buf.writeEnumValue(this.action);
buf.writeVarIntToBuffer(this.auxData);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processEntityAction(this);
}
public static enum Action
{
START_SNEAKING,
STOP_SNEAKING,
STOP_SLEEPING,
START_SPRINTING,
STOP_SPRINTING,
RIDING_JUMP,
OPEN_INVENTORY;
}
}

View file

@ -0,0 +1,57 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C0CPacketInput implements Packet<INetHandlerPlayServer>
{
private float strafeSpeed;
private float forwardSpeed;
private boolean jumping;
private boolean sneaking;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.strafeSpeed = buf.readFloat();
this.forwardSpeed = buf.readFloat();
byte b0 = buf.readByte();
this.jumping = (b0 & 1) > 0;
this.sneaking = (b0 & 2) > 0;
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeFloat(this.strafeSpeed);
buf.writeFloat(this.forwardSpeed);
byte b0 = 0;
if (this.jumping)
{
b0 = (byte)(b0 | 1);
}
if (this.sneaking)
{
b0 = (byte)(b0 | 2);
}
buf.writeByte(b0);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processInput(this);
}
}

View file

@ -0,0 +1,36 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C0DPacketCloseWindow implements Packet<INetHandlerPlayServer>
{
private int windowId;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processCloseWindow(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
}
}

View file

@ -0,0 +1,52 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ItemStack;
public class C0EPacketClickWindow implements Packet<INetHandlerPlayServer>
{
private int windowId;
private int slotId;
private int usedButton;
private short actionNumber;
private ItemStack clickedItem;
private int mode;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processClickWindow(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readByte();
this.slotId = buf.readShort();
this.usedButton = buf.readByte();
this.actionNumber = buf.readShort();
this.mode = buf.readByte();
this.clickedItem = buf.readItemStackFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeShort(this.slotId);
buf.writeByte(this.usedButton);
buf.writeShort(this.actionNumber);
buf.writeByte(this.mode);
buf.writeItemStackToBuffer(this.clickedItem);
}
}

View file

@ -0,0 +1,42 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C0FPacketConfirmTransaction implements Packet<INetHandlerPlayServer>
{
private int windowId;
private short uid;
private boolean accepted;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processConfirmTransaction(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readByte();
this.uid = buf.readShort();
this.accepted = buf.readByte() != 0;
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeShort(this.uid);
buf.writeByte(this.accepted ? 1 : 0);
}
}

View file

@ -0,0 +1,45 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ItemStack;
public class C10PacketCreativeInventoryAction implements Packet<INetHandlerPlayServer>
{
private int slotId;
private ItemStack stack;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processCreativeInventoryAction(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.slotId = buf.readShort();
this.stack = buf.readItemStackFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeShort(this.slotId);
buf.writeItemStackToBuffer(this.stack);
}
public ItemStack getStack()
{
return this.stack;
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C11PacketEnchantItem implements Packet<INetHandlerPlayServer>
{
private int windowId;
private int button;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processEnchantItem(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readByte();
this.button = buf.readByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeByte(this.button);
}
}

View file

@ -0,0 +1,59 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
import proxy.util.ChatComponent;
public class C12PacketUpdateSign implements Packet<INetHandlerPlayServer>
{
private BlockPos pos;
private ChatComponent[] lines;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.pos = buf.readBlockPos();
this.lines = new ChatComponent[4];
for (int i = 0; i < 4; ++i)
{
String s = buf.readStringFromBuffer(384);
ChatComponent ichatcomponent = ChatComponent.Serializer.jsonToComponent(s);
this.lines[i] = ichatcomponent;
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.pos);
for (int i = 0; i < 4; ++i)
{
ChatComponent ichatcomponent = this.lines[i];
String s = ChatComponent.Serializer.componentToJson(ichatcomponent);
buf.writeString(s);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processUpdateSign(this);
}
public ChatComponent[] getLines()
{
return this.lines;
}
}

View file

@ -0,0 +1,121 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C13PacketPlayerAbilities implements Packet<INetHandlerPlayServer>
{
private boolean invulnerable;
private boolean flying;
private boolean allowFlying;
private boolean creativeMode;
private float flySpeed;
private float walkSpeed;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
byte b0 = buf.readByte();
this.setInvulnerable((b0 & 1) > 0);
this.setFlying((b0 & 2) > 0);
this.setAllowFlying((b0 & 4) > 0);
this.setCreativeMode((b0 & 8) > 0);
this.setFlySpeed(buf.readFloat());
this.setWalkSpeed(buf.readFloat());
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
byte b0 = 0;
if (this.isInvulnerable())
{
b0 = (byte)(b0 | 1);
}
if (this.isFlying())
{
b0 = (byte)(b0 | 2);
}
if (this.isAllowFlying())
{
b0 = (byte)(b0 | 4);
}
if (this.isCreativeMode())
{
b0 = (byte)(b0 | 8);
}
buf.writeByte(b0);
buf.writeFloat(this.flySpeed);
buf.writeFloat(this.walkSpeed);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processPlayerAbilities(this);
}
public boolean isInvulnerable()
{
return this.invulnerable;
}
public void setInvulnerable(boolean isInvulnerable)
{
this.invulnerable = isInvulnerable;
}
public boolean isFlying()
{
return this.flying;
}
public void setFlying(boolean isFlying)
{
this.flying = isFlying;
}
public boolean isAllowFlying()
{
return this.allowFlying;
}
public void setAllowFlying(boolean isAllowFlying)
{
this.allowFlying = isAllowFlying;
}
public boolean isCreativeMode()
{
return this.creativeMode;
}
public void setCreativeMode(boolean isCreativeMode)
{
this.creativeMode = isCreativeMode;
}
public void setFlySpeed(float flySpeedIn)
{
this.flySpeed = flySpeedIn;
}
public void setWalkSpeed(float walkSpeedIn)
{
this.walkSpeed = walkSpeedIn;
}
}

View file

@ -0,0 +1,76 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class C14PacketTabComplete implements Packet<INetHandlerPlayServer>
{
private String message;
private BlockPos targetBlock;
public C14PacketTabComplete()
{
}
public C14PacketTabComplete(String msg)
{
this(msg, (BlockPos)null);
}
public C14PacketTabComplete(String msg, BlockPos target)
{
this.message = msg;
this.targetBlock = target;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.message = buf.readStringFromBuffer(32767);
boolean flag = buf.readBoolean();
if (flag)
{
this.targetBlock = buf.readBlockPos();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.message.length() > 32767 ? this.message.substring(0, 32767) : this.message);
boolean flag = this.targetBlock != null;
buf.writeBoolean(flag);
if (flag)
{
buf.writeBlockPos(this.targetBlock);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processTabComplete(this);
}
public String getMessage()
{
return this.message;
}
public BlockPos getTargetBlock()
{
return this.targetBlock;
}
}

View file

@ -0,0 +1,48 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C15PacketClientSettings implements Packet<INetHandlerPlayServer>
{
private String lang;
private int view;
private byte chatVisibility;
private boolean enableColors;
private int modelPartFlags;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.lang = buf.readStringFromBuffer(7);
this.view = buf.readByte();
this.chatVisibility = buf.readByte();
this.enableColors = buf.readBoolean();
this.modelPartFlags = buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.lang);
buf.writeByte(this.view);
buf.writeByte(this.chatVisibility);
buf.writeBoolean(this.enableColors);
buf.writeByte(this.modelPartFlags);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processClientSettings(this);
}
}

View file

@ -0,0 +1,43 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C16PacketClientStatus implements Packet<INetHandlerPlayServer>
{
private C16PacketClientStatus.EnumState status;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.status = (C16PacketClientStatus.EnumState)buf.readEnumValue(C16PacketClientStatus.EnumState.class);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeEnumValue(this.status);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processClientStatus(this);
}
public static enum EnumState
{
PERFORM_RESPAWN,
REQUEST_STATS,
OPEN_INVENTORY_ACHIEVEMENT;
}
}

View file

@ -0,0 +1,61 @@
package net.minecraft.network.play.client;
import io.netty.buffer.ByteBuf;
import io.netty.buffer.Unpooled;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C17PacketCustomPayload implements Packet<INetHandlerPlayServer>
{
private String channel;
private PacketBuffer data;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.channel = buf.readStringFromBuffer(20);
int i = buf.readableBytes();
if (i >= 0 && i <= 32767)
{
this.data = new PacketBuffer(buf.readBytes(i));
}
else
{
throw new IOException("Payload may not be larger than 32767 bytes");
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.channel);
buf.writeBytes((ByteBuf)this.data);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.processVanilla250Packet(this);
}
public String getChannelName()
{
return this.channel;
}
public PacketBuffer getBufferData()
{
return new PacketBuffer(Unpooled.wrappedBuffer(this.data));
}
}

View file

@ -0,0 +1,37 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import java.util.UUID;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C18PacketSpectate implements Packet<INetHandlerPlayServer>
{
private UUID id;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.id = buf.readUuid();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeUuid(this.id);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.handleSpectate(this);
}
}

View file

@ -0,0 +1,47 @@
package net.minecraft.network.play.client;
import java.io.IOException;
import proxy.network.INetHandlerPlayServer;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class C19PacketResourcePackStatus implements Packet<INetHandlerPlayServer>
{
private String hash;
private C19PacketResourcePackStatus.Action status;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.hash = buf.readStringFromBuffer(40);
this.status = (C19PacketResourcePackStatus.Action)buf.readEnumValue(C19PacketResourcePackStatus.Action.class);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.hash);
buf.writeEnumValue(this.status);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayServer handler)
{
handler.handleResourcePackStatus(this);
}
public static enum Action
{
SUCCESSFULLY_LOADED,
DECLINED,
FAILED_DOWNLOAD,
ACCEPTED;
}
}

View file

@ -0,0 +1,50 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S00PacketKeepAlive implements Packet<INetHandlerPlayClient>
{
private int id;
public S00PacketKeepAlive()
{
}
public S00PacketKeepAlive(int idIn)
{
this.id = idIn;
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleKeepAlive(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.id = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.id);
}
public int func_149134_c()
{
return this.id;
}
}

View file

@ -0,0 +1,121 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S01PacketJoinGame implements Packet<INetHandlerPlayClient>
{
private int entityId;
private boolean hardcoreMode;
private byte gameType;
private int dimension;
private byte difficulty;
private int maxPlayers;
private String worldType;
private boolean reducedDebugInfo;
public S01PacketJoinGame()
{
}
public S01PacketJoinGame(int entityIdIn, boolean spectator)
{
this.entityId = entityIdIn;
this.dimension = 0;
this.difficulty = 2;
this.gameType = (byte)(spectator ? 3 : 0);
this.maxPlayers = 1;
this.hardcoreMode = false;
this.worldType = "flat";
this.reducedDebugInfo = false;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readInt();
int i = buf.readUnsignedByte();
this.hardcoreMode = (i & 8) == 8;
i = i & -9;
this.gameType = (byte)i;
this.dimension = buf.readByte();
this.difficulty = (byte)buf.readUnsignedByte();
this.maxPlayers = buf.readUnsignedByte();
this.worldType = buf.readStringFromBuffer(16);
this.reducedDebugInfo = buf.readBoolean();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.entityId);
int i = this.gameType;
if (this.hardcoreMode)
{
i |= 8;
}
buf.writeByte(i);
buf.writeByte(this.dimension);
buf.writeByte(this.difficulty);
buf.writeByte(this.maxPlayers);
buf.writeString(this.worldType);
buf.writeBoolean(this.reducedDebugInfo);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleJoinGame(this);
}
public int getEntityId()
{
return this.entityId;
}
public boolean isHardcoreMode()
{
return this.hardcoreMode;
}
public byte getGameType()
{
return this.gameType;
}
public int getDimension()
{
return this.dimension;
}
public byte getDifficulty()
{
return this.difficulty;
}
public int getMaxPlayers()
{
return this.maxPlayers;
}
public String getWorldType()
{
return this.worldType;
}
public boolean isReducedDebugInfo()
{
return this.reducedDebugInfo;
}
}

View file

@ -0,0 +1,51 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ChatComponent;
import proxy.util.ChatComponentText;
public class S02PacketChat implements Packet<INetHandlerPlayClient>
{
private ChatComponent chatComponent;
private byte type;
public S02PacketChat()
{
}
public S02PacketChat(String message)
{
this.chatComponent = new ChatComponentText(message);
this.type = 0;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.chatComponent = buf.readChatComponent();
this.type = buf.readByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeChatComponent(this.chatComponent);
buf.writeByte(this.type);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleChat(this);
}
}

View file

@ -0,0 +1,59 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S03PacketTimeUpdate implements Packet<INetHandlerPlayClient>
{
private long totalWorldTime;
private long worldTime;
public S03PacketTimeUpdate()
{
}
public S03PacketTimeUpdate(long totalTimeIn, boolean doDayLightCycle)
{
this.totalWorldTime = totalTimeIn;
this.worldTime = totalTimeIn;
if (!doDayLightCycle)
{
this.worldTime = -this.worldTime;
if (this.worldTime == 0L)
{
this.worldTime = -1L;
}
}
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.totalWorldTime = buf.readLong();
this.worldTime = buf.readLong();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeLong(this.totalWorldTime);
buf.writeLong(this.worldTime);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleTimeUpdate(this);
}
}

View file

@ -0,0 +1,43 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ItemStack;
public class S04PacketEntityEquipment implements Packet<INetHandlerPlayClient>
{
private int entityID;
private int equipmentSlot;
private ItemStack itemStack;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityID = buf.readVarIntFromBuffer();
this.equipmentSlot = buf.readShort();
this.itemStack = buf.readItemStackFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityID);
buf.writeShort(this.equipmentSlot);
buf.writeItemStackToBuffer(this.itemStack);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityEquipment(this);
}
}

View file

@ -0,0 +1,37 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S05PacketSpawnPosition implements Packet<INetHandlerPlayClient>
{
private BlockPos spawnBlockPos;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.spawnBlockPos = buf.readBlockPos();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.spawnBlockPos);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSpawnPosition(this);
}
}

View file

@ -0,0 +1,42 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S06PacketUpdateHealth implements Packet<INetHandlerPlayClient>
{
private float health;
private int foodLevel;
private float saturationLevel;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.health = buf.readFloat();
this.foodLevel = buf.readVarIntFromBuffer();
this.saturationLevel = buf.readFloat();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeFloat(this.health);
buf.writeVarIntToBuffer(this.foodLevel);
buf.writeFloat(this.saturationLevel);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleUpdateHealth(this);
}
}

View file

@ -0,0 +1,57 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S07PacketRespawn implements Packet<INetHandlerPlayClient>
{
private int dimensionID;
private byte difficulty;
private byte gameType;
private String worldType;
public S07PacketRespawn()
{
}
public S07PacketRespawn(S01PacketJoinGame pkt)
{
this.dimensionID = pkt.getDimension();
this.difficulty = pkt.getDifficulty();
this.gameType = pkt.getGameType();
this.worldType = pkt.getWorldType();
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleRespawn(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.dimensionID = buf.readInt();
this.difficulty = (byte)buf.readUnsignedByte();
this.gameType = (byte)buf.readUnsignedByte();
this.worldType = buf.readStringFromBuffer(16);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.dimensionID);
buf.writeByte(this.difficulty);
buf.writeByte(this.gameType);
buf.writeString(this.worldType);
}
}

View file

@ -0,0 +1,121 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.Collections;
import java.util.EnumSet;
import java.util.Set;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S08PacketPlayerPosLook implements Packet<INetHandlerPlayClient>
{
private double x;
private double y;
private double z;
private float yaw;
private float pitch;
private Set<S08PacketPlayerPosLook.EnumFlags> field_179835_f;
public S08PacketPlayerPosLook()
{
}
public S08PacketPlayerPosLook(double xIn, double yIn, double zIn, float yawIn, float pitchIn)
{
this.x = xIn;
this.y = yIn;
this.z = zIn;
this.yaw = yawIn;
this.pitch = pitchIn;
this.field_179835_f = Collections.<S08PacketPlayerPosLook.EnumFlags>emptySet();
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.x = buf.readDouble();
this.y = buf.readDouble();
this.z = buf.readDouble();
this.yaw = buf.readFloat();
this.pitch = buf.readFloat();
this.field_179835_f = S08PacketPlayerPosLook.EnumFlags.func_180053_a(buf.readUnsignedByte());
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeDouble(this.x);
buf.writeDouble(this.y);
buf.writeDouble(this.z);
buf.writeFloat(this.yaw);
buf.writeFloat(this.pitch);
buf.writeByte(S08PacketPlayerPosLook.EnumFlags.func_180056_a(this.field_179835_f));
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handlePlayerPosLook(this);
}
public static enum EnumFlags
{
X(0),
Y(1),
Z(2),
Y_ROT(3),
X_ROT(4);
private int field_180058_f;
private EnumFlags(int p_i45992_3_)
{
this.field_180058_f = p_i45992_3_;
}
private int func_180055_a()
{
return 1 << this.field_180058_f;
}
private boolean func_180054_b(int p_180054_1_)
{
return (p_180054_1_ & this.func_180055_a()) == this.func_180055_a();
}
public static Set<S08PacketPlayerPosLook.EnumFlags> func_180053_a(int p_180053_0_)
{
Set<S08PacketPlayerPosLook.EnumFlags> set = EnumSet.<S08PacketPlayerPosLook.EnumFlags>noneOf(S08PacketPlayerPosLook.EnumFlags.class);
for (S08PacketPlayerPosLook.EnumFlags s08packetplayerposlook$enumflags : values())
{
if (s08packetplayerposlook$enumflags.func_180054_b(p_180053_0_))
{
set.add(s08packetplayerposlook$enumflags);
}
}
return set;
}
public static int func_180056_a(Set<S08PacketPlayerPosLook.EnumFlags> p_180056_0_)
{
int i = 0;
for (S08PacketPlayerPosLook.EnumFlags s08packetplayerposlook$enumflags : p_180056_0_)
{
i |= s08packetplayerposlook$enumflags.func_180055_a();
}
return i;
}
}
}

View file

@ -0,0 +1,36 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S09PacketHeldItemChange implements Packet<INetHandlerPlayClient>
{
private int heldItemHotbarIndex;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.heldItemHotbarIndex = buf.readByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.heldItemHotbarIndex);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleHeldItemChange(this);
}
}

View file

@ -0,0 +1,40 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S0APacketUseBed implements Packet<INetHandlerPlayClient>
{
private int playerID;
private BlockPos bedPos;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.playerID = buf.readVarIntFromBuffer();
this.bedPos = buf.readBlockPos();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.playerID);
buf.writeBlockPos(this.bedPos);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleUseBed(this);
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S0BPacketAnimation implements Packet<INetHandlerPlayClient>
{
private int entityId;
private int type;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.type = buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeByte(this.type);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleAnimation(this);
}
}

View file

@ -0,0 +1,80 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.List;
import java.util.UUID;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.DataWatcher;
import proxy.util.MathHelper;
public class S0CPacketSpawnPlayer implements Packet<INetHandlerPlayClient>
{
private int entityId;
private UUID playerId;
private int x;
private int y;
private int z;
private byte yaw;
private byte pitch;
private int currentItem;
private List<DataWatcher.WatchableObject> field_148958_j;
public S0CPacketSpawnPlayer()
{
}
public S0CPacketSpawnPlayer(int id, UUID uuid, double x, double y, double z, float yaw, float pitch)
{
this.entityId = id;
this.playerId = uuid;
this.x = MathHelper.floor_double(x * 32.0D);
this.y = MathHelper.floor_double(y * 32.0D);
this.z = MathHelper.floor_double(z * 32.0D);
this.yaw = (byte)((int)(yaw * 256.0F / 360.0F));
this.pitch = (byte)((int)(pitch * 256.0F / 360.0F));
this.currentItem = 0;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.playerId = buf.readUuid();
this.x = buf.readInt();
this.y = buf.readInt();
this.z = buf.readInt();
this.yaw = buf.readByte();
this.pitch = buf.readByte();
this.currentItem = buf.readShort();
this.field_148958_j = DataWatcher.readWatchedListFromPacketBuffer(buf);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeUuid(this.playerId);
buf.writeInt(this.x);
buf.writeInt(this.y);
buf.writeInt(this.z);
buf.writeByte(this.yaw);
buf.writeByte(this.pitch);
buf.writeShort(this.currentItem);
DataWatcher.writeWatchedListToPacketBuffer(this.field_148958_j, buf);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSpawnPlayer(this);
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S0DPacketCollectItem implements Packet<INetHandlerPlayClient>
{
private int collectedItemEntityId;
private int entityId;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.collectedItemEntityId = buf.readVarIntFromBuffer();
this.entityId = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.collectedItemEntityId);
buf.writeVarIntToBuffer(this.entityId);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleCollectItem(this);
}
}

View file

@ -0,0 +1,74 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S0EPacketSpawnObject implements Packet<INetHandlerPlayClient>
{
private int entityId;
private int x;
private int y;
private int z;
private int speedX;
private int speedY;
private int speedZ;
private int pitch;
private int yaw;
private int type;
private int field_149020_k;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.type = buf.readByte();
this.x = buf.readInt();
this.y = buf.readInt();
this.z = buf.readInt();
this.pitch = buf.readByte();
this.yaw = buf.readByte();
this.field_149020_k = buf.readInt();
if (this.field_149020_k > 0)
{
this.speedX = buf.readShort();
this.speedY = buf.readShort();
this.speedZ = buf.readShort();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeByte(this.type);
buf.writeInt(this.x);
buf.writeInt(this.y);
buf.writeInt(this.z);
buf.writeByte(this.pitch);
buf.writeByte(this.yaw);
buf.writeInt(this.field_149020_k);
if (this.field_149020_k > 0)
{
buf.writeShort(this.speedX);
buf.writeShort(this.speedY);
buf.writeShort(this.speedZ);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSpawnObject(this);
}
}

View file

@ -0,0 +1,71 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.List;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.DataWatcher;
public class S0FPacketSpawnMob implements Packet<INetHandlerPlayClient>
{
private int entityId;
private int type;
private int x;
private int y;
private int z;
private int velocityX;
private int velocityY;
private int velocityZ;
private byte yaw;
private byte pitch;
private byte headPitch;
private List<DataWatcher.WatchableObject> watcher;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.type = buf.readByte() & 255;
this.x = buf.readInt();
this.y = buf.readInt();
this.z = buf.readInt();
this.yaw = buf.readByte();
this.pitch = buf.readByte();
this.headPitch = buf.readByte();
this.velocityX = buf.readShort();
this.velocityY = buf.readShort();
this.velocityZ = buf.readShort();
this.watcher = DataWatcher.readWatchedListFromPacketBuffer(buf);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeByte(this.type & 255);
buf.writeInt(this.x);
buf.writeInt(this.y);
buf.writeInt(this.z);
buf.writeByte(this.yaw);
buf.writeByte(this.pitch);
buf.writeByte(this.headPitch);
buf.writeShort(this.velocityX);
buf.writeShort(this.velocityY);
buf.writeShort(this.velocityZ);
DataWatcher.writeWatchedListToPacketBuffer(this.watcher, buf);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSpawnMob(this);
}
}

View file

@ -0,0 +1,46 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S10PacketSpawnPainting implements Packet<INetHandlerPlayClient>
{
private int entityID;
private BlockPos position;
private byte facing;
private String title;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityID = buf.readVarIntFromBuffer();
this.title = buf.readStringFromBuffer(13);
this.position = buf.readBlockPos();
this.facing = (byte)buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityID);
buf.writeString(this.title);
buf.writeBlockPos(this.position);
buf.writeByte(this.facing);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSpawnPainting(this);
}
}

View file

@ -0,0 +1,48 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S11PacketSpawnExperienceOrb implements Packet<INetHandlerPlayClient>
{
private int entityID;
private int posX;
private int posY;
private int posZ;
private int xpValue;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityID = buf.readVarIntFromBuffer();
this.posX = buf.readInt();
this.posY = buf.readInt();
this.posZ = buf.readInt();
this.xpValue = buf.readShort();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityID);
buf.writeInt(this.posX);
buf.writeInt(this.posY);
buf.writeInt(this.posZ);
buf.writeShort(this.xpValue);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSpawnExperienceOrb(this);
}
}

View file

@ -0,0 +1,45 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S12PacketEntityVelocity implements Packet<INetHandlerPlayClient>
{
private int entityID;
private int motionX;
private int motionY;
private int motionZ;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityID = buf.readVarIntFromBuffer();
this.motionX = buf.readShort();
this.motionY = buf.readShort();
this.motionZ = buf.readShort();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityID);
buf.writeShort(this.motionX);
buf.writeShort(this.motionY);
buf.writeShort(this.motionZ);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityVelocity(this);
}
}

View file

@ -0,0 +1,46 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S13PacketDestroyEntities implements Packet<INetHandlerPlayClient>
{
private int[] entityIDs;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityIDs = new int[buf.readVarIntFromBuffer()];
for (int i = 0; i < this.entityIDs.length; ++i)
{
this.entityIDs[i] = buf.readVarIntFromBuffer();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityIDs.length);
for (int i = 0; i < this.entityIDs.length; ++i)
{
buf.writeVarIntToBuffer(this.entityIDs[i]);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleDestroyEntities(this);
}
}

View file

@ -0,0 +1,118 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S14PacketEntity implements Packet<INetHandlerPlayClient>
{
protected int entityId;
protected byte posX;
protected byte posY;
protected byte posZ;
protected byte yaw;
protected byte pitch;
protected boolean onGround;
protected boolean field_149069_g;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityMovement(this);
}
public static class S15PacketEntityRelMove extends S14PacketEntity
{
public void readPacketData(PacketBuffer buf) throws IOException
{
super.readPacketData(buf);
this.posX = buf.readByte();
this.posY = buf.readByte();
this.posZ = buf.readByte();
this.onGround = buf.readBoolean();
}
public void writePacketData(PacketBuffer buf) throws IOException
{
super.writePacketData(buf);
buf.writeByte(this.posX);
buf.writeByte(this.posY);
buf.writeByte(this.posZ);
buf.writeBoolean(this.onGround);
}
}
public static class S16PacketEntityLook extends S14PacketEntity
{
public S16PacketEntityLook()
{
this.field_149069_g = true;
}
public void readPacketData(PacketBuffer buf) throws IOException
{
super.readPacketData(buf);
this.yaw = buf.readByte();
this.pitch = buf.readByte();
this.onGround = buf.readBoolean();
}
public void writePacketData(PacketBuffer buf) throws IOException
{
super.writePacketData(buf);
buf.writeByte(this.yaw);
buf.writeByte(this.pitch);
buf.writeBoolean(this.onGround);
}
}
public static class S17PacketEntityLookMove extends S14PacketEntity
{
public S17PacketEntityLookMove()
{
this.field_149069_g = true;
}
public void readPacketData(PacketBuffer buf) throws IOException
{
super.readPacketData(buf);
this.posX = buf.readByte();
this.posY = buf.readByte();
this.posZ = buf.readByte();
this.yaw = buf.readByte();
this.pitch = buf.readByte();
this.onGround = buf.readBoolean();
}
public void writePacketData(PacketBuffer buf) throws IOException
{
super.writePacketData(buf);
buf.writeByte(this.posX);
buf.writeByte(this.posY);
buf.writeByte(this.posZ);
buf.writeByte(this.yaw);
buf.writeByte(this.pitch);
buf.writeBoolean(this.onGround);
}
}
}

View file

@ -0,0 +1,54 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S18PacketEntityTeleport implements Packet<INetHandlerPlayClient>
{
private int entityId;
private int posX;
private int posY;
private int posZ;
private byte yaw;
private byte pitch;
private boolean onGround;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.posX = buf.readInt();
this.posY = buf.readInt();
this.posZ = buf.readInt();
this.yaw = buf.readByte();
this.pitch = buf.readByte();
this.onGround = buf.readBoolean();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeInt(this.posX);
buf.writeInt(this.posY);
buf.writeInt(this.posZ);
buf.writeByte(this.yaw);
buf.writeByte(this.pitch);
buf.writeBoolean(this.onGround);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityTeleport(this);
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S19PacketEntityHeadLook implements Packet<INetHandlerPlayClient>
{
private int entityId;
private byte yaw;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.yaw = buf.readByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeByte(this.yaw);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityHeadLook(this);
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S19PacketEntityStatus implements Packet<INetHandlerPlayClient>
{
private int entityId;
private byte logicOpcode;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readInt();
this.logicOpcode = buf.readByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.entityId);
buf.writeByte(this.logicOpcode);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityStatus(this);
}
}

View file

@ -0,0 +1,42 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S1BPacketEntityAttach implements Packet<INetHandlerPlayClient>
{
private int leash;
private int entityId;
private int vehicleEntityId;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readInt();
this.vehicleEntityId = buf.readInt();
this.leash = buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.entityId);
buf.writeInt(this.vehicleEntityId);
buf.writeByte(this.leash);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityAttach(this);
}
}

View file

@ -0,0 +1,41 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.List;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.DataWatcher;
public class S1CPacketEntityMetadata implements Packet<INetHandlerPlayClient>
{
private int entityId;
private List<DataWatcher.WatchableObject> field_149378_b;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.field_149378_b = DataWatcher.readWatchedListFromPacketBuffer(buf);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
DataWatcher.writeWatchedListToPacketBuffer(this.field_149378_b, buf);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityMetadata(this);
}
}

View file

@ -0,0 +1,48 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S1DPacketEntityEffect implements Packet<INetHandlerPlayClient>
{
private int entityId;
private byte effectId;
private byte amplifier;
private int duration;
private byte hideParticles;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.effectId = buf.readByte();
this.amplifier = buf.readByte();
this.duration = buf.readVarIntFromBuffer();
this.hideParticles = buf.readByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeByte(this.effectId);
buf.writeByte(this.amplifier);
buf.writeVarIntToBuffer(this.duration);
buf.writeByte(this.hideParticles);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityEffect(this);
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S1EPacketRemoveEntityEffect implements Packet<INetHandlerPlayClient>
{
private int entityId;
private int effectId;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.effectId = buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeByte(this.effectId);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleRemoveEntityEffect(this);
}
}

View file

@ -0,0 +1,42 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S1FPacketSetExperience implements Packet<INetHandlerPlayClient>
{
private float field_149401_a;
private int totalExperience;
private int level;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.field_149401_a = buf.readFloat();
this.level = buf.readVarIntFromBuffer();
this.totalExperience = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeFloat(this.field_149401_a);
buf.writeVarIntToBuffer(this.level);
buf.writeVarIntToBuffer(this.totalExperience);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSetExperience(this);
}
}

View file

@ -0,0 +1,127 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.Collection;
import java.util.List;
import java.util.UUID;
import com.google.common.collect.Lists;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S20PacketEntityProperties implements Packet<INetHandlerPlayClient>
{
private int entityId;
private final List<S20PacketEntityProperties.Snapshot> field_149444_b = Lists.<S20PacketEntityProperties.Snapshot>newArrayList();
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
int i = buf.readInt();
for (int j = 0; j < i; ++j)
{
String s = buf.readStringFromBuffer(64);
double d0 = buf.readDouble();
List<AttributeModifier> list = Lists.<AttributeModifier>newArrayList();
int k = buf.readVarIntFromBuffer();
for (int l = 0; l < k; ++l)
{
UUID uuid = buf.readUuid();
list.add(new AttributeModifier(uuid, buf.readDouble(), buf.readByte()));
}
this.field_149444_b.add(new S20PacketEntityProperties.Snapshot(s, d0, list));
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeInt(this.field_149444_b.size());
for (S20PacketEntityProperties.Snapshot s20packetentityproperties$snapshot : this.field_149444_b)
{
buf.writeString(s20packetentityproperties$snapshot.func_151409_a());
buf.writeDouble(s20packetentityproperties$snapshot.func_151410_b());
buf.writeVarIntToBuffer(s20packetentityproperties$snapshot.func_151408_c().size());
for (AttributeModifier attributemodifier : s20packetentityproperties$snapshot.func_151408_c())
{
buf.writeUuid(attributemodifier.getID());
buf.writeDouble(attributemodifier.getAmount());
buf.writeByte(attributemodifier.getOperation());
}
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEntityProperties(this);
}
private class AttributeModifier {
private final UUID id;
private final double amount;
private final byte operation;
public AttributeModifier(UUID id, double amount, byte operation) {
this.id = id;
this.amount = amount;
this.operation = operation;
}
public UUID getID() {
return this.id;
}
public double getAmount() {
return this.amount;
}
public byte getOperation() {
return this.operation;
}
}
public class Snapshot
{
private final String field_151412_b;
private final double field_151413_c;
private final Collection<AttributeModifier> field_151411_d;
public Snapshot(String p_i45235_2_, double p_i45235_3_, Collection<AttributeModifier> p_i45235_5_)
{
this.field_151412_b = p_i45235_2_;
this.field_151413_c = p_i45235_3_;
this.field_151411_d = p_i45235_5_;
}
public String func_151409_a()
{
return this.field_151412_b;
}
public double func_151410_b()
{
return this.field_151413_c;
}
public Collection<AttributeModifier> func_151408_c()
{
return this.field_151411_d;
}
}
}

View file

@ -0,0 +1,54 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S21PacketChunkData implements Packet<INetHandlerPlayClient>
{
private int chunkX;
private int chunkZ;
private S21PacketChunkData.Extracted extractedData;
private boolean field_149279_g;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.chunkX = buf.readInt();
this.chunkZ = buf.readInt();
this.field_149279_g = buf.readBoolean();
this.extractedData = new S21PacketChunkData.Extracted();
this.extractedData.dataSize = buf.readShort();
this.extractedData.data = buf.readByteArray();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.chunkX);
buf.writeInt(this.chunkZ);
buf.writeBoolean(this.field_149279_g);
buf.writeShort((short)(this.extractedData.dataSize & 65535));
buf.writeByteArray(this.extractedData.data);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleChunkData(this);
}
public static class Extracted
{
public byte[] data;
public int dataSize;
}
}

View file

@ -0,0 +1,75 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S22PacketMultiBlockChange implements Packet<INetHandlerPlayClient>
{
private int chunkPosCoordX;
private int chunkPosCoordZ;
private S22PacketMultiBlockChange.BlockUpdateData[] changedBlocks;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.chunkPosCoordX = buf.readInt();
this.chunkPosCoordZ = buf.readInt();
this.changedBlocks = new S22PacketMultiBlockChange.BlockUpdateData[buf.readVarIntFromBuffer()];
for (int i = 0; i < this.changedBlocks.length; ++i)
{
this.changedBlocks[i] = new S22PacketMultiBlockChange.BlockUpdateData(buf.readShort(), buf.readVarIntFromBuffer());
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.chunkPosCoordX);
buf.writeInt(this.chunkPosCoordZ);
buf.writeVarIntToBuffer(this.changedBlocks.length);
for (S22PacketMultiBlockChange.BlockUpdateData s22packetmultiblockchange$blockupdatedata : this.changedBlocks)
{
buf.writeShort(s22packetmultiblockchange$blockupdatedata.func_180089_b());
buf.writeVarIntToBuffer(s22packetmultiblockchange$blockupdatedata.getBlockState());
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleMultiBlockChange(this);
}
public class BlockUpdateData
{
private final short chunkPosCrammed;
private final int blockState;
public BlockUpdateData(short p_i45984_2_, int state)
{
this.chunkPosCrammed = p_i45984_2_;
this.blockState = state;
}
public short func_180089_b()
{
return this.chunkPosCrammed;
}
public int getBlockState()
{
return this.blockState;
}
}
}

View file

@ -0,0 +1,40 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S23PacketBlockChange implements Packet<INetHandlerPlayClient>
{
private BlockPos blockPosition;
private int blockState;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.blockPosition = buf.readBlockPos();
this.blockState = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.blockPosition);
buf.writeVarIntToBuffer(this.blockState);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleBlockChange(this);
}
}

View file

@ -0,0 +1,46 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S24PacketBlockAction implements Packet<INetHandlerPlayClient>
{
private BlockPos blockPosition;
private int instrument;
private int pitch;
private int block;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.blockPosition = buf.readBlockPos();
this.instrument = buf.readUnsignedByte();
this.pitch = buf.readUnsignedByte();
this.block = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.blockPosition);
buf.writeByte(this.instrument);
buf.writeByte(this.pitch);
buf.writeVarIntToBuffer(this.block);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleBlockAction(this);
}
}

View file

@ -0,0 +1,43 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S25PacketBlockBreakAnim implements Packet<INetHandlerPlayClient>
{
private int breakerId;
private BlockPos position;
private int progress;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.breakerId = buf.readVarIntFromBuffer();
this.position = buf.readBlockPos();
this.progress = buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.breakerId);
buf.writeBlockPos(this.position);
buf.writeByte(this.progress);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleBlockBreakAnim(this);
}
}

View file

@ -0,0 +1,131 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.Arrays;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S26PacketMapChunkBulk implements Packet<INetHandlerPlayClient>
{
private int[] xPositions;
private int[] zPositions;
private S21PacketChunkData.Extracted[] chunksData;
private boolean isOverworld;
public S26PacketMapChunkBulk()
{
}
public S26PacketMapChunkBulk(int x, int y, int z)
{
this.xPositions = new int[1];
this.zPositions = new int[1];
this.chunksData = new S21PacketChunkData.Extracted[1];
this.isOverworld = true;
this.xPositions[0] = x >> 4;
this.zPositions[0] = z >> 4;
this.chunksData[0] = getExtractedData(x, y, z);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.isOverworld = buf.readBoolean();
int i = buf.readVarIntFromBuffer();
this.xPositions = new int[i];
this.zPositions = new int[i];
this.chunksData = new S21PacketChunkData.Extracted[i];
for (int j = 0; j < i; ++j)
{
this.xPositions[j] = buf.readInt();
this.zPositions[j] = buf.readInt();
this.chunksData[j] = new S21PacketChunkData.Extracted();
this.chunksData[j].dataSize = buf.readShort() & 65535;
this.chunksData[j].data = new byte[func_180737_a(Integer.bitCount(this.chunksData[j].dataSize), this.isOverworld, true)];
}
for (int k = 0; k < i; ++k)
{
buf.readBytes(this.chunksData[k].data);
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBoolean(this.isOverworld);
buf.writeVarIntToBuffer(this.chunksData.length);
for (int i = 0; i < this.xPositions.length; ++i)
{
buf.writeInt(this.xPositions[i]);
buf.writeInt(this.zPositions[i]);
buf.writeShort((short)(this.chunksData[i].dataSize & 65535));
}
for (int j = 0; j < this.xPositions.length; ++j)
{
buf.writeBytes(this.chunksData[j].data);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleMapChunkBulk(this);
}
protected static int func_180737_a(int p_180737_0_, boolean p_180737_1_, boolean p_180737_2_)
{
int i = p_180737_0_ * 2 * 16 * 16 * 16;
int j = p_180737_0_ * 16 * 16 * 16 / 2;
int k = p_180737_1_ ? p_180737_0_ * 16 * 16 * 16 / 2 : 0;
int l = p_180737_2_ ? 256 : 0;
return i + j + k + l;
}
public static S21PacketChunkData.Extracted getExtractedData(int x, int y, int z)
{
S21PacketChunkData.Extracted seg = new S21PacketChunkData.Extracted();
seg.dataSize = 1 << (y >> 4);
seg.data = new byte[func_180737_a(1, true, true)];
int id1 = (x & 15) | (y & 15) << 8 | (z & 15) << 4;
int id2 = (x & 15) | ((y + 2) & 15) << 8 | ((z + 1) & 15) << 4;
int id3 = (x & 15) | ((y + 2) & 15) << 8 | ((z + 2) & 15) << 4;
int j = 0;
char[] achar = new char[4096];
for (int n = 0; n < achar.length; n++)
{
char c0 = (char)(n == id1 ? 2 << 4 : (n == id2 ? (68 << 4) | 2 : (n == id3 ? 166 << 4 : 0)));
seg.data[j++] = (byte)(c0 & 255);
seg.data[j++] = (byte)(c0 >> 8 & 255);
}
byte[] adata = new byte[2048];
j = func_179757_a(adata, seg.data, j);
Arrays.fill(adata, (byte)255);
j = func_179757_a(adata, seg.data, j);
adata = new byte[256];
Arrays.fill(adata, (byte)1);
func_179757_a(adata, seg.data, j);
return seg;
}
private static int func_179757_a(byte[] p_179757_0_, byte[] p_179757_1_, int p_179757_2_)
{
System.arraycopy(p_179757_0_, 0, p_179757_1_, p_179757_2_, p_179757_0_.length);
return p_179757_2_ + p_179757_0_.length;
}
}

View file

@ -0,0 +1,88 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.List;
import com.google.common.collect.Lists;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S27PacketExplosion implements Packet<INetHandlerPlayClient>
{
private double posX;
private double posY;
private double posZ;
private float strength;
private List<BlockPos> affectedBlockPositions;
private float field_149152_f;
private float field_149153_g;
private float field_149159_h;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.posX = (double)buf.readFloat();
this.posY = (double)buf.readFloat();
this.posZ = (double)buf.readFloat();
this.strength = buf.readFloat();
int i = buf.readInt();
this.affectedBlockPositions = Lists.<BlockPos>newArrayListWithCapacity(i);
int j = (int)this.posX;
int k = (int)this.posY;
int l = (int)this.posZ;
for (int i1 = 0; i1 < i; ++i1)
{
int j1 = buf.readByte() + j;
int k1 = buf.readByte() + k;
int l1 = buf.readByte() + l;
this.affectedBlockPositions.add(new BlockPos(j1, k1, l1));
}
this.field_149152_f = buf.readFloat();
this.field_149153_g = buf.readFloat();
this.field_149159_h = buf.readFloat();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeFloat((float)this.posX);
buf.writeFloat((float)this.posY);
buf.writeFloat((float)this.posZ);
buf.writeFloat(this.strength);
buf.writeInt(this.affectedBlockPositions.size());
int i = (int)this.posX;
int j = (int)this.posY;
int k = (int)this.posZ;
for (BlockPos blockpos : this.affectedBlockPositions)
{
int l = blockpos.getX() - i;
int i1 = blockpos.getY() - j;
int j1 = blockpos.getZ() - k;
buf.writeByte(l);
buf.writeByte(i1);
buf.writeByte(j1);
}
buf.writeFloat(this.field_149152_f);
buf.writeFloat(this.field_149153_g);
buf.writeFloat(this.field_149159_h);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleExplosion(this);
}
}

View file

@ -0,0 +1,46 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S28PacketEffect implements Packet<INetHandlerPlayClient>
{
private int soundType;
private BlockPos soundPos;
private int soundData;
private boolean serverWide;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.soundType = buf.readInt();
this.soundPos = buf.readBlockPos();
this.soundData = buf.readInt();
this.serverWide = buf.readBoolean();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.soundType);
buf.writeBlockPos(this.soundPos);
buf.writeInt(this.soundData);
buf.writeBoolean(this.serverWide);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleEffect(this);
}
}

View file

@ -0,0 +1,51 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S29PacketSoundEffect implements Packet<INetHandlerPlayClient>
{
private String soundName;
private int posX;
private int posY = Integer.MAX_VALUE;
private int posZ;
private float soundVolume;
private int soundPitch;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.soundName = buf.readStringFromBuffer(256);
this.posX = buf.readInt();
this.posY = buf.readInt();
this.posZ = buf.readInt();
this.soundVolume = buf.readFloat();
this.soundPitch = buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.soundName);
buf.writeInt(this.posX);
buf.writeInt(this.posY);
buf.writeInt(this.posZ);
buf.writeFloat(this.soundVolume);
buf.writeByte(this.soundPitch);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSoundEffect(this);
}
}

View file

@ -0,0 +1,77 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S2APacketParticles implements Packet<INetHandlerPlayClient>
{
private int particleType;
private float xCoord;
private float yCoord;
private float zCoord;
private float xOffset;
private float yOffset;
private float zOffset;
private float particleSpeed;
private int particleCount;
private boolean longDistance;
private int[] particleArguments;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.particleType = buf.readInt();
this.longDistance = buf.readBoolean();
this.xCoord = buf.readFloat();
this.yCoord = buf.readFloat();
this.zCoord = buf.readFloat();
this.xOffset = buf.readFloat();
this.yOffset = buf.readFloat();
this.zOffset = buf.readFloat();
this.particleSpeed = buf.readFloat();
this.particleCount = buf.readInt();
int i = this.particleType == 36 ? 2 : (this.particleType == 37 || this.particleType == 38 ? 1 : 0);
this.particleArguments = new int[i];
for (int j = 0; j < i; ++j)
{
this.particleArguments[j] = buf.readVarIntFromBuffer();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeInt(this.particleType);
buf.writeBoolean(this.longDistance);
buf.writeFloat(this.xCoord);
buf.writeFloat(this.yCoord);
buf.writeFloat(this.zCoord);
buf.writeFloat(this.xOffset);
buf.writeFloat(this.yOffset);
buf.writeFloat(this.zOffset);
buf.writeFloat(this.particleSpeed);
buf.writeInt(this.particleCount);
int i = this.particleType == 36 ? 2 : (this.particleType == 37 || this.particleType == 38 ? 1 : 0);
for (int j = 0; j < i; ++j)
{
buf.writeVarIntToBuffer(this.particleArguments[j]);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleParticles(this);
}
}

View file

@ -0,0 +1,49 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S2BPacketChangeGameState implements Packet<INetHandlerPlayClient>
{
private int state;
private float field_149141_c;
public S2BPacketChangeGameState()
{
}
public S2BPacketChangeGameState(int stateIn, float p_i45194_2_)
{
this.state = stateIn;
this.field_149141_c = p_i45194_2_;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.state = buf.readUnsignedByte();
this.field_149141_c = buf.readFloat();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.state);
buf.writeFloat(this.field_149141_c);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleChangeGameState(this);
}
}

View file

@ -0,0 +1,48 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S2CPacketSpawnGlobalEntity implements Packet<INetHandlerPlayClient>
{
private int entityId;
private int x;
private int y;
private int z;
private int type;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
this.type = buf.readByte();
this.x = buf.readInt();
this.y = buf.readInt();
this.z = buf.readInt();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
buf.writeByte(this.type);
buf.writeInt(this.x);
buf.writeInt(this.y);
buf.writeInt(this.z);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSpawnGlobalEntity(this);
}
}

View file

@ -0,0 +1,57 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ChatComponent;
public class S2DPacketOpenWindow implements Packet<INetHandlerPlayClient>
{
private int windowId;
private String inventoryType;
private ChatComponent windowTitle;
private int slotCount;
private int entityId;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleOpenWindow(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readUnsignedByte();
this.inventoryType = buf.readStringFromBuffer(32);
this.windowTitle = buf.readChatComponent();
this.slotCount = buf.readUnsignedByte();
if (this.inventoryType.equals("EntityHorse"))
{
this.entityId = buf.readInt();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeString(this.inventoryType);
buf.writeChatComponent(this.windowTitle);
buf.writeByte(this.slotCount);
if (this.inventoryType.equals("EntityHorse"))
{
buf.writeInt(this.entityId);
}
}
}

View file

@ -0,0 +1,36 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S2EPacketCloseWindow implements Packet<INetHandlerPlayClient>
{
private int windowId;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleCloseWindow(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
}
}

View file

@ -0,0 +1,43 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ItemStack;
public class S2FPacketSetSlot implements Packet<INetHandlerPlayClient>
{
private int windowId;
private int slot;
private ItemStack item;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSetSlot(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readByte();
this.slot = buf.readShort();
this.item = buf.readItemStackFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeShort(this.slot);
buf.writeItemStackToBuffer(this.item);
}
}

View file

@ -0,0 +1,51 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ItemStack;
public class S30PacketWindowItems implements Packet<INetHandlerPlayClient>
{
private int windowId;
private ItemStack[] itemStacks;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readUnsignedByte();
int i = buf.readShort();
this.itemStacks = new ItemStack[i];
for (int j = 0; j < i; ++j)
{
this.itemStacks[j] = buf.readItemStackFromBuffer();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeShort(this.itemStacks.length);
for (ItemStack itemstack : this.itemStacks)
{
buf.writeItemStackToBuffer(itemstack);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleWindowItems(this);
}
}

View file

@ -0,0 +1,42 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S31PacketWindowProperty implements Packet<INetHandlerPlayClient>
{
private int windowId;
private int varIndex;
private int varValue;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleWindowProperty(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readUnsignedByte();
this.varIndex = buf.readShort();
this.varValue = buf.readShort();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeShort(this.varIndex);
buf.writeShort(this.varValue);
}
}

View file

@ -0,0 +1,42 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S32PacketConfirmTransaction implements Packet<INetHandlerPlayClient>
{
private int windowId;
private short actionNumber;
private boolean field_148893_c;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleConfirmTransaction(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.windowId = buf.readUnsignedByte();
this.actionNumber = buf.readShort();
this.field_148893_c = buf.readBoolean();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.windowId);
buf.writeShort(this.actionNumber);
buf.writeBoolean(this.field_148893_c);
}
}

View file

@ -0,0 +1,60 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
import proxy.util.ChatComponent;
import proxy.util.ChatComponentText;
public class S33PacketUpdateSign implements Packet<INetHandlerPlayClient>
{
private BlockPos blockPos;
private ChatComponent[] lines;
public S33PacketUpdateSign() {
}
public S33PacketUpdateSign(int x, int y, int z, String line1, String line2, String line3, String line4) {
this.blockPos = new BlockPos(x, y, z);
this.lines = new ChatComponent[] {new ChatComponentText(line1), new ChatComponentText(line2), new ChatComponentText(line3), new ChatComponentText(line4)};
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.blockPos = buf.readBlockPos();
this.lines = new ChatComponent[4];
for (int i = 0; i < 4; ++i)
{
this.lines[i] = buf.readChatComponent();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.blockPos);
for (int i = 0; i < 4; ++i)
{
buf.writeChatComponent(this.lines[i]);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleUpdateSign(this);
}
}

View file

@ -0,0 +1,116 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S34PacketMaps implements Packet<INetHandlerPlayClient>
{
private static class Vec4b
{
private byte field_176117_a;
private byte field_176115_b;
private byte field_176116_c;
private byte field_176114_d;
public Vec4b(byte p_i45555_1_, byte p_i45555_2_, byte p_i45555_3_, byte p_i45555_4_)
{
this.field_176117_a = p_i45555_1_;
this.field_176115_b = p_i45555_2_;
this.field_176116_c = p_i45555_3_;
this.field_176114_d = p_i45555_4_;
}
public byte func_176110_a()
{
return this.field_176117_a;
}
public byte func_176112_b()
{
return this.field_176115_b;
}
public byte func_176113_c()
{
return this.field_176116_c;
}
public byte func_176111_d()
{
return this.field_176114_d;
}
}
private int mapId;
private byte mapScale;
private Vec4b[] mapVisiblePlayersVec4b;
private int mapMinX;
private int mapMinY;
private int mapMaxX;
private int mapMaxY;
private byte[] mapDataBytes;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.mapId = buf.readVarIntFromBuffer();
this.mapScale = buf.readByte();
this.mapVisiblePlayersVec4b = new Vec4b[buf.readVarIntFromBuffer()];
for (int i = 0; i < this.mapVisiblePlayersVec4b.length; ++i)
{
short short1 = (short)buf.readByte();
this.mapVisiblePlayersVec4b[i] = new Vec4b((byte)(short1 >> 4 & 15), buf.readByte(), buf.readByte(), (byte)(short1 & 15));
}
this.mapMaxX = buf.readUnsignedByte();
if (this.mapMaxX > 0)
{
this.mapMaxY = buf.readUnsignedByte();
this.mapMinX = buf.readUnsignedByte();
this.mapMinY = buf.readUnsignedByte();
this.mapDataBytes = buf.readByteArray();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.mapId);
buf.writeByte(this.mapScale);
buf.writeVarIntToBuffer(this.mapVisiblePlayersVec4b.length);
for (Vec4b vec4b : this.mapVisiblePlayersVec4b)
{
buf.writeByte((vec4b.func_176110_a() & 15) << 4 | vec4b.func_176111_d() & 15);
buf.writeByte(vec4b.func_176112_b());
buf.writeByte(vec4b.func_176113_c());
}
buf.writeByte(this.mapMaxX);
if (this.mapMaxX > 0)
{
buf.writeByte(this.mapMaxY);
buf.writeByte(this.mapMinX);
buf.writeByte(this.mapMinY);
buf.writeByteArray(this.mapDataBytes);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleMaps(this);
}
}

View file

@ -0,0 +1,44 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.nbt.NBTTagCompound;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S35PacketUpdateTileEntity implements Packet<INetHandlerPlayClient>
{
private BlockPos blockPos;
private int metadata;
private NBTTagCompound nbt;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.blockPos = buf.readBlockPos();
this.metadata = buf.readUnsignedByte();
this.nbt = buf.readNBTTagCompoundFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.blockPos);
buf.writeByte((byte)this.metadata);
buf.writeNBTTagCompoundToBuffer(this.nbt);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleUpdateTileEntity(this);
}
}

View file

@ -0,0 +1,45 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.BlockPos;
public class S36PacketSignEditorOpen implements Packet<INetHandlerPlayClient>
{
private BlockPos signPosition;
public S36PacketSignEditorOpen() {
}
public S36PacketSignEditorOpen(int x, int y, int z) {
this.signPosition = new BlockPos(x, y, z);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSignEditorOpen(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.signPosition = buf.readBlockPos();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeBlockPos(this.signPosition);
}
}

View file

@ -0,0 +1,58 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.Map;
import java.util.Map.Entry;
import com.google.common.collect.Maps;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S37PacketStatistics implements Packet<INetHandlerPlayClient>
{
private Map<String, Integer> field_148976_a;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleStatistics(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
int i = buf.readVarIntFromBuffer();
this.field_148976_a = Maps.<String, Integer>newHashMap();
for (int j = 0; j < i; ++j)
{
String statbase = buf.readStringFromBuffer(32767);
int k = buf.readVarIntFromBuffer();
if (statbase != null)
{
this.field_148976_a.put(statbase, Integer.valueOf(k));
}
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.field_148976_a.size());
for (Entry<String, Integer> entry : this.field_148976_a.entrySet())
{
buf.writeString(entry.getKey());
buf.writeVarIntToBuffer(((Integer)entry.getValue()).intValue());
}
}
}

View file

@ -0,0 +1,253 @@
package net.minecraft.network.play.server;
import com.google.common.base.Objects;
import com.google.common.collect.Lists;
import java.io.IOException;
import java.util.List;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ChatComponent;
import proxy.util.GameProfile;
import proxy.util.Property;
public class S38PacketPlayerListItem implements Packet<INetHandlerPlayClient>
{
private S38PacketPlayerListItem.Action action;
private final List<S38PacketPlayerListItem.AddPlayerData> players = Lists.<S38PacketPlayerListItem.AddPlayerData>newArrayList();
public S38PacketPlayerListItem()
{
}
public S38PacketPlayerListItem(S38PacketPlayerListItem.Action actionIn, GameProfile profile, int ping, int mode, ChatComponent display)
{
this.action = actionIn;
this.players.add(new S38PacketPlayerListItem.AddPlayerData(profile, ping, mode, display));
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.action = (S38PacketPlayerListItem.Action)buf.readEnumValue(S38PacketPlayerListItem.Action.class);
int i = buf.readVarIntFromBuffer();
for (int j = 0; j < i; ++j)
{
GameProfile gameprofile = null;
int k = 0;
int worldsettings$gametype = 0;
ChatComponent ichatcomponent = null;
switch (this.action)
{
case ADD_PLAYER:
gameprofile = new GameProfile(buf.readUuid(), buf.readStringFromBuffer(16));
int l = buf.readVarIntFromBuffer();
int i1 = 0;
for (; i1 < l; ++i1)
{
String s = buf.readStringFromBuffer(32767);
String s1 = buf.readStringFromBuffer(32767);
if (buf.readBoolean())
{
gameprofile.getProperties().put(s, new Property(s, s1, buf.readStringFromBuffer(32767)));
}
else
{
gameprofile.getProperties().put(s, new Property(s, s1));
}
}
worldsettings$gametype = buf.readVarIntFromBuffer();
k = buf.readVarIntFromBuffer();
if (buf.readBoolean())
{
ichatcomponent = buf.readChatComponent();
}
break;
case UPDATE_GAME_MODE:
gameprofile = new GameProfile(buf.readUuid(), (String)null);
worldsettings$gametype = buf.readVarIntFromBuffer();
break;
case UPDATE_LATENCY:
gameprofile = new GameProfile(buf.readUuid(), (String)null);
k = buf.readVarIntFromBuffer();
break;
case UPDATE_DISPLAY_NAME:
gameprofile = new GameProfile(buf.readUuid(), (String)null);
if (buf.readBoolean())
{
ichatcomponent = buf.readChatComponent();
}
break;
case REMOVE_PLAYER:
gameprofile = new GameProfile(buf.readUuid(), (String)null);
}
this.players.add(new S38PacketPlayerListItem.AddPlayerData(gameprofile, k, worldsettings$gametype, ichatcomponent));
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeEnumValue(this.action);
buf.writeVarIntToBuffer(this.players.size());
for (S38PacketPlayerListItem.AddPlayerData s38packetplayerlistitem$addplayerdata : this.players)
{
switch (this.action)
{
case ADD_PLAYER:
buf.writeUuid(s38packetplayerlistitem$addplayerdata.getProfile().getId());
buf.writeString(s38packetplayerlistitem$addplayerdata.getProfile().getName());
buf.writeVarIntToBuffer(s38packetplayerlistitem$addplayerdata.getProfile().getProperties().size());
for (Property property : s38packetplayerlistitem$addplayerdata.getProfile().getProperties().values())
{
buf.writeString(property.getName());
buf.writeString(property.getValue());
if (property.hasSignature())
{
buf.writeBoolean(true);
buf.writeString(property.getSignature());
}
else
{
buf.writeBoolean(false);
}
}
buf.writeVarIntToBuffer(s38packetplayerlistitem$addplayerdata.getGameMode());
buf.writeVarIntToBuffer(s38packetplayerlistitem$addplayerdata.getPing());
if (s38packetplayerlistitem$addplayerdata.getDisplayName() == null)
{
buf.writeBoolean(false);
}
else
{
buf.writeBoolean(true);
buf.writeChatComponent(s38packetplayerlistitem$addplayerdata.getDisplayName());
}
break;
case UPDATE_GAME_MODE:
buf.writeUuid(s38packetplayerlistitem$addplayerdata.getProfile().getId());
buf.writeVarIntToBuffer(s38packetplayerlistitem$addplayerdata.getGameMode());
break;
case UPDATE_LATENCY:
buf.writeUuid(s38packetplayerlistitem$addplayerdata.getProfile().getId());
buf.writeVarIntToBuffer(s38packetplayerlistitem$addplayerdata.getPing());
break;
case UPDATE_DISPLAY_NAME:
buf.writeUuid(s38packetplayerlistitem$addplayerdata.getProfile().getId());
if (s38packetplayerlistitem$addplayerdata.getDisplayName() == null)
{
buf.writeBoolean(false);
}
else
{
buf.writeBoolean(true);
buf.writeChatComponent(s38packetplayerlistitem$addplayerdata.getDisplayName());
}
break;
case REMOVE_PLAYER:
buf.writeUuid(s38packetplayerlistitem$addplayerdata.getProfile().getId());
}
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handlePlayerListItem(this);
}
public List<S38PacketPlayerListItem.AddPlayerData> getEntries()
{
return this.players;
}
public S38PacketPlayerListItem.Action getAction()
{
return this.action;
}
public String toString()
{
return Objects.toStringHelper(this).add("action", this.action).add("entries", this.players).toString();
}
public static enum Action
{
ADD_PLAYER,
UPDATE_GAME_MODE,
UPDATE_LATENCY,
UPDATE_DISPLAY_NAME,
REMOVE_PLAYER;
}
public class AddPlayerData
{
private final int ping;
private final int gamemode;
private final GameProfile profile;
private final ChatComponent displayName;
public AddPlayerData(GameProfile profile, int pingIn, int gamemodeIn, ChatComponent displayNameIn)
{
this.profile = profile;
this.ping = pingIn;
this.gamemode = gamemodeIn;
this.displayName = displayNameIn;
}
public GameProfile getProfile()
{
return this.profile;
}
public int getPing()
{
return this.ping;
}
public int getGameMode()
{
return this.gamemode;
}
public ChatComponent getDisplayName()
{
return this.displayName;
}
}
}

View file

@ -0,0 +1,145 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S39PacketPlayerAbilities implements Packet<INetHandlerPlayClient>
{
private boolean invulnerable;
private boolean flying;
private boolean allowFlying;
private boolean creativeMode;
private float flySpeed;
private float walkSpeed;
public S39PacketPlayerAbilities()
{
}
public S39PacketPlayerAbilities(boolean spectator)
{
this.setInvulnerable(spectator);
this.setFlying(spectator);
this.setAllowFlying(spectator);
this.setCreativeMode(false);
this.setFlySpeed(0.05f);
this.setWalkSpeed(0.1f);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
byte b0 = buf.readByte();
this.setInvulnerable((b0 & 1) > 0);
this.setFlying((b0 & 2) > 0);
this.setAllowFlying((b0 & 4) > 0);
this.setCreativeMode((b0 & 8) > 0);
this.setFlySpeed(buf.readFloat());
this.setWalkSpeed(buf.readFloat());
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
byte b0 = 0;
if (this.isInvulnerable())
{
b0 = (byte)(b0 | 1);
}
if (this.isFlying())
{
b0 = (byte)(b0 | 2);
}
if (this.isAllowFlying())
{
b0 = (byte)(b0 | 4);
}
if (this.isCreativeMode())
{
b0 = (byte)(b0 | 8);
}
buf.writeByte(b0);
buf.writeFloat(this.flySpeed);
buf.writeFloat(this.walkSpeed);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handlePlayerAbilities(this);
}
public boolean isInvulnerable()
{
return this.invulnerable;
}
public void setInvulnerable(boolean isInvulnerable)
{
this.invulnerable = isInvulnerable;
}
public boolean isFlying()
{
return this.flying;
}
public void setFlying(boolean isFlying)
{
this.flying = isFlying;
}
public boolean isAllowFlying()
{
return this.allowFlying;
}
public void setAllowFlying(boolean isAllowFlying)
{
this.allowFlying = isAllowFlying;
}
public boolean isCreativeMode()
{
return this.creativeMode;
}
public void setCreativeMode(boolean isCreativeMode)
{
this.creativeMode = isCreativeMode;
}
public float getFlySpeed()
{
return this.flySpeed;
}
public void setFlySpeed(float flySpeedIn)
{
this.flySpeed = flySpeedIn;
}
public float getWalkSpeed()
{
return this.walkSpeed;
}
public void setWalkSpeed(float walkSpeedIn)
{
this.walkSpeed = walkSpeedIn;
}
}

View file

@ -0,0 +1,60 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S3APacketTabComplete implements Packet<INetHandlerPlayClient>
{
private String[] matches;
public S3APacketTabComplete()
{
}
public S3APacketTabComplete(String[] matchesIn)
{
this.matches = matchesIn;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.matches = new String[buf.readVarIntFromBuffer()];
for (int i = 0; i < this.matches.length; ++i)
{
this.matches[i] = buf.readStringFromBuffer(32767);
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.matches.length);
for (String s : this.matches)
{
buf.writeString(s);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleTabComplete(this);
}
public String[] func_149630_c()
{
return this.matches;
}
}

View file

@ -0,0 +1,53 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S3BPacketScoreboardObjective implements Packet<INetHandlerPlayClient>
{
private String objectiveName;
private String objectiveValue;
private String type;
private int field_149342_c;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.objectiveName = buf.readStringFromBuffer(16);
this.field_149342_c = buf.readByte();
if (this.field_149342_c == 0 || this.field_149342_c == 2)
{
this.objectiveValue = buf.readStringFromBuffer(32);
this.type = buf.readStringFromBuffer(16);
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.objectiveName);
buf.writeByte(this.field_149342_c);
if (this.field_149342_c == 0 || this.field_149342_c == 2)
{
buf.writeString(this.objectiveValue);
buf.writeString(this.type);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleScoreboardObjective(this);
}
}

View file

@ -0,0 +1,59 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S3CPacketUpdateScore implements Packet<INetHandlerPlayClient>
{
private String name = "";
private String objective = "";
private int value;
private S3CPacketUpdateScore.Action action;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.name = buf.readStringFromBuffer(40);
this.action = (S3CPacketUpdateScore.Action)buf.readEnumValue(S3CPacketUpdateScore.Action.class);
this.objective = buf.readStringFromBuffer(16);
if (this.action != S3CPacketUpdateScore.Action.REMOVE)
{
this.value = buf.readVarIntFromBuffer();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.name);
buf.writeEnumValue(this.action);
buf.writeString(this.objective);
if (this.action != S3CPacketUpdateScore.Action.REMOVE)
{
buf.writeVarIntToBuffer(this.value);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleUpdateScore(this);
}
public static enum Action
{
CHANGE,
REMOVE;
}
}

View file

@ -0,0 +1,39 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S3DPacketDisplayScoreboard implements Packet<INetHandlerPlayClient>
{
private int position;
private String scoreName;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.position = buf.readByte();
this.scoreName = buf.readStringFromBuffer(16);
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.position);
buf.writeString(this.scoreName);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleDisplayScoreboard(this);
}
}

View file

@ -0,0 +1,96 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import java.util.Collection;
import com.google.common.collect.Lists;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S3EPacketTeams implements Packet<INetHandlerPlayClient>
{
private String name = "";
private String displayName = "";
private String prefix = "";
private String suffix = "";
private String nameTagVisibility;
private int color;
private Collection<String> players;
private int action;
private int friendlyFlags;
public S3EPacketTeams()
{
this.nameTagVisibility = "always";
this.color = -1;
this.players = Lists.newArrayList();
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.name = buf.readStringFromBuffer(16);
this.action = buf.readByte();
if (this.action == 0 || this.action == 2)
{
this.displayName = buf.readStringFromBuffer(32);
this.prefix = buf.readStringFromBuffer(16);
this.suffix = buf.readStringFromBuffer(16);
this.friendlyFlags = buf.readByte();
this.nameTagVisibility = buf.readStringFromBuffer(32);
this.color = buf.readByte();
}
if (this.action == 0 || this.action == 3 || this.action == 4)
{
int i = buf.readVarIntFromBuffer();
for (int j = 0; j < i; ++j)
{
this.players.add(buf.readStringFromBuffer(40));
}
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.name);
buf.writeByte(this.action);
if (this.action == 0 || this.action == 2)
{
buf.writeString(this.displayName);
buf.writeString(this.prefix);
buf.writeString(this.suffix);
buf.writeByte(this.friendlyFlags);
buf.writeString(this.nameTagVisibility);
buf.writeByte(this.color);
}
if (this.action == 0 || this.action == 3 || this.action == 4)
{
buf.writeVarIntToBuffer(this.players.size());
for (String s : this.players)
{
buf.writeString(s);
}
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleTeams(this);
}
}

View file

@ -0,0 +1,74 @@
package net.minecraft.network.play.server;
import io.netty.buffer.ByteBuf;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S3FPacketCustomPayload implements Packet<INetHandlerPlayClient>
{
private String channel;
private PacketBuffer data;
public S3FPacketCustomPayload()
{
}
public S3FPacketCustomPayload(String channelName, PacketBuffer dataIn)
{
this.channel = channelName;
this.data = dataIn;
if (dataIn.writerIndex() > 1048576)
{
throw new IllegalArgumentException("Payload may not be larger than 1048576 bytes");
}
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.channel = buf.readStringFromBuffer(20);
int i = buf.readableBytes();
if (i >= 0 && i <= 1048576)
{
this.data = new PacketBuffer(buf.readBytes(i));
}
else
{
throw new IOException("Payload may not be larger than 1048576 bytes");
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeString(this.channel);
buf.writeBytes((ByteBuf)this.data);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleCustomPayload(this);
}
public String getChannelName()
{
return this.channel;
}
public PacketBuffer getBufferData()
{
return this.data;
}
}

View file

@ -0,0 +1,51 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ChatComponent;
public class S40PacketDisconnect implements Packet<INetHandlerPlayClient>
{
private ChatComponent reason;
public S40PacketDisconnect()
{
}
public S40PacketDisconnect(ChatComponent reasonIn)
{
this.reason = reasonIn;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.reason = buf.readChatComponent();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeChatComponent(this.reason);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleDisconnect(this);
}
public ChatComponent getReason()
{
return this.reason;
}
}

View file

@ -0,0 +1,36 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S41PacketServerDifficulty implements Packet<INetHandlerPlayClient>
{
private byte difficulty;
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleServerDifficulty(this);
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.difficulty = (byte)buf.readUnsignedByte();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeByte(this.difficulty);
}
}

View file

@ -0,0 +1,71 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S42PacketCombatEvent implements Packet<INetHandlerPlayClient>
{
public S42PacketCombatEvent.Event eventType;
public int field_179774_b;
public int field_179775_c;
public int field_179772_d;
public String deathMessage;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.eventType = (S42PacketCombatEvent.Event)buf.readEnumValue(S42PacketCombatEvent.Event.class);
if (this.eventType == S42PacketCombatEvent.Event.END_COMBAT)
{
this.field_179772_d = buf.readVarIntFromBuffer();
this.field_179775_c = buf.readInt();
}
else if (this.eventType == S42PacketCombatEvent.Event.ENTITY_DIED)
{
this.field_179774_b = buf.readVarIntFromBuffer();
this.field_179775_c = buf.readInt();
this.deathMessage = buf.readStringFromBuffer(32767);
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeEnumValue(this.eventType);
if (this.eventType == S42PacketCombatEvent.Event.END_COMBAT)
{
buf.writeVarIntToBuffer(this.field_179772_d);
buf.writeInt(this.field_179775_c);
}
else if (this.eventType == S42PacketCombatEvent.Event.ENTITY_DIED)
{
buf.writeVarIntToBuffer(this.field_179774_b);
buf.writeInt(this.field_179775_c);
buf.writeString(this.deathMessage);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleCombatEvent(this);
}
public static enum Event
{
ENTER_COMBAT,
END_COMBAT,
ENTITY_DIED;
}
}

View file

@ -0,0 +1,36 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S43PacketCamera implements Packet<INetHandlerPlayClient>
{
private int entityId;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.entityId = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.entityId);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleCamera(this);
}
}

View file

@ -0,0 +1,126 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S44PacketWorldBorder implements Packet<INetHandlerPlayClient>
{
private S44PacketWorldBorder.Action action;
private int size;
private double centerX;
private double centerZ;
private double targetSize;
private double diameter;
private long timeUntilTarget;
private int warningTime;
private int warningDistance;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.action = (S44PacketWorldBorder.Action)buf.readEnumValue(S44PacketWorldBorder.Action.class);
switch (this.action)
{
case SET_SIZE:
this.targetSize = buf.readDouble();
break;
case LERP_SIZE:
this.diameter = buf.readDouble();
this.targetSize = buf.readDouble();
this.timeUntilTarget = buf.readVarLong();
break;
case SET_CENTER:
this.centerX = buf.readDouble();
this.centerZ = buf.readDouble();
break;
case SET_WARNING_BLOCKS:
this.warningDistance = buf.readVarIntFromBuffer();
break;
case SET_WARNING_TIME:
this.warningTime = buf.readVarIntFromBuffer();
break;
case INITIALIZE:
this.centerX = buf.readDouble();
this.centerZ = buf.readDouble();
this.diameter = buf.readDouble();
this.targetSize = buf.readDouble();
this.timeUntilTarget = buf.readVarLong();
this.size = buf.readVarIntFromBuffer();
this.warningDistance = buf.readVarIntFromBuffer();
this.warningTime = buf.readVarIntFromBuffer();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeEnumValue(this.action);
switch (this.action)
{
case SET_SIZE:
buf.writeDouble(this.targetSize);
break;
case LERP_SIZE:
buf.writeDouble(this.diameter);
buf.writeDouble(this.targetSize);
buf.writeVarLong(this.timeUntilTarget);
break;
case SET_CENTER:
buf.writeDouble(this.centerX);
buf.writeDouble(this.centerZ);
break;
case SET_WARNING_BLOCKS:
buf.writeVarIntToBuffer(this.warningDistance);
break;
case SET_WARNING_TIME:
buf.writeVarIntToBuffer(this.warningTime);
break;
case INITIALIZE:
buf.writeDouble(this.centerX);
buf.writeDouble(this.centerZ);
buf.writeDouble(this.diameter);
buf.writeDouble(this.targetSize);
buf.writeVarLong(this.timeUntilTarget);
buf.writeVarIntToBuffer(this.size);
buf.writeVarIntToBuffer(this.warningDistance);
buf.writeVarIntToBuffer(this.warningTime);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleWorldBorder(this);
}
public static enum Action
{
SET_SIZE,
LERP_SIZE,
SET_CENTER,
INITIALIZE,
SET_WARNING_TIME,
SET_WARNING_BLOCKS;
}
}

View file

@ -0,0 +1,123 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ChatComponent;
public class S45PacketTitle implements Packet<INetHandlerPlayClient>
{
private S45PacketTitle.Type type;
private ChatComponent message;
private int fadeInTime;
private int displayTime;
private int fadeOutTime;
public S45PacketTitle()
{
}
public S45PacketTitle(S45PacketTitle.Type type, ChatComponent message)
{
this(type, message, -1, -1, -1);
}
public S45PacketTitle(int fadeInTime, int displayTime, int fadeOutTime)
{
this(S45PacketTitle.Type.TIMES, (ChatComponent)null, fadeInTime, displayTime, fadeOutTime);
}
public S45PacketTitle(S45PacketTitle.Type type, ChatComponent message, int fadeInTime, int displayTime, int fadeOutTime)
{
this.type = type;
this.message = message;
this.fadeInTime = fadeInTime;
this.displayTime = displayTime;
this.fadeOutTime = fadeOutTime;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.type = (S45PacketTitle.Type)buf.readEnumValue(S45PacketTitle.Type.class);
if (this.type == S45PacketTitle.Type.TITLE || this.type == S45PacketTitle.Type.SUBTITLE)
{
this.message = buf.readChatComponent();
}
if (this.type == S45PacketTitle.Type.TIMES)
{
this.fadeInTime = buf.readInt();
this.displayTime = buf.readInt();
this.fadeOutTime = buf.readInt();
}
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeEnumValue(this.type);
if (this.type == S45PacketTitle.Type.TITLE || this.type == S45PacketTitle.Type.SUBTITLE)
{
buf.writeChatComponent(this.message);
}
if (this.type == S45PacketTitle.Type.TIMES)
{
buf.writeInt(this.fadeInTime);
buf.writeInt(this.displayTime);
buf.writeInt(this.fadeOutTime);
}
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleTitle(this);
}
public static enum Type
{
TITLE,
SUBTITLE,
TIMES,
CLEAR,
RESET;
public static S45PacketTitle.Type byName(String name)
{
for (S45PacketTitle.Type s45packettitle$type : values())
{
if (s45packettitle$type.name().equalsIgnoreCase(name))
{
return s45packettitle$type;
}
}
return TITLE;
}
public static String[] getNames()
{
String[] astring = new String[values().length];
int i = 0;
for (S45PacketTitle.Type s45packettitle$type : values())
{
astring[i++] = s45packettitle$type.name().toLowerCase();
}
return astring;
}
}
}

View file

@ -0,0 +1,41 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
public class S46PacketSetCompressionLevel implements Packet<INetHandlerPlayClient>
{
private int threshold;
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.threshold = buf.readVarIntFromBuffer();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeVarIntToBuffer(this.threshold);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handleSetCompressionLevel(this);
}
public int getThreshold()
{
return this.threshold;
}
}

View file

@ -0,0 +1,50 @@
package net.minecraft.network.play.server;
import java.io.IOException;
import proxy.network.INetHandlerPlayClient;
import proxy.network.Packet;
import proxy.network.PacketBuffer;
import proxy.util.ChatComponent;
public class S47PacketPlayerListHeaderFooter implements Packet<INetHandlerPlayClient>
{
private ChatComponent header;
private ChatComponent footer;
public S47PacketPlayerListHeaderFooter()
{
}
public S47PacketPlayerListHeaderFooter(ChatComponent headerIn, ChatComponent footerIn)
{
this.header = headerIn;
this.footer = footerIn;
}
/**
* Reads the raw packet data from the data stream.
*/
public void readPacketData(PacketBuffer buf) throws IOException
{
this.header = buf.readChatComponent();
this.footer = buf.readChatComponent();
}
/**
* Writes the raw packet data to the data stream.
*/
public void writePacketData(PacketBuffer buf) throws IOException
{
buf.writeChatComponent(this.header);
buf.writeChatComponent(this.footer);
}
/**
* Passes this Packet on to the NetHandler for processing.
*/
public void processPacket(INetHandlerPlayClient handler)
{
handler.handlePlayerListHeaderFooter(this);
}
}

Some files were not shown because too many files have changed in this diff Show more