@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/world/item/ItemHanging.java
|
||||
+++ b/net/minecraft/world/item/ItemHanging.java
|
||||
@@ -24,6 +24,11 @@
|
||||
@@ -25,6 +25,11 @@
|
||||
import net.minecraft.world.level.World;
|
||||
import net.minecraft.world.level.gameevent.GameEvent;
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
public class ItemHanging extends Item {
|
||||
|
||||
private static final IChatBaseComponent TOOLTIP_RANDOM_VARIANT = IChatBaseComponent.translatable("painting.random").withStyle(EnumChatFormat.GRAY);
|
||||
@@ -74,6 +79,19 @@
|
||||
@@ -75,6 +80,19 @@
|
||||
|
||||
if (((EntityHanging) object).survives()) {
|
||||
if (!world.isClientSide) {
|
||||
@@ -32,3 +32,12 @@
|
||||
((EntityHanging) object).playPlacementSound();
|
||||
world.gameEvent((Entity) entityhuman, (Holder) GameEvent.ENTITY_PLACE, ((EntityHanging) object).position());
|
||||
world.addFreshEntity((Entity) object);
|
||||
@@ -102,7 +120,7 @@
|
||||
|
||||
if (!customdata.isEmpty()) {
|
||||
customdata.read(holderlookup_a.createSerializationContext(DynamicOpsNBT.INSTANCE), EntityPainting.VARIANT_MAP_CODEC).result().ifPresentOrElse((holder) -> {
|
||||
- Optional optional = ((PaintingVariant) holder.value()).title();
|
||||
+ Optional<IChatBaseComponent> optional = ((PaintingVariant) holder.value()).title(); // CraftBukkit - decompile error
|
||||
|
||||
Objects.requireNonNull(list);
|
||||
optional.ifPresent(list::add);
|
||||
|
||||
Reference in New Issue
Block a user