diff --git a/patches/api/0033-Fix-javadoc-warnings-missing-param-and-return.patch b/patches/api/0033-Fix-javadoc-warnings-missing-param-and-return.patch index ac8774b67..91345e10e 100644 --- a/patches/api/0033-Fix-javadoc-warnings-missing-param-and-return.patch +++ b/patches/api/0033-Fix-javadoc-warnings-missing-param-and-return.patch @@ -534,7 +534,7 @@ index 28a1fe3af1546daa779df46468e0ff8ad823f9ca..7a3be414ef9d54d7a852ba92d704011f @NotNull diff --git a/src/main/java/org/bukkit/UnsafeValues.java b/src/main/java/org/bukkit/UnsafeValues.java -index 6dbd520182b1e7713a68baad09b7f613424ef619..14244cc7f11035c4da4613bbdf49dac51f0da3cf 100644 +index 6dbd520182b1e7713a68baad09b7f613424ef619..7899609b7a3041477d5240deaeee9b80159c2db3 100644 --- a/src/main/java/org/bukkit/UnsafeValues.java +++ b/src/main/java/org/bukkit/UnsafeValues.java @@ -87,6 +87,8 @@ public interface UnsafeValues { @@ -582,6 +582,35 @@ index 6dbd520182b1e7713a68baad09b7f613424ef619..14244cc7f11035c4da4613bbdf49dac5 */ public int nextEntityId(); +@@ -162,4 +172,28 @@ public interface UnsafeValues { + */ + int getProtocolVersion(); + // Paper end ++ ++ // Purpur start ++ ++ /** ++ * Serialize entity to byte array ++ * ++ * @param entity entity to serialize ++ * @return serialized entity ++ */ ++ byte[] serializeEntity(org.bukkit.entity.Entity entity); ++ ++ /** ++ * Deserialize an entity from byte array ++ *
++ * The entity is not automatically spawned in the world. You will have to spawn
++ * the entity yourself with {@link org.bukkit.entity.Entity#spawnAt(Location)} or
++ * {@link org.bukkit.entity.Entity#spawnAt(Location, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason)}
++ *
++ * @param data serialized entity
++ * @param world world entity belongs in
++ * @return deserialized entity
++ */
++ org.bukkit.entity.Entity deserializeEntity(byte[] data, org.bukkit.World world);
++ // Purpur end
+ }
diff --git a/src/main/java/org/bukkit/WorldBorder.java b/src/main/java/org/bukkit/WorldBorder.java
index afb7b136b461202026290624836446cff9f9e45d..087579fdff09237409c9f80446e7a15a78f9040c 100644
--- a/src/main/java/org/bukkit/WorldBorder.java
diff --git a/patches/api/0038-Add-unsafe-Entity-serialization-API.patch b/patches/api/0038-Add-unsafe-Entity-serialization-API.patch
index b52163d44..90919d39e 100644
--- a/patches/api/0038-Add-unsafe-Entity-serialization-API.patch
+++ b/patches/api/0038-Add-unsafe-Entity-serialization-API.patch
@@ -16,39 +16,6 @@ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see
-+ * The entity is not automatically spawned in the world. You will have to spawn
-+ * the entity yourself with {@link org.bukkit.entity.Entity#spawnAt(Location)} or
-+ * {@link org.bukkit.entity.Entity#spawnAt(Location, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason)}
-+ *
-+ * @param data serialized entity
-+ * @param world world entity belongs in
-+ * @return deserialized entity
-+ */
-+ org.bukkit.entity.Entity deserializeEntity(byte[] data, org.bukkit.World world);
-+ // Purpur end
- }
diff --git a/src/main/java/org/bukkit/entity/Entity.java b/src/main/java/org/bukkit/entity/Entity.java
index b47e31d2b9b41b39b46892fe10bf36d82c5d8e1b..7fa5242bd44c9b19648d79fa8fecbb7ee125288e 100644
--- a/src/main/java/org/bukkit/entity/Entity.java
diff --git a/patches/server/0003-Rebrand.patch b/patches/server/0003-Rebrand.patch
index 7725e9e4c..9c23a2a0b 100644
--- a/patches/server/0003-Rebrand.patch
+++ b/patches/server/0003-Rebrand.patch
@@ -104,6 +104,25 @@ index dd0daf3138a38d0c8a399e6cb54bbc58af47f710..53d847b863a957639ff2e58280861316
}
public CrashReport b(CrashReport crashreport) {
+diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+index 858bd62d2a17c15ee573c5cd607a876d3a99c2b1..3e63ea5ae2d31a502fa639806a926cd1ab8b6796 100644
+--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
++++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+@@ -260,11 +260,12 @@ public class DedicatedServer extends MinecraftServer implements IMinecraftServer
+ DedicatedServer.LOGGER.warn("**** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!");
+ DedicatedServer.LOGGER.warn("The server will make no attempt to authenticate usernames. Beware.");
+ // Spigot start
+- if (org.spigotmc.SpigotConfig.bungee) {
+- DedicatedServer.LOGGER.warn("Whilst this makes it possible to use BungeeCord, unless access to your server is properly restricted, it also opens up the ability for hackers to connect with any username they choose.");
++ if (com.destroystokyo.paper.PaperConfig.isProxyOnlineMode()) { // Purpur
++ DedicatedServer.LOGGER.warn("Whilst this makes it possible to use BungeeCord or Velocity, unless access to your server is properly restricted, it also opens up the ability for hackers to connect with any username they choose."); // Purpur
+ DedicatedServer.LOGGER.warn("Please see http://www.spigotmc.org/wiki/firewall-guide/ for further information.");
+ } else {
+ DedicatedServer.LOGGER.warn("While this makes the game possible to play without internet access, it also opens up the ability for hackers to connect with any username they choose.");
++ DedicatedServer.LOGGER.warn("You will not be offered any support as long as the server allows offline-mode players to join."); // Purpur
+ }
+ // Spigot end
+ DedicatedServer.LOGGER.warn("To change this, set \"online-mode\" to \"true\" in the server.properties file.");
diff --git a/src/main/java/net/pl3x/purpur/PurpurVersionFetcher.java b/src/main/java/net/pl3x/purpur/PurpurVersionFetcher.java
new file mode 100644
index 0000000000000000000000000000000000000000..cabfcebf9f944f7a2a2a1cffc7401435803a8741
diff --git a/patches/server/0004-Purpur-config-files.patch b/patches/server/0004-Purpur-config-files.patch
index f075e08b3..2ea645f7c 100644
--- a/patches/server/0004-Purpur-config-files.patch
+++ b/patches/server/0004-Purpur-config-files.patch
@@ -45,7 +45,7 @@ index 14ac28d4d6b1ab0f0a70dfefc589f7723a1d2e1a..4eb122cfd31902df9789d2e8ff261520
config.save(CONFIG_FILE);
} catch (IOException ex) {
diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
-index 858bd62d2a17c15ee573c5cd607a876d3a99c2b1..a76219e59c24862b9c1e09e4a2a29cf2a6260514 100644
+index 3e63ea5ae2d31a502fa639806a926cd1ab8b6796..cbccb889167f8e235f417e224bbf5f025a6304f5 100644
--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
@@ -212,6 +212,15 @@ public class DedicatedServer extends MinecraftServer implements IMinecraftServer
diff --git a/patches/server/0153-Implement-TPSBar.patch b/patches/server/0153-Implement-TPSBar.patch
index f8ef7ff85..851417955 100644
--- a/patches/server/0153-Implement-TPSBar.patch
+++ b/patches/server/0153-Implement-TPSBar.patch
@@ -29,10 +29,10 @@ index e3c3b2eb03ad132a91140cb459fd8f378154ee2e..176fc4c8b7c5ef45b29cb8aaa1b1ff16
this.isRestarting = isRestarting;
this.hasLoggedStop = true; // Paper
diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
-index a76219e59c24862b9c1e09e4a2a29cf2a6260514..4f7fed0418df17b80cb41e16bb1978c5cb284810 100644
+index cbccb889167f8e235f417e224bbf5f025a6304f5..df6eaa94f2928242dbd69a918d0b0b919bd3436b 100644
--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
-@@ -324,6 +324,8 @@ public class DedicatedServer extends MinecraftServer implements IMinecraftServer
+@@ -325,6 +325,8 @@ public class DedicatedServer extends MinecraftServer implements IMinecraftServer
MinecraftServerBeans.a((MinecraftServer) this);
}
diff --git a/patches/server/0208-Implement-Mob-Blindness.patch b/patches/server/0208-Implement-Mob-Blindness.patch
new file mode 100644
index 000000000..c5c186649
--- /dev/null
+++ b/patches/server/0208-Implement-Mob-Blindness.patch
@@ -0,0 +1,46 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Encode42