Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-16 11:30:06 +01:00
0aa0a1d973
Upstream has released updates that appear to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing CraftBukkit Changes: b5d7883a SPIGOT-6634: Override needed method 99561c21 SPIGOT-6624: Explosions do not destroy blocks out of vanilla heights in custom dimensions
36 Zeilen
2.0 KiB
Diff
36 Zeilen
2.0 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Malfrador <malfrador@gmail.com>
|
|
Date: Wed, 7 Jul 2021 12:48:50 +0200
|
|
Subject: [PATCH] Config option for named entity death logging
|
|
|
|
|
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperConfig.java b/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
|
index 98b71384508447adc80c2175f8e35e5d86b0c378..f101302892a7f95ffa0e6d63cb69d8a3ddbd67a7 100644
|
|
--- a/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
|
+++ b/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
|
@@ -492,6 +492,11 @@ public class PaperConfig {
|
|
deobfuscateStacktraces = getBoolean("settings.loggers.deobfuscate-stacktraces", deobfuscateStacktraces);
|
|
}
|
|
|
|
+ public static boolean logNamedEntityDeaths = true;
|
|
+ private static void namedEntityDeaths() {
|
|
+ logNamedEntityDeaths = getBoolean("settings.log-named-entity-deaths", logNamedEntityDeaths);
|
|
+ }
|
|
+
|
|
public static int itemValidationDisplayNameLength = 8192;
|
|
public static int itemValidationLocNameLength = 8192;
|
|
public static int itemValidationLoreLineLength = 8192;
|
|
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
|
index 442d0df276defbbea1b4282b99460ab463c2e5e0..027898e97667081840562547653d4adaeae01dda 100644
|
|
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
|
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
|
@@ -1634,7 +1634,7 @@ public abstract class LivingEntity extends Entity {
|
|
this.stopSleeping();
|
|
}
|
|
|
|
- if (!this.level.isClientSide && this.hasCustomName()) {
|
|
+ if (com.destroystokyo.paper.PaperConfig.logNamedEntityDeaths && !this.level.isClientSide && this.hasCustomName()) { // Paper - add setting for entity death logging
|
|
LivingEntity.LOGGER.info("Named entity {} died: {}", this, this.getCombatTracker().getDeathMessage().getString());
|
|
}
|
|
|