Archiviert
13
0
Dieses Repository wurde am 2024-12-25 archiviert. Du kannst Dateien ansehen und es klonen, aber nicht pushen oder Issues/Pull-Requests öffnen.
Paper-Old/src/main/java/net/minecraft/server/PacketHandshakingInSetProtocol.java
2013-11-30 19:26:12 -06:00

48 Zeilen
1.3 KiB
Java

package net.minecraft.server;
import java.io.IOException; // CraftBukkit
public class PacketHandshakingInSetProtocol extends Packet {
private int a;
public String b; // CraftBukkit private -> public
public int c; // CraftBukkit private -> public
private EnumProtocol d;
public PacketHandshakingInSetProtocol() {}
public void a(PacketDataSerializer packetdataserializer) throws IOException { // CraftBukkit - added throws
this.a = packetdataserializer.a();
this.b = packetdataserializer.c(255);
this.c = packetdataserializer.readUnsignedShort();
this.d = EnumProtocol.a(packetdataserializer.a());
}
public void b(PacketDataSerializer packetdataserializer) throws IOException { // CraftBukkit - added throws
packetdataserializer.b(this.a);
packetdataserializer.a(this.b);
packetdataserializer.writeShort(this.c);
packetdataserializer.b(this.d.c());
}
public void a(PacketHandshakingInListener packethandshakinginlistener) {
packethandshakinginlistener.a(this);
}
public boolean a() {
return true;
}
public EnumProtocol c() {
return this.d;
}
public int d() {
return this.a;
}
public void handle(PacketListener packetlistener) {
this.a((PacketHandshakingInListener) packetlistener);
}
}