mirror of
https://github.com/Winds-Studio/Leaf.git
synced 2025-12-19 15:09:25 +00:00
Upstream has released updates that appear to apply and compile correctly Leaves Changes: LeavesMC/Leaves@0fcb32c [ci skip] update contributing and readme (#381)
44 lines
1.4 KiB
Diff
44 lines
1.4 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: violetc <58360096+s-yh-china@users.noreply.github.com>
|
|
Date: Tue, 13 Sep 2022 16:59:31 +0800
|
|
Subject: [PATCH] Leaves: Server Utils
|
|
|
|
TODO: Check whether Leaves's Return-nether-portal-fix.patch improves performance
|
|
and change store way to sql maybe?
|
|
|
|
Original license: GPLv3
|
|
Original project: https://github.com/LeavesMC/Leaves
|
|
|
|
Commit: 0fcb32c478a8137e692664f332ad2eb0fdd7939b
|
|
|
|
diff --git a/src/main/java/org/leavesmc/leaves/LeavesLogger.java b/src/main/java/org/leavesmc/leaves/LeavesLogger.java
|
|
new file mode 100644
|
|
index 0000000000000000000000000000000000000000..47347a3bdab2ff9818bf8198291d2dabec7da8c6
|
|
--- /dev/null
|
|
+++ b/src/main/java/org/leavesmc/leaves/LeavesLogger.java
|
|
@@ -0,0 +1,24 @@
|
|
+package org.leavesmc.leaves;
|
|
+
|
|
+import org.bukkit.Bukkit;
|
|
+
|
|
+import java.util.logging.Level;
|
|
+import java.util.logging.Logger;
|
|
+
|
|
+public class LeavesLogger extends Logger {
|
|
+ public static final LeavesLogger LOGGER = new LeavesLogger();
|
|
+
|
|
+ private LeavesLogger() {
|
|
+ super("Leaves", null);
|
|
+ setParent(Bukkit.getLogger());
|
|
+ setLevel(Level.ALL);
|
|
+ }
|
|
+
|
|
+ public void severe(String msg, Exception exception) {
|
|
+ this.severe(msg + ", " + exception.getCause() + ": " + exception.getMessage());
|
|
+ }
|
|
+
|
|
+ public void warning(String msg, Exception exception) {
|
|
+ this.warning(msg + ", " + exception.getCause() + ": " + exception.getMessage());
|
|
+ }
|
|
+}
|