PaperMC/paper-server/patches/sources/net/minecraft/world/item
Owen1212055 d300c94ec2 Properly resend entities
This resolves some issues which caused entities to not be resent correctly.
Entities that are interacted with need to be resent to the client, so we resend all the entity
data to the player whilst making sure not to clear dirty entries from the tracker. This makes
sure that values will be correctly updated to other players.

This also adds utilities to aid in further preventing entity desyncs.

This also also fixes the bug causing cancelling PlayerInteractEvent to cause items to continue
to be used despite being cancelled on the server.

For example, items being consumed but never finishing, shields being put up, etc.
The underlying issue of this is that the client modifies their synced data values,
and so we have to (forcibly) resend them in order for the client to reset their using item state.

See: https://github.com/PaperMC/Paper/pull/1896

== AT ==
public net.minecraft.server.level.ChunkMap$TrackedEntity serverEntity
2022-12-07 17:25:19 -05:00
..
alchemy Custom Potion Mixes 2021-10-07 14:34:55 -07:00
component Properly resend entities 2022-12-07 17:25:19 -05:00
consume_effects Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
crafting Improve performance of RecipeMap#removeRecipe 2024-10-31 20:36:41 -07:00
enchantment Add EntityDamageItemEvent 2020-12-22 13:52:48 -08:00
trading Add PlayerTradeEvent and PlayerPurchaseEvent 2020-07-02 16:12:10 -07:00
ArmorStandItem.java.patch Fix slot desync 2023-08-23 13:22:09 -07:00
AxeItem.java.patch Fire EntityChangeBlockEvent in more places 2021-08-09 20:45:46 -07:00
BlockItem.java.patch Fix slot desync 2023-08-23 13:22:09 -07:00
BoatItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
BoneMealItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
BucketItem.java.patch Dont resend blocks on interactions 2023-06-27 21:09:11 -04:00
CrossbowItem.java.patch Add EntityLoadCrossbowEvent 2020-10-07 12:04:01 -04:00
DebugStickItem.java.patch Add creative mode NBT permissions 2019-02-25 19:26:56 +11:00
DyeItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
EggItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
EndCrystalItem.java.patch Do crystal-portal proximity check before entity lookup 2023-08-15 21:04:55 +02:00
EnderEyeItem.java.patch Fire EntityChangeBlockEvent in more places 2021-08-09 20:45:46 -07:00
EnderpearlItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
ExperienceBottleItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
FireChargeItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
FireworkRocketItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
FishingRodItem.java.patch Add hand to fish event for all player interactions 2023-07-03 01:55:32 +02:00
FlintAndSteelItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
HangingEntityItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
HoneycombItem.java.patch Fire EntityChangeBlockEvent in more places 2021-08-09 20:45:46 -07:00
ItemCooldowns.java.patch Add PlayerItemCooldownEvent 2020-08-25 13:48:33 +02:00
ItemStack.java.patch Fix cancelling BlockPlaceEvent calling onRemove 2024-05-23 11:02:20 +02:00
ItemUtils.java.patch Add various missing EntityDropItemEvent calls 2021-07-20 21:35:47 -07:00
LeadItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
LingeringPotionItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
MapItem.java.patch Use seed based lookup for Treasure Maps - Fixes lag from carto/sunken maps 2020-06-07 19:25:13 -04:00
MinecartItem.java.patch Fix slot desync 2023-08-23 13:22:09 -07:00
NameTagItem.java.patch Add PlayerNameEntityEvent 2020-07-05 00:33:54 -07:00
PotionItem.java.patch Fire EntityChangeBlockEvent in more places 2021-08-09 20:45:46 -07:00
ProjectileWeaponItem.java.patch Add EntityLoadCrossbowEvent 2020-10-07 12:04:01 -04:00
ServerItemCooldowns.java.patch Add PlayerItemCooldownEvent 2020-08-25 13:48:33 +02:00
ShovelItem.java.patch Fire EntityChangeBlockEvent in more places 2021-08-09 20:45:46 -07:00
SignItem.java.patch Remap CraftBukkit to Mojang+Yarn Mappings 2024-12-11 22:26:55 +01:00
SnowballItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
SpawnEggItem.java.patch Allow disabling mob spawner spawn egg transformation 2020-10-09 20:30:12 -04:00
SplashPotionItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
StandingAndWallBlockItem.java.patch Expose hand in BlockCanBuildEvent 2023-08-21 14:13:42 +01:00
ThrowablePotionItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
TridentItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
WindChargeItem.java.patch PlayerLaunchProjectileEvent 2018-07-21 03:11:03 -05:00
WrittenBookItem.java.patch Disable component selector resolving in books by default 2022-06-02 20:35:58 +02:00