Update to Minecraft 1.12-pre5

Obsoletes 1.12-pre2
This commit is contained in:
md_5 2017-05-19 21:00:04 +10:00
parent 16d261553c
commit 09ee2b1644
3 changed files with 21 additions and 21 deletions

View File

@ -61,42 +61,42 @@ public enum Protocol
KeepAlive.class,
map( ProtocolConstants.MINECRAFT_1_8, 0x00 ),
map( ProtocolConstants.MINECRAFT_1_9, 0x1F ),
map( ProtocolConstants.MINECRAFT_1_12, 0x20 )
map( ProtocolConstants.MINECRAFT_1_12, 0x1F )
);
TO_CLIENT.registerPacket(
Login.class,
map( ProtocolConstants.MINECRAFT_1_8, 0x01 ),
map( ProtocolConstants.MINECRAFT_1_9, 0x23 ),
map( ProtocolConstants.MINECRAFT_1_12, 0x24 )
map( ProtocolConstants.MINECRAFT_1_12, 0x23 )
);
TO_CLIENT.registerPacket(
Chat.class,
map( ProtocolConstants.MINECRAFT_1_8, 0x02 ),
map( ProtocolConstants.MINECRAFT_1_9, 0x0F ),
map( ProtocolConstants.MINECRAFT_1_12, 0x10 )
map( ProtocolConstants.MINECRAFT_1_12, 0x0F )
);
TO_CLIENT.registerPacket(
Respawn.class,
map( ProtocolConstants.MINECRAFT_1_8, 0x07 ),
map( ProtocolConstants.MINECRAFT_1_9, 0x33 ),
map( ProtocolConstants.MINECRAFT_1_12, 0x35 )
map( ProtocolConstants.MINECRAFT_1_12, 0x34 )
);
TO_CLIENT.registerPacket(
BossBar.class,
map( ProtocolConstants.MINECRAFT_1_9, 0x0C ),
map( ProtocolConstants.MINECRAFT_1_12, 0x0D )
map( ProtocolConstants.MINECRAFT_1_12, 0x0C )
);
TO_CLIENT.registerPacket(
PlayerListItem.class, // PlayerInfo
map( ProtocolConstants.MINECRAFT_1_8, 0x38 ),
map( ProtocolConstants.MINECRAFT_1_9, 0x2D ),
map( ProtocolConstants.MINECRAFT_1_12, 0x2E )
map( ProtocolConstants.MINECRAFT_1_12, 0x2D )
);
TO_CLIENT.registerPacket(
TabCompleteResponse.class,
map( ProtocolConstants.MINECRAFT_1_8, 0x3A ),
map( ProtocolConstants.MINECRAFT_1_9, 0x0E ),
map( ProtocolConstants.MINECRAFT_1_12, 0x0F )
map( ProtocolConstants.MINECRAFT_1_12, 0x0E )
);
TO_CLIENT.registerPacket(
ScoreboardObjective.class,
@ -126,13 +126,13 @@ public enum Protocol
PluginMessage.class,
map( ProtocolConstants.MINECRAFT_1_8, 0x3F ),
map( ProtocolConstants.MINECRAFT_1_9, 0x18 ),
map( ProtocolConstants.MINECRAFT_1_12, 0x19 )
map( ProtocolConstants.MINECRAFT_1_12, 0x18 )
);
TO_CLIENT.registerPacket(
Kick.class,
map( ProtocolConstants.MINECRAFT_1_8, 0x40 ),
map( ProtocolConstants.MINECRAFT_1_9, 0x1A ),
map( ProtocolConstants.MINECRAFT_1_12, 0x1B )
map( ProtocolConstants.MINECRAFT_1_12, 0x1A )
);
TO_CLIENT.registerPacket(
Title.class,

View File

@ -14,7 +14,7 @@ public class ProtocolConstants
public static final int MINECRAFT_1_10 = 210;
public static final int MINECRAFT_1_11 = 315;
public static final int MINECRAFT_1_11_1 = 316;
public static final int MINECRAFT_1_12 = 329;
public static final int MINECRAFT_1_12 = 332;
public static final List<String> SUPPORTED_VERSIONS = Arrays.asList(
"1.8.x",
"1.9.x",

View File

@ -24,14 +24,14 @@ class EntityMap_1_12 extends EntityMap
addRewrite( 0x05, ProtocolConstants.Direction.TO_CLIENT, true ); // Spawn Player : PacketPlayOutNamedEntitySpawn
addRewrite( 0x06, ProtocolConstants.Direction.TO_CLIENT, true ); // Animation : PacketPlayOutAnimation
addRewrite( 0x08, ProtocolConstants.Direction.TO_CLIENT, true ); // Block Break Animation : PacketPlayOutBlockBreakAnimation
addRewrite( 0x1C, ProtocolConstants.Direction.TO_CLIENT, false ); // Entity Status : PacketPlayOutEntityStatus
addRewrite( 0x26, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Relative Move : PacketPlayOutRelEntityMove
addRewrite( 0x27, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Look and Relative Move : PacketPlayOutRelEntityMoveLook
addRewrite( 0x28, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Look : PacketPlayOutEntityLook
addRewrite( 0x29, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity : PacketPlayOutEntity
addRewrite( 0x30, ProtocolConstants.Direction.TO_CLIENT, true ); // Use bed : PacketPlayOutBed
addRewrite( 0x33, ProtocolConstants.Direction.TO_CLIENT, true ); // Remove Entity Effect : PacketPlayOutRemoveEntityEffect
addRewrite( 0x36, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Head Look : PacketPlayOutEntityHeadRotation
addRewrite( 0x1B, ProtocolConstants.Direction.TO_CLIENT, false ); // Entity Status : PacketPlayOutEntityStatus
addRewrite( 0x25, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Relative Move : PacketPlayOutRelEntityMove
addRewrite( 0x26, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Look and Relative Move : PacketPlayOutRelEntityMoveLook
addRewrite( 0x27, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Look : PacketPlayOutEntityLook
addRewrite( 0x28, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity : PacketPlayOutEntity
addRewrite( 0x2F, ProtocolConstants.Direction.TO_CLIENT, true ); // Use bed : PacketPlayOutBed
addRewrite( 0x31, ProtocolConstants.Direction.TO_CLIENT, true ); // Remove Entity Effect : PacketPlayOutRemoveEntityEffect
addRewrite( 0x35, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Head Look : PacketPlayOutEntityHeadRotation
addRewrite( 0x38, ProtocolConstants.Direction.TO_CLIENT, true ); // Camera : PacketPlayOutCamera
addRewrite( 0x3B, ProtocolConstants.Direction.TO_CLIENT, true ); // Entity Metadata : PacketPlayOutEntityMetadata
addRewrite( 0x3C, ProtocolConstants.Direction.TO_CLIENT, false ); // Attach Entity : PacketPlayOutAttachEntity
@ -71,7 +71,7 @@ class EntityMap_1_12 extends EntityMap
DefinedPacket.readVarInt( packet );
jumpIndex = packet.readerIndex();
// Fall through on purpose to int array of IDs
case 0x32 /* Destroy Entities : PacketPlayOutEntityDestroy */:
case 0x31 /* Destroy Entities : PacketPlayOutEntityDestroy */:
int count = DefinedPacket.readVarInt( packet );
int[] ids = new int[ count ];
for ( int i = 0; i < count; i++ )
@ -132,7 +132,7 @@ class EntityMap_1_12 extends EntityMap
packet.writerIndex( previous );
}
break;
case 0x2D /* Combat Event : PacketPlayOutCombatEvent */:
case 0x2C /* Combat Event : PacketPlayOutCombatEvent */:
int event = packet.readUnsignedByte();
if ( event == 1 /* End Combat*/ )
{
@ -164,7 +164,7 @@ class EntityMap_1_12 extends EntityMap
int packetId = DefinedPacket.readVarInt( packet );
int packetIdLength = packet.readerIndex() - readerIndex;
if ( packetId == 0x1D /* Spectate : PacketPlayInSpectate */ && !BungeeCord.getInstance().getConfig().isIpForward() )
if ( packetId == 0x1E /* Spectate : PacketPlayInSpectate */ && !BungeeCord.getInstance().getConfig().isIpForward() )
{
UUID uuid = DefinedPacket.readUUID( packet );
ProxiedPlayer player;