9
0
mirror of https://github.com/Winds-Studio/Leaf.git synced 2025-12-19 15:09:25 +00:00
Files
Leaf/leaf-archived-patches/removed/1.21.5/mcserver/0041-Softly-log-invalid-pool-element-errors.patch
2025-06-29 23:39:55 +08:00

30 lines
1.7 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Martijn Muijsers <martijnmuijsers@live.nl>
Date: Fri, 25 Nov 2022 16:26:04 +0100
Subject: [PATCH] Softly log invalid pool element errors
Removed since Leaf 1.21.5
License: MIT (https://opensource.org/licenses/MIT)
Gale - https://galemc.org
This patch is based on the following patch:
"Change vanilla structure error to info log level"
By: chickeneer <emcchickeneer@gmail.com>
As part of: EmpireCraft (https://github.com/starlis/empirecraft)
Licensed under: MIT (https://opensource.org/licenses/MIT)
diff --git a/net/minecraft/world/level/levelgen/structure/PoolElementStructurePiece.java b/net/minecraft/world/level/levelgen/structure/PoolElementStructurePiece.java
index 786fa3a33334ca6b4b43b89b6fde9de5c41a3b28..42600faa2a2393d71d93b6818ac64ab030737772 100644
--- a/net/minecraft/world/level/levelgen/structure/PoolElementStructurePiece.java
+++ b/net/minecraft/world/level/levelgen/structure/PoolElementStructurePiece.java
@@ -80,7 +80,7 @@ public class PoolElementStructurePiece extends StructurePiece {
DynamicOps<Tag> dynamicOps = context.registryAccess().createSerializationContext(NbtOps.INSTANCE);
StructurePoolElement.CODEC
.encodeStart(dynamicOps, this.element)
- .resultOrPartial(LOGGER::error)
+ .resultOrPartial(org.galemc.gale.configuration.GaleGlobalConfiguration.get().logToConsole.invalidPoolElementErrorStringConsumer) // Gale - EMC - softly log invalid pool element errors)
.ifPresent(elementTag -> tag.put("pool_element", elementTag));
tag.putString("rotation", this.rotation.name());
ListTag listTag = new ListTag();