aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches
diff options
context:
space:
mode:
authorSpottedleaf <[email protected]>2024-08-18 15:32:25 -0700
committerSpottedleaf <[email protected]>2024-08-18 15:32:25 -0700
commitbe1078f5f2e28c1a1de99e9c96e4003c3f96f6e8 (patch)
treee01011f9ac7dc4887a4108d662379ee080a803f5 /patches
parentb4bc512cac4d75f9e366479c5d8fdcf4275c85ce (diff)
downloadPaper-be1078f5f2e28c1a1de99e9c96e4003c3f96f6e8.tar.gz
Paper-be1078f5f2e28c1a1de99e9c96e4003c3f96f6e8.zip
Use player file, not directory, when checking for offline player data
When trying to fall back to offline player data in onlide mode, we need to use the player file. This fixes a mistake during update where 'file' was used, but the new code uses 'file1' for the player file.
Diffstat (limited to 'patches')
-rw-r--r--patches/server/0039-Check-online-mode-before-converting-and-renaming-pla.patch4
1 files changed, 2 insertions, 2 deletions
diff --git a/patches/server/0039-Check-online-mode-before-converting-and-renaming-pla.patch b/patches/server/0039-Check-online-mode-before-converting-and-renaming-pla.patch
index f89cf885a5..70183b1722 100644
--- a/patches/server/0039-Check-online-mode-before-converting-and-renaming-pla.patch
+++ b/patches/server/0039-Check-online-mode-before-converting-and-renaming-pla.patch
@@ -5,7 +5,7 @@ Subject: [PATCH] Check online mode before converting and renaming player data
diff --git a/src/main/java/net/minecraft/world/level/storage/PlayerDataStorage.java b/src/main/java/net/minecraft/world/level/storage/PlayerDataStorage.java
-index 79222a04ef104bf2eed85684479384b7c350ea19..e11c8523e633d2a8e3cea7ecd54978b2958b9684 100644
+index 79222a04ef104bf2eed85684479384b7c350ea19..cd013567dd6224c86c0f1813d8a3d5fb7b8cabb5 100644
--- a/src/main/java/net/minecraft/world/level/storage/PlayerDataStorage.java
+++ b/src/main/java/net/minecraft/world/level/storage/PlayerDataStorage.java
@@ -78,7 +78,7 @@ public class PlayerDataStorage {
@@ -13,7 +13,7 @@ index 79222a04ef104bf2eed85684479384b7c350ea19..e11c8523e633d2a8e3cea7ecd54978b2
// Spigot Start
boolean usingWrongFile = false;
- if ( !file1.exists() )
-+ if ( org.bukkit.Bukkit.getOnlineMode() && !file.exists() ) // Paper - Check online mode first
++ if ( org.bukkit.Bukkit.getOnlineMode() && !file1.exists() ) // Paper - Check online mode first
{
file1 = new File( file, java.util.UUID.nameUUIDFromBytes( ( "OfflinePlayer:" + name ).getBytes( java.nio.charset.StandardCharsets.UTF_8 ) ).toString() + s );
if ( file1.exists() )