mirror of
https://github.com/PaperMC/Waterfall.git
synced 2024-11-28 13:15:31 +01:00
Resolve previous bad merge - opps
This commit is contained in:
parent
db05bbac39
commit
710c45640c
@ -1,4 +1,4 @@
|
|||||||
From a5b6dce1c9847a01bff890ab2a486efb9813d564 Mon Sep 17 00:00:00 2001
|
From 413c03afc73fede6e6f1eecf0c020dceaa84ed92 Mon Sep 17 00:00:00 2001
|
||||||
From: Techcable <Techcable@techcable.net>
|
From: Techcable <Techcable@techcable.net>
|
||||||
Date: Thu, 19 May 2016 17:09:22 -0600
|
Date: Thu, 19 May 2016 17:09:22 -0600
|
||||||
Subject: [PATCH] Allow invalid packet ids for forge servers
|
Subject: [PATCH] Allow invalid packet ids for forge servers
|
||||||
@ -37,20 +37,24 @@ index e7cb3803..447eaae7 100644
|
|||||||
{
|
{
|
||||||
packet.read( in, prot.getDirection(), protocolVersion );
|
packet.read( in, prot.getDirection(), protocolVersion );
|
||||||
diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
||||||
index 57a93c93..2ca7fec4 100644
|
index 57a93c93..0dfc4a31 100644
|
||||||
--- a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
--- a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
||||||
+++ b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
+++ b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
||||||
@@ -336,14 +336,18 @@ public enum Protocol
|
@@ -336,14 +336,23 @@ public enum Protocol
|
||||||
return protocol;
|
return protocol;
|
||||||
}
|
}
|
||||||
|
|
||||||
- public final DefinedPacket createPacket(int id, int version)
|
|
||||||
+ public boolean hasPacket(int i, boolean supportsForge) {
|
+ public boolean hasPacket(int i, boolean supportsForge) {
|
||||||
+ return supportsForge || i >= 0 && i <= MAX_PACKET_ID;
|
+ return supportsForge || i >= 0 && i <= MAX_PACKET_ID;
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
+ public final DefinedPacket createPacket(int id, int version, boolean supportsForge)
|
public final DefinedPacket createPacket(int id, int version)
|
||||||
{
|
{
|
||||||
|
+ return createPacket(id, version, true);
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ public final DefinedPacket createPacket(int id, int version, boolean supportsForge)
|
||||||
|
+ {
|
||||||
ProtocolData protocolData = getProtocolData( version );
|
ProtocolData protocolData = getProtocolData( version );
|
||||||
if (protocolData == null)
|
if (protocolData == null)
|
||||||
{
|
{
|
||||||
@ -118,5 +122,5 @@ index 6a794175..ec154429 100644
|
|||||||
{
|
{
|
||||||
rewriteInt( packet, oldId, newId, readerIndex + packetIdLength );
|
rewriteInt( packet, oldId, newId, readerIndex + packetIdLength );
|
||||||
--
|
--
|
||||||
2.12.0
|
2.13.0
|
||||||
|
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
From 0b651d342eec029126a06c1d93bae18f460b67de Mon Sep 17 00:00:00 2001
|
From 3c673a369304650e538163d8054132eb00a295ec Mon Sep 17 00:00:00 2001
|
||||||
From: Techcable <Techcable@techcable.net>
|
From: Techcable <Techcable@techcable.net>
|
||||||
Date: Wed, 6 Apr 2016 23:46:00 -0700
|
Date: Wed, 6 Apr 2016 23:46:00 -0700
|
||||||
Subject: [PATCH] Better debug checks
|
Subject: [PATCH] Better debug checks
|
||||||
|
|
||||||
|
|
||||||
diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
||||||
index 2ca7fec4..5636e67c 100644
|
index 0dfc4a31..a7036833 100644
|
||||||
--- a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
--- a/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
||||||
+++ b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
+++ b/protocol/src/main/java/net/md_5/bungee/protocol/Protocol.java
|
||||||
@@ -404,7 +404,7 @@ public enum Protocol
|
@@ -409,7 +409,7 @@ public enum Protocol
|
||||||
{
|
{
|
||||||
throw new BadPacketException( "Unsupported protocol version" );
|
throw new BadPacketException( "Unsupported protocol version" );
|
||||||
}
|
}
|
||||||
@ -18,5 +18,5 @@ index 2ca7fec4..5636e67c 100644
|
|||||||
return protocolData.packetMap.get( packet );
|
return protocolData.packetMap.get( packet );
|
||||||
}
|
}
|
||||||
--
|
--
|
||||||
2.12.0
|
2.13.0
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user