mirror of
https://github.com/Dreeam-qwq/Gale.git
synced 2025-12-21 15:59:28 +00:00
Rebuild
This commit is contained in:
@@ -0,0 +1,71 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Muijsers <martijnmuijsers@live.nl>
|
||||
Date: Fri, 25 Nov 2022 15:03:50 +0100
|
||||
Subject: [PATCH] Do not log legacy Material initialization
|
||||
|
||||
License: MIT (https://opensource.org/licenses/MIT)
|
||||
Gale - https://galemc.org
|
||||
|
||||
This patch is based on the following patch:
|
||||
"Logger settings (suppressing pointless logs)"
|
||||
By: William Blake Galbreath <blake.galbreath@gmail.com>
|
||||
As part of: Purpur (https://github.com/PurpurMC/Purpur)
|
||||
Licensed under: MIT (https://opensource.org/licenses/MIT)
|
||||
|
||||
* Purpur copyright *
|
||||
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2019-2022 PurpurMC
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/legacy/CraftLegacy.java b/src/main/java/org/bukkit/craftbukkit/legacy/CraftLegacy.java
|
||||
index dc591702d1ad41209bb80e8d05f4ca11f20816f2..38a5b11d52ffcd1e3f7ffe8d617e7d3fd93f07c6 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/legacy/CraftLegacy.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/legacy/CraftLegacy.java
|
||||
@@ -31,6 +31,7 @@ import org.bukkit.Material;
|
||||
import org.bukkit.craftbukkit.util.CraftMagicNumbers;
|
||||
import org.bukkit.entity.EntityType;
|
||||
import org.bukkit.material.MaterialData;
|
||||
+import org.galemc.gale.configuration.GaleGlobalConfiguration;
|
||||
|
||||
/**
|
||||
* This class may seem unnecessarily slow and complicated/repetitive however it
|
||||
@@ -265,7 +266,7 @@ public final class CraftLegacy {
|
||||
}
|
||||
|
||||
static {
|
||||
- LOGGER.warn("Initializing Legacy Material Support. Unless you have legacy plugins and/or data this is a bug!"); // Paper - Improve logging and errors; doesn't need to be an error
|
||||
+ if (GaleGlobalConfiguration.get().logToConsole.legacyMaterialInitialization) LOGGER.warn("Initializing Legacy Material Support. Unless you have legacy plugins and/or data this is a bug!"); // Paper - Improve logging and errors; doesn't need to be an error // Gale - Purpur - do not log legacy Material initialization
|
||||
if (MinecraftServer.getServer() != null && MinecraftServer.getServer().isDebugging()) {
|
||||
new Exception().printStackTrace();
|
||||
}
|
||||
diff --git a/src/main/java/org/galemc/gale/configuration/GaleGlobalConfiguration.java b/src/main/java/org/galemc/gale/configuration/GaleGlobalConfiguration.java
|
||||
index c6908d6cf03a514690508ae216d3a6347ded0b61..5af30bdac9e9315b53d31309956486ca3f0622b5 100644
|
||||
--- a/src/main/java/org/galemc/gale/configuration/GaleGlobalConfiguration.java
|
||||
+++ b/src/main/java/org/galemc/gale/configuration/GaleGlobalConfiguration.java
|
||||
@@ -91,6 +91,7 @@ public class GaleGlobalConfiguration extends ConfigurationPart {
|
||||
public boolean ignoredAdvancements = true; // Gale - Purpur - do not log ignored advancements
|
||||
public boolean setBlockInFarChunk = true; // Gale - Purpur - do not log setBlock in far chunks
|
||||
public boolean unrecognizedRecipes = false; // Gale - Purpur - do not log unrecognized recipes
|
||||
+ public boolean legacyMaterialInitialization = false; // Gale - Purpur - do not log legacy Material initialization
|
||||
|
||||
public Chat chat;
|
||||
public class Chat extends ConfigurationPart {
|
||||
Reference in New Issue
Block a user