mirror of
https://github.com/AtlasMediaGroup/Scissors.git
synced 2024-11-30 08:06:01 +00:00
Update Paper
This commit is contained in:
parent
24df678717
commit
d61ec8e005
@ -2,7 +2,7 @@ group=me.totalfreedom.scissors
|
|||||||
version=1.19.3-R0.1-SNAPSHOT
|
version=1.19.3-R0.1-SNAPSHOT
|
||||||
|
|
||||||
mcVersion=1.19.3
|
mcVersion=1.19.3
|
||||||
paperRef=f26e9ccdd0d08d765f96a32d1d124f0f6b9bb3a2
|
paperRef=52718dba10c028a57a7a00993ed490a503ca9ecd
|
||||||
|
|
||||||
org.gradle.caching=true
|
org.gradle.caching=true
|
||||||
org.gradle.parallel=true
|
org.gradle.parallel=true
|
||||||
|
@ -5,20 +5,20 @@ 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
|
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java
|
||||||
index 2771dd62c04c8da890724fe03f836fdeba440c55..023916ec8dc85b30e521874bcc2104e89832282a 100644
|
index deed77a3d44bc55681483d7f47f148b5220135f2..053cb78362006a94ee0d82b9b1f665c5f86a4458 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java
|
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaSkull.java
|
||||||
@@ -9,6 +9,9 @@ import java.util.UUID;
|
@@ -11,6 +11,9 @@ import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.nbt.CompoundTag;
|
|
||||||
import net.minecraft.nbt.NbtUtils;
|
import net.minecraft.nbt.NbtUtils;
|
||||||
|
import net.minecraft.resources.ResourceLocation;
|
||||||
import net.minecraft.world.level.block.entity.SkullBlockEntity;
|
import net.minecraft.world.level.block.entity.SkullBlockEntity;
|
||||||
+// Scissors start
|
+// Scissors start
|
||||||
+import org.apache.commons.lang3.StringUtils;
|
+import org.apache.commons.lang3.StringUtils;
|
||||||
+// Scissors end
|
+// Scissors end
|
||||||
import org.bukkit.Bukkit;
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
import org.bukkit.OfflinePlayer;
|
import org.bukkit.NamespacedKey;
|
||||||
@@ -63,7 +66,9 @@ class CraftMetaSkull extends CraftMetaItem implements SkullMeta {
|
@@ -73,7 +76,9 @@ class CraftMetaSkull extends CraftMetaItem implements SkullMeta {
|
||||||
|
|
||||||
if (tag.contains(SKULL_OWNER.NBT, CraftMagicNumbers.NBT.TAG_COMPOUND)) {
|
if (tag.contains(SKULL_OWNER.NBT, CraftMagicNumbers.NBT.TAG_COMPOUND)) {
|
||||||
this.setProfile(NbtUtils.readGameProfile(tag.getCompound(SKULL_OWNER.NBT)));
|
this.setProfile(NbtUtils.readGameProfile(tag.getCompound(SKULL_OWNER.NBT)));
|
||||||
@ -28,4 +28,4 @@ index 2771dd62c04c8da890724fe03f836fdeba440c55..023916ec8dc85b30e521874bcc2104e8
|
|||||||
+ // Scissors end
|
+ // Scissors end
|
||||||
this.setProfile(new GameProfile(null, tag.getString(SKULL_OWNER.NBT)));
|
this.setProfile(new GameProfile(null, tag.getString(SKULL_OWNER.NBT)));
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
@ -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
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 08cb3db28f13c352a162009deeb28ee637e98d2a..da47e84dffd3518b84eeeb80ab4f17073fed9a9c 100644
|
index 50d8d16b1856c0c875ccabbcfc240379a7669559..ad014bcb602ae041494948cfef939128bd86419b 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
@@ -1922,6 +1922,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
@@ -1922,6 +1922,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||||
@ -28,7 +28,7 @@ index 08cb3db28f13c352a162009deeb28ee637e98d2a..da47e84dffd3518b84eeeb80ab4f1707
|
|||||||
@Override
|
@Override
|
||||||
public void handleUseItemOn(ServerboundUseItemOnPacket packet) {
|
public void handleUseItemOn(ServerboundUseItemOnPacket packet) {
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
@@ -3306,17 +3318,24 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
@@ -3308,17 +3320,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
|
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);
|
BlockPos blockposition = BlockEntity.getPosFromTag(nbttagcompound);
|
||||||
|
|
||||||
|
@ -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
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
index 028d41c22ec5d67434dc42926cd875fe576768ea..5086fc9f81e9ae894b6fa64819e77267812cae17 100644
|
index a29a44d5ae3b6a0cd6fc012c931271502f9c55c4..15b68a89f928d661b215a4463689540abf150316 100644
|
||||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||||
+++ b/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;
|
@@ -29,6 +29,8 @@ import java.util.function.UnaryOperator;
|
||||||
@ -17,7 +17,7 @@ index 028d41c22ec5d67434dc42926cd875fe576768ea..5086fc9f81e9ae894b6fa64819e77267
|
|||||||
import net.minecraft.ChatFormatting;
|
import net.minecraft.ChatFormatting;
|
||||||
import net.minecraft.CrashReport;
|
import net.minecraft.CrashReport;
|
||||||
import net.minecraft.CrashReportCategory;
|
import net.minecraft.CrashReportCategory;
|
||||||
@@ -2948,6 +2950,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
@@ -2950,6 +2952,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||||
public void handleContainerClick(ServerboundContainerClickPacket packet) {
|
public void handleContainerClick(ServerboundContainerClickPacket packet) {
|
||||||
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel());
|
||||||
if (this.player.isImmobile()) return; // CraftBukkit
|
if (this.player.isImmobile()) return; // CraftBukkit
|
||||||
@ -25,7 +25,7 @@ index 028d41c22ec5d67434dc42926cd875fe576768ea..5086fc9f81e9ae894b6fa64819e77267
|
|||||||
this.player.resetLastActionTime();
|
this.player.resetLastActionTime();
|
||||||
if (this.player.containerMenu.containerId == packet.getContainerId() && this.player.containerMenu.stillValid(this.player)) { // CraftBukkit
|
if (this.player.containerMenu.containerId == packet.getContainerId() && this.player.containerMenu.stillValid(this.player)) { // CraftBukkit
|
||||||
boolean cancelled = this.player.isSpectator(); // CraftBukkit - see below if
|
boolean cancelled = this.player.isSpectator(); // CraftBukkit - see below if
|
||||||
@@ -2969,6 +2972,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
@@ -2971,6 +2974,18 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user