aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0294-offset-item-frame-ticking.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/server/0294-offset-item-frame-ticking.patch')
-rw-r--r--patches/server/0294-offset-item-frame-ticking.patch19
1 files changed, 19 insertions, 0 deletions
diff --git a/patches/server/0294-offset-item-frame-ticking.patch b/patches/server/0294-offset-item-frame-ticking.patch
new file mode 100644
index 0000000000..3db1ffe305
--- /dev/null
+++ b/patches/server/0294-offset-item-frame-ticking.patch
@@ -0,0 +1,19 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: kickash32 <[email protected]>
+Date: Tue, 30 Jul 2019 03:17:16 +0500
+Subject: [PATCH] offset item frame ticking
+
+
+diff --git a/src/main/java/net/minecraft/world/entity/decoration/BlockAttachedEntity.java b/src/main/java/net/minecraft/world/entity/decoration/BlockAttachedEntity.java
+index e4eece7bbd14514ec60da26a8744672baa8956f9..7bc612890f941177da11da0ce047d5a74d8ebb33 100644
+--- a/src/main/java/net/minecraft/world/entity/decoration/BlockAttachedEntity.java
++++ b/src/main/java/net/minecraft/world/entity/decoration/BlockAttachedEntity.java
+@@ -26,7 +26,7 @@ import org.bukkit.event.hanging.HangingBreakEvent;
+ public abstract class BlockAttachedEntity extends Entity {
+
+ private static final Logger LOGGER = LogUtils.getLogger();
+- private int checkInterval;
++ private int checkInterval; { this.checkInterval = this.getId() % this.level().spigotConfig.hangingTickFrequency; } // Paper - Perf: offset item frame ticking
+ protected BlockPos pos;
+
+ protected BlockAttachedEntity(EntityType<? extends BlockAttachedEntity> type, Level world) {