1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-08-13 18:14:38 +02:00

Fixed offline player data changes rollingback on relogin. Need to reproccess OfflinePlayer as a user, not declare it as a user. Tested and works perfectly.

git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1347 e251c2fe-e539-e718-e476-b85c1f46cddb
This commit is contained in:
xeology
2011-05-05 04:32:32 +00:00
parent def1f0948a
commit f4cd897ff8

View File

@@ -592,8 +592,9 @@ public class Essentials extends JavaPlugin
File userFolder = new File(getDataFolder(), "userdata");
File userFile = new File(userFolder, Util.sanitizeFileName(name) + ".yml");
if (userFile.exists())
{
return new User(new OfflinePlayer(name), this);
{ //Users do not get offline changes saved without being reproccessed as Users! ~ Xeology :)
User user=getUser((Player) new OfflinePlayer(name));
return user;
}
return null;
}