Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 04:20:04 +01:00
812618deba
Unintended side effects in recent versions, this patch has likely outlived its usefulness. Closes GH-452
25 Zeilen
1.1 KiB
Diff
25 Zeilen
1.1 KiB
Diff
From 8a94f4550cf262cc0d651b0f080673bd7316b6d1 Mon Sep 17 00:00:00 2001
|
|
From: Fabse <fabse@uwmc.info>
|
|
Date: Mon, 28 Mar 2016 00:46:46 +0200
|
|
Subject: [PATCH] Minecart drop name workaround
|
|
|
|
This is a workaround for MC-68446 (or similar).
|
|
In Survival Minecraft this bug only shows in minecart drops, so this is the only thing fixed here.
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityMinecartAbstract.java b/src/main/java/net/minecraft/server/EntityMinecartAbstract.java
|
|
index 4438d83..9df7dfc 100644
|
|
--- a/src/main/java/net/minecraft/server/EntityMinecartAbstract.java
|
|
+++ b/src/main/java/net/minecraft/server/EntityMinecartAbstract.java
|
|
@@ -172,7 +172,7 @@ public abstract class EntityMinecartAbstract extends Entity implements INamableT
|
|
if (this.world.getGameRules().getBoolean("doEntityDrops")) {
|
|
ItemStack itemstack = new ItemStack(Items.MINECART, 1);
|
|
|
|
- if (this.getName() != null) {
|
|
+ if (this.hasCustomName()) { // Paper - Only set item name if custom name is set. Workaround for MC-68446
|
|
itemstack.c(this.getName());
|
|
}
|
|
|
|
--
|
|
2.9.3
|
|
|