20 lines
1.1 KiB
Diff
20 lines
1.1 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Tom <cryptite@gmail.com>
|
|
Date: Thu, 23 Sep 2021 08:56:42 -0500
|
|
Subject: [PATCH] Don't send equipment updates if only durability changed
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
|
index 1018f4640bab5876c5e0afb5b88f71437fb79662..5c9630008533276f393a276f1247e1f5fae75326 100644
|
|
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
|
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
|
@@ -2995,7 +2995,7 @@ public abstract class LivingEntity extends Entity {
|
|
|
|
ItemStack itemstack1 = this.getItemBySlot(enumitemslot);
|
|
|
|
- if (!ItemStack.matches(itemstack1, itemstack)) {
|
|
+ if (!ItemStack.isSameIgnoreDurability(itemstack1, itemstack)) {
|
|
// Paper start - PlayerArmorChangeEvent
|
|
if (this instanceof ServerPlayer && enumitemslot.getType() == EquipmentSlot.Type.ARMOR) {
|
|
final org.bukkit.inventory.ItemStack oldItem = CraftItemStack.asBukkitCopy(itemstack);
|