Skip to content

Commit

Permalink
Fix patches
Browse files Browse the repository at this point in the history
  • Loading branch information
Dreeam-qwq committed Jul 22, 2024
1 parent c2f66ea commit 83c2468
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 22 deletions.
19 changes: 0 additions & 19 deletions patches/server/0093-Fix-MC-183518.patch
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,3 @@ index d0dbe7e3c7c9c2727d5de456808765b2666108e4..95f26facf942e0ce460b2027f39c65dd
}

protected void doRunTask(R task) {
diff --git a/src/main/java/net/minecraft/util/thread/BlockableEventLoop.java.rej b/src/main/java/net/minecraft/util/thread/BlockableEventLoop.java.rej
new file mode 100644
index 0000000000000000000000000000000000000000..3a83c5369a6acc0663a66409052c9dfcf36a70f7
--- /dev/null
+++ b/src/main/java/net/minecraft/util/thread/BlockableEventLoop.java.rej
@@ -0,0 +1,13 @@
+diff a/src/main/java/net/minecraft/util/thread/BlockableEventLoop.java b/src/main/java/net/minecraft/util/thread/BlockableEventLoop.java (rejected hunks)
+@@ -142,8 +142,9 @@ public abstract class BlockableEventLoop<R extends Runnable> implements Profiler
+ }
+
+ public void waitForTasks() {
+- Thread.yield();
+- LockSupport.parkNanos("waiting for tasks", 100000L);
++ // Leaf start - Fix MC-183518
++ LockSupport.parkNanos("waiting for tasks", 2000000L);
++ // Leaf end
+ }
+
+ protected void doRunTask(R task) {
8 changes: 5 additions & 3 deletions patches/server/0095-Fix-MC-266334.patch
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,23 @@ MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Related MC issue: https://bugs.mojang.com/browse/MC-266334

Co-Authored-By: Kobe ⑧ <102713261+HaHaWTH@users.noreply.github.com>

diff --git a/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java b/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java
index 8e71d4d3874ff154eae423a8fb8f15ae08143f4d..e017341d273c7803cc1a78b93a971c41a299ce27 100644
index 8e71d4d3874ff154eae423a8fb8f15ae08143f4d..53d17352b2a6a9806c92ddf321556fd41872947d 100644
--- a/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java
+++ b/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java
@@ -516,6 +516,12 @@ public class ArmorStand extends LivingEntity {
boolean flag = source.is(DamageTypeTags.CAN_BREAK_ARMOR_STAND);
boolean flag1 = source.is(DamageTypeTags.ALWAYS_KILLS_ARMOR_STANDS);

+ // Leaf start
+ // Leaf start - Fix MC-266334
+ if (!flag && source.getDirectEntity() instanceof net.minecraft.world.entity.projectile.ShulkerBullet){
+ return false;
+ }
+ // Leaf end
+ // Leaf end - Fix MC-266334
+
if (!flag && !flag1) {
return false;
Expand Down

0 comments on commit 83c2468

Please sign in to comment.