diff --git a/gradle.properties b/gradle.properties index 15dff40..2d5c6dc 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,7 +2,7 @@ group=me.totalfreedom.scissors version=1.19.2-R0.1-SNAPSHOT mcVersion=1.19.2 -paperRef=36a5f150c550d03ea24cbc5b1bcc1993a44cb2eb +paperRef=ef0e5a642d33ac62f070c45a61cb42647b2744cd org.gradle.caching=true org.gradle.parallel=true diff --git a/patches/server/0005-Fixes-the-Blank-SkullOwner-exploit.patch b/patches/server/0005-Fixes-the-Blank-SkullOwner-exploit.patch index 5e28c6d..e6a1f74 100644 --- a/patches/server/0005-Fixes-the-Blank-SkullOwner-exploit.patch +++ b/patches/server/0005-Fixes-the-Blank-SkullOwner-exploit.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Fixes the Blank SkullOwner exploit diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java -index 292ae4a68093b7d939a755e1062cee57da186ab1..4ae030580131252b849fd356717d0323c29cf773 100644 +index 92b56f16b4d8107ccf206be6b81a98dc58986c10..e6d0cd263aa5769805426825df7e49724aa05809 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java -@@ -7,6 +7,9 @@ import java.util.UUID; +@@ -9,6 +9,9 @@ import java.util.UUID; import net.minecraft.nbt.CompoundTag; import net.minecraft.nbt.NbtUtils; import net.minecraft.world.level.block.entity.SkullBlockEntity; @@ -18,7 +18,7 @@ index 292ae4a68093b7d939a755e1062cee57da186ab1..4ae030580131252b849fd356717d0323 import org.bukkit.Bukkit; import org.bukkit.Material; import org.bukkit.OfflinePlayer; -@@ -45,7 +48,9 @@ class CraftMetaSkull extends CraftMetaItem implements SkullMeta { +@@ -61,7 +64,9 @@ class CraftMetaSkull extends CraftMetaItem implements SkullMeta { if (tag.contains(SKULL_OWNER.NBT, CraftMagicNumbers.NBT.TAG_COMPOUND)) { this.setProfile(NbtUtils.readGameProfile(tag.getCompound(SKULL_OWNER.NBT))); diff --git a/patches/server/0006-Ignore-null-air-bundle-items-in-CraftMetaBundle.patch b/patches/server/0006-Ignore-null-air-bundle-items-in-CraftMetaBundle.patch index 5184fc3..03ce1f4 100644 --- a/patches/server/0006-Ignore-null-air-bundle-items-in-CraftMetaBundle.patch +++ b/patches/server/0006-Ignore-null-air-bundle-items-in-CraftMetaBundle.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Ignore null/air bundle items in CraftMetaBundle diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBundle.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBundle.java -index 8fd1e392258eba9dbe2194c024ad7e0ca3e43cf8..28be42594857f2d8320a035c1f8b95cdc300ddd5 100644 +index e14318383403f12e26dd7801a9dbdea854df185f..bd3f516a9e9a47c9f00b681b0b457d308bfd1710 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBundle.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBundle.java -@@ -49,7 +49,11 @@ public class CraftMetaBundle extends CraftMetaItem implements BundleMeta { +@@ -47,7 +47,11 @@ public class CraftMetaBundle extends CraftMetaItem implements BundleMeta { for (int i = 0; i < list.size(); i++) { CompoundTag nbttagcompound1 = list.getCompound(i); diff --git a/patches/server/0010-Fixes-Knowledge-Books-causing-log-spam-when-invalid-.patch b/patches/server/0010-Fixes-Knowledge-Books-causing-log-spam-when-invalid-.patch index 626498f..03da083 100644 --- a/patches/server/0010-Fixes-Knowledge-Books-causing-log-spam-when-invalid-.patch +++ b/patches/server/0010-Fixes-Knowledge-Books-causing-log-spam-when-invalid-.patch @@ -31,10 +31,10 @@ index b79f4ce38a42e4dba8ebdfc97dadc531b7245c7a..9c49be7c53a1f2a8c203341b8ded9cd2 } } diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaKnowledgeBook.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaKnowledgeBook.java -index e816e505cd292d6c5138dff0aeae0e9592c09de0..0f6438dfe0a6620eb87233b9eefbe2340dfc347b 100644 +index 50fdb086ffec84edc5138737c95f08ed4757a6f3..bb0f673a619810850df0d78bb4abd9d7c49ecbe4 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaKnowledgeBook.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaKnowledgeBook.java -@@ -42,7 +42,12 @@ public class CraftMetaKnowledgeBook extends CraftMetaItem implements KnowledgeBo +@@ -41,7 +41,12 @@ public class CraftMetaKnowledgeBook extends CraftMetaItem implements KnowledgeBo for (int i = 0; i < pages.size(); i++) { String recipe = pages.getString(i); diff --git a/patches/server/0012-Even-more-ResourceLocation-validation-and-log-spam-f.patch b/patches/server/0012-Even-more-ResourceLocation-validation-and-log-spam-f.patch index 002c0c9..c84834f 100644 --- a/patches/server/0012-Even-more-ResourceLocation-validation-and-log-spam-f.patch +++ b/patches/server/0012-Even-more-ResourceLocation-validation-and-log-spam-f.patch @@ -60,10 +60,10 @@ index 0dd0ce9a9b3253e87eda12354249ec2fd2a33cf2..b6920f9432ca1736afbe775186fbbcf1 @Override diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -index d775e19402188e35f79affb4ed636b6533f90ab5..29f5ab80ffbc421da911046678427755c6156894 100644 +index 9187f92f1708478dfffcd9de65898fd409a1b0c1..091b9ef3a247132cdd55addf413918ed1901a854 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java -@@ -63,8 +63,18 @@ public abstract class CraftMob extends CraftLivingEntity implements Mob { +@@ -72,8 +72,18 @@ public abstract class CraftMob extends CraftLivingEntity implements Mob { @Override public LootTable getLootTable() { diff --git a/patches/server/0014-Even-more-resource-location-validation.patch b/patches/server/0014-Even-more-resource-location-validation.patch index 077bc41..8c7d770 100644 --- a/patches/server/0014-Even-more-resource-location-validation.patch +++ b/patches/server/0014-Even-more-resource-location-validation.patch @@ -40,10 +40,10 @@ index ac0f0a4da4282c13f6e1f37710cb615d66b8ef2c..e789bcb0c426651a48fb3c78e885c6e3 @Nullable diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java -index 3646b969fa51b9683ab4137e530c3a6f6fc6c465..286e9a8d3673be3a7fef2af6402e025d3058f6e7 100644 +index 557e90e54439ce0430075403392b5052d5181feb..2ec4f71fd02bcca5a810cee5d8c7d293599998f7 100644 --- a/src/main/java/net/minecraft/world/entity/Mob.java +++ b/src/main/java/net/minecraft/world/entity/Mob.java -@@ -579,7 +579,7 @@ public abstract class Mob extends LivingEntity { +@@ -585,7 +585,7 @@ public abstract class Mob extends LivingEntity { this.setLeftHanded(nbt.getBoolean("LeftHanded")); if (nbt.contains("DeathLootTable", 8)) { diff --git a/patches/server/0015-Change-version-fetcher-to-AMG.patch b/patches/server/0015-Change-version-fetcher-to-AMG.patch index 243731f..a2bec42 100644 --- a/patches/server/0015-Change-version-fetcher-to-AMG.patch +++ b/patches/server/0015-Change-version-fetcher-to-AMG.patch @@ -76,10 +76,10 @@ index bf42969859545a8a520923ef1836ffa4a5cc24a0..31d0624fcaf1998383eebde7fbd3a103 switch (distance) { case -1: diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 56a784e943cb5d8b15b41e3e66545ebf166c221c..1503b897794b3cfaf22ab90423d7d4c7c789d1c6 100644 +index f30621be24c6c3a4f173436fce1ad1c13507c84f..604662cd3ac1e0a9b956d1a3078afa9e16beb473 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java -@@ -276,7 +276,7 @@ public class Main { +@@ -278,7 +278,7 @@ public class Main { if (buildDate.before(deadline.getTime())) { // Paper start - This is some stupid bullshit System.err.println("*** Warning, you've not updated in a while! ***"); diff --git a/patches/server/0023-Validate-coordinates-before-attempting-to-get-block-.patch b/patches/server/0023-Validate-coordinates-before-attempting-to-get-block-.patch index c330467..ac42908 100644 --- a/patches/server/0023-Validate-coordinates-before-attempting-to-get-block-.patch +++ b/patches/server/0023-Validate-coordinates-before-attempting-to-get-block-.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Validate coordinates before attempting to get block entities diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 325def3149693f64b2b21e0e655b5b3e888fd9a0..4fc877f19e6b127914269a7073fa2725b9f322fe 100644 +index 9eb921fec32afa360f3a402e978411fcf3ec618c..fde54ce82ed015cfb6d0767b70ff073bc02a0ba5 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -1933,6 +1933,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -28,7 +28,7 @@ index 325def3149693f64b2b21e0e655b5b3e888fd9a0..4fc877f19e6b127914269a7073fa2725 @Override public void handleUseItemOn(ServerboundUseItemOnPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); -@@ -3450,17 +3462,24 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3448,17 +3460,24 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic if (!itemstack.isEmpty() && nbttagcompound != null && nbttagcompound.contains("x") && nbttagcompound.contains("y") && nbttagcompound.contains("z") && this.player.getBukkitEntity().hasPermission("minecraft.nbt.copy")) { // Spigot BlockPos blockposition = BlockEntity.getPosFromTag(nbttagcompound); diff --git a/patches/server/0028-Better-handling-of-invalid-JSON-components.patch b/patches/server/0028-Better-handling-of-invalid-JSON-components.patch index b7f270d..f8742d1 100644 --- a/patches/server/0028-Better-handling-of-invalid-JSON-components.patch +++ b/patches/server/0028-Better-handling-of-invalid-JSON-components.patch @@ -110,10 +110,10 @@ index 97a2657bc98d41c3c1e376b266d2c85f685acc88..7b6476455e095eed15c92797ce3a3e11 } }).reduce((accumulator, current) -> { diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index f925a8d550ecbf2044a37bfe58b30d6578c5f6af..ec379f87fafd7c7ffb5139a7c192d562e3f178ad 100644 +index 0b3765ff8a25215bc42298b591eeffe022107079..e572c22e809a9580132fa9666c38665863d9777b 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2301,12 +2301,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { +@@ -2315,12 +2315,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { this.setRot(this.getYRot(), this.getXRot()); if (nbt.contains("CustomName", 8)) { String s = nbt.getString("CustomName"); diff --git a/patches/server/0032-Add-spectator-teleport-event.patch b/patches/server/0032-Add-spectator-teleport-event.patch index 39384b5..2d601be 100644 --- a/patches/server/0032-Add-spectator-teleport-event.patch +++ b/patches/server/0032-Add-spectator-teleport-event.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add spectator teleport event diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index 4fc877f19e6b127914269a7073fa2725b9f322fe..ca36e4f3cdb257a7e8de93d8c2b82140eaaad56e 100644 +index fde54ce82ed015cfb6d0767b70ff073bc02a0ba5..8ad540867e1f7942170f24faa4f42a84c0c63690 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -1,5 +1,6 @@ @@ -15,7 +15,7 @@ index 4fc877f19e6b127914269a7073fa2725b9f322fe..ca36e4f3cdb257a7e8de93d8c2b82140 import com.google.common.collect.Lists; import com.google.common.primitives.Floats; import com.mojang.brigadier.ParseResults; -@@ -2075,6 +2076,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -2076,6 +2077,14 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic Entity entity = packet.getEntity(worldserver); if (entity != null) { diff --git a/patches/server/0033-Prevent-invalid-container-events.patch b/patches/server/0033-Prevent-invalid-container-events.patch index 3706146..6bcc5d1 100644 --- a/patches/server/0033-Prevent-invalid-container-events.patch +++ b/patches/server/0033-Prevent-invalid-container-events.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Prevent invalid container events diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java -index ca36e4f3cdb257a7e8de93d8c2b82140eaaad56e..2fdaa6ff9782684b8840d7f76fe08680e53de635 100644 +index 8ad540867e1f7942170f24faa4f42a84c0c63690..a7eb51e6b695cdb9dc20698b774da33ec4035544 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -29,6 +29,8 @@ import java.util.function.UnaryOperator; @@ -17,7 +17,7 @@ index ca36e4f3cdb257a7e8de93d8c2b82140eaaad56e..2fdaa6ff9782684b8840d7f76fe08680 import net.minecraft.ChatFormatting; import net.minecraft.CrashReport; import net.minecraft.CrashReportCategory; -@@ -3097,6 +3099,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3095,6 +3097,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic public void handleContainerClick(ServerboundContainerClickPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); if (this.player.isImmobile()) return; // CraftBukkit @@ -25,7 +25,7 @@ index ca36e4f3cdb257a7e8de93d8c2b82140eaaad56e..2fdaa6ff9782684b8840d7f76fe08680 this.player.resetLastActionTime(); if (this.player.containerMenu.containerId == packet.getContainerId() && this.player.containerMenu.stillValid(this.player)) { // CraftBukkit boolean cancelled = this.player.isSpectator(); // CraftBukkit - see below if -@@ -3118,6 +3121,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic +@@ -3116,6 +3119,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic return; } diff --git a/patches/server/0035-Add-Scissors-configuration-file-command.patch b/patches/server/0035-Add-Scissors-configuration-file-command.patch index 05ad402..af69bba 100644 --- a/patches/server/0035-Add-Scissors-configuration-file-command.patch +++ b/patches/server/0035-Add-Scissors-configuration-file-command.patch @@ -388,10 +388,10 @@ index 0000000000000000000000000000000000000000..e08f502fc7165f9f466217910210edb5 +} + diff --git a/src/main/java/net/minecraft/server/Main.java b/src/main/java/net/minecraft/server/Main.java -index 0a843e0afbcb1af8e2641515eb244b791b819b8c..f5c0375b171516c0ae734644b4449db8900143df 100644 +index 5962f7a2b185d7d54a0f9e341a4fdf6e6f1c1ec5..41cc0fe90e10ee53c4fcd49265be02978ab97099 100644 --- a/src/main/java/net/minecraft/server/Main.java +++ b/src/main/java/net/minecraft/server/Main.java -@@ -114,6 +114,7 @@ public class Main { +@@ -118,6 +118,7 @@ public class Main { // Paper start - load config files for access below if needed org.bukkit.configuration.file.YamlConfiguration bukkitConfiguration = io.papermc.paper.configuration.PaperConfigurations.loadLegacyConfigFile((File) optionset.valueOf("bukkit-settings")); org.bukkit.configuration.file.YamlConfiguration spigotConfiguration = io.papermc.paper.configuration.PaperConfigurations.loadLegacyConfigFile((File) optionset.valueOf("spigot-settings")); @@ -421,7 +421,7 @@ index bdd6560fe85950b0a857a949cb38c044da44ca6b..c4894b7022ee5e63135c9463c8faf61e this.setFlightAllowed(dedicatedserverproperties.allowFlight); this.setMotd(dedicatedserverproperties.motd); diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index bf349ab7249c617172522aeaa5d437a496e9acfe..30b3755955a6ee1b6e8f150918ebd8348e1000dd 100644 +index 4017fbe7761ba7eaf4e9b3c047e1ca79042aab8c..bc459fd74701e0aad7a5a1491ca349cba68efd4e 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -960,6 +960,8 @@ public final class CraftServer implements Server { @@ -455,10 +455,10 @@ index bf349ab7249c617172522aeaa5d437a496e9acfe..30b3755955a6ee1b6e8f150918ebd834 public void restart() { org.spigotmc.RestartCommand.restart(); diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java -index 1503b897794b3cfaf22ab90423d7d4c7c789d1c6..1da8e9570b7f52609cd25b6b6dab8748afc3e457 100644 +index 604662cd3ac1e0a9b956d1a3078afa9e16beb473..96ee05b115d88a60e7953e3f0f7c1b8095ebf360 100644 --- a/src/main/java/org/bukkit/craftbukkit/Main.java +++ b/src/main/java/org/bukkit/craftbukkit/Main.java -@@ -171,6 +171,22 @@ public class Main { +@@ -173,6 +173,22 @@ public class Main { .defaultsTo("Unknown Server") .describedAs("Name"); // Paper end