- Add restore method in LimboCache

* Apply it to process that have use of it
- Fix fly & walk speed not get restored
This commit is contained in:
DNx5
2016-07-04 13:21:57 +07:00
parent deffcb3e2b
commit 140275f366
14 changed files with 98 additions and 115 deletions
@@ -66,14 +66,14 @@ public class AuthGroupHandler {
return permissionsManager.addGroup(player, settings.getProperty(SecuritySettings.UNLOGGEDIN_GROUP));
case LOGGED_IN:
// Get the limbo player data
PlayerData limbo = limboCache.getPlayerData(player.getName().toLowerCase());
if (limbo == null) {
// Get the player data
PlayerData data = limboCache.getPlayerData(player.getName().toLowerCase());
if (data == null) {
return false;
}
// Get the players group
String realGroup = limbo.getGroup();
String realGroup = data.getGroup();
// Remove the other group types groups, set the real group
permissionsManager.removeGroups(player,