2021-06-11 14:02:28 +02:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Mark Vainomaa <mikroskeem@mikroskeem.eu>
|
|
|
|
Date: Mon, 26 Mar 2018 18:30:53 +0300
|
|
|
|
Subject: [PATCH] Make player data saving configurable
|
|
|
|
|
|
|
|
Upstream has added a patch which negates the need for this patch,
|
|
|
|
however, we should still migrate our configuration back upstream,
|
|
|
|
to prevent unexpected situations
|
|
|
|
|
|
|
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperConfig.java b/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
2021-07-26 01:11:44 +02:00
|
|
|
index 8007220fa0646414c9cec66161aca2394e62dde3..3c29a0a39df1d6d4100a8a2fa403746ca4b95717 100644
|
2021-06-11 14:02:28 +02:00
|
|
|
--- a/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
|
|
|
+++ b/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
2021-07-26 01:11:44 +02:00
|
|
|
@@ -288,4 +288,13 @@ public class PaperConfig {
|
2021-06-11 14:02:28 +02:00
|
|
|
private static void authenticationServersDownKickMessage() {
|
|
|
|
authenticationServersDownKickMessage = Strings.emptyToNull(getString("messages.kick.authentication-servers-down", authenticationServersDownKickMessage));
|
|
|
|
}
|
|
|
|
+
|
|
|
|
+ private static void savePlayerData() {
|
|
|
|
+ Object val = config.get("settings.save-player-data");
|
|
|
|
+ if (val instanceof Boolean) {
|
|
|
|
+ SpigotConfig.disablePlayerDataSaving = !(Boolean) val;
|
|
|
|
+ SpigotConfig.config.set("players.disable-saving", SpigotConfig.disableAdvancementSaving);
|
|
|
|
+ SpigotConfig.save();
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
}
|