mirror of
https://github.com/GeyserMC/MCProtocolLib.git
synced 2024-12-04 21:01:02 -05:00
Update to 1.14.3
This commit is contained in:
parent
520589e647
commit
0dc580ee23
3 changed files with 12 additions and 4 deletions
2
pom.xml
2
pom.xml
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
<groupId>com.github.steveice10</groupId>
|
<groupId>com.github.steveice10</groupId>
|
||||||
<artifactId>mcprotocollib</artifactId>
|
<artifactId>mcprotocollib</artifactId>
|
||||||
<version>1.14.2-SNAPSHOT</version>
|
<version>1.14.3-SNAPSHOT</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>MCProtocolLib</name>
|
<name>MCProtocolLib</name>
|
||||||
|
|
|
@ -2,8 +2,8 @@ package com.github.steveice10.mc.protocol;
|
||||||
|
|
||||||
public class MinecraftConstants {
|
public class MinecraftConstants {
|
||||||
// General Constants
|
// General Constants
|
||||||
public static final String GAME_VERSION = "1.14.2";
|
public static final String GAME_VERSION = "1.14.3";
|
||||||
public static final int PROTOCOL_VERSION = 485;
|
public static final int PROTOCOL_VERSION = 490;
|
||||||
|
|
||||||
// General Key Constants
|
// General Key Constants
|
||||||
public static final String PROFILE_KEY = "profile";
|
public static final String PROFILE_KEY = "profile";
|
||||||
|
|
|
@ -16,16 +16,18 @@ public class ServerTradeListPacket extends MinecraftPacket {
|
||||||
private int villagerLevel;
|
private int villagerLevel;
|
||||||
private int experience;
|
private int experience;
|
||||||
private boolean isRegularVillager;
|
private boolean isRegularVillager;
|
||||||
|
private boolean canRestock;
|
||||||
|
|
||||||
public ServerTradeListPacket() {
|
public ServerTradeListPacket() {
|
||||||
}
|
}
|
||||||
|
|
||||||
public ServerTradeListPacket(int windowId, VillagerTrade[] trades, int villagerLevel, int experience, boolean isRegularVillager) {
|
public ServerTradeListPacket(int windowId, VillagerTrade[] trades, int villagerLevel, int experience, boolean isRegularVillager, boolean canRestock) {
|
||||||
this.windowId = windowId;
|
this.windowId = windowId;
|
||||||
this.trades = trades;
|
this.trades = trades;
|
||||||
this.villagerLevel = villagerLevel;
|
this.villagerLevel = villagerLevel;
|
||||||
this.experience = experience;
|
this.experience = experience;
|
||||||
this.isRegularVillager = isRegularVillager;
|
this.isRegularVillager = isRegularVillager;
|
||||||
|
this.canRestock = canRestock;
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getWindowId() {
|
public int getWindowId() {
|
||||||
|
@ -48,6 +50,10 @@ public class ServerTradeListPacket extends MinecraftPacket {
|
||||||
return isRegularVillager;
|
return isRegularVillager;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean canRestock() {
|
||||||
|
return canRestock;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void read(NetInput in) throws IOException {
|
public void read(NetInput in) throws IOException {
|
||||||
this.windowId = in.readVarInt();
|
this.windowId = in.readVarInt();
|
||||||
|
@ -76,6 +82,7 @@ public class ServerTradeListPacket extends MinecraftPacket {
|
||||||
this.villagerLevel = in.readVarInt();
|
this.villagerLevel = in.readVarInt();
|
||||||
this.experience = in.readVarInt();
|
this.experience = in.readVarInt();
|
||||||
this.isRegularVillager = in.readBoolean();
|
this.isRegularVillager = in.readBoolean();
|
||||||
|
this.canRestock = in.readBoolean();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -106,5 +113,6 @@ public class ServerTradeListPacket extends MinecraftPacket {
|
||||||
out.writeVarInt(this.villagerLevel);
|
out.writeVarInt(this.villagerLevel);
|
||||||
out.writeVarInt(this.experience);
|
out.writeVarInt(this.experience);
|
||||||
out.writeBoolean(this.isRegularVillager);
|
out.writeBoolean(this.isRegularVillager);
|
||||||
|
out.writeBoolean(this.canRestock);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue