Revert "Packet based movement freeze (#1879)" (#1882)

This reverts commit db3acce70c.
This commit is contained in:
Gabriele C
2019-08-07 10:49:23 +02:00
committed by GitHub
parent db3acce70c
commit 48357831cd
26 changed files with 1145 additions and 234 deletions
@@ -6,7 +6,6 @@ import fr.xephi.authme.data.limbo.LimboService;
import fr.xephi.authme.datasource.DataSource;
import fr.xephi.authme.events.LoginEvent;
import fr.xephi.authme.events.RestoreInventoryEvent;
import fr.xephi.authme.listener.protocollib.ProtocolLibService;
import fr.xephi.authme.permission.PermissionsManager;
import fr.xephi.authme.permission.PlayerStatePermission;
import fr.xephi.authme.process.SynchronousProcess;
@@ -24,7 +23,6 @@ import org.bukkit.potion.PotionEffectType;
import javax.inject.Inject;
import java.util.List;
import static fr.xephi.authme.settings.properties.RestrictionSettings.ALLOW_UNAUTHED_MOVEMENT;
import static fr.xephi.authme.settings.properties.RestrictionSettings.PROTECT_INVENTORY_BEFORE_LOGIN;
public class ProcessSyncPlayerLogin implements SynchronousProcess {
@@ -59,9 +57,6 @@ public class ProcessSyncPlayerLogin implements SynchronousProcess {
@Inject
private PermissionsManager permissionsManager;
@Inject
private ProtocolLibService protocolLibService;
ProcessSyncPlayerLogin() {
}
@@ -92,9 +87,6 @@ public class ProcessSyncPlayerLogin implements SynchronousProcess {
if (commonService.getProperty(PROTECT_INVENTORY_BEFORE_LOGIN)) {
restoreInventory(player);
}
if (!commonService.getProperty(ALLOW_UNAUTHED_MOVEMENT)) {
protocolLibService.sendUnFreezePacket(player);
}
final PlayerAuth auth = dataSource.getAuth(name);
teleportationService.teleportOnLogin(player, auth, limbo);
@@ -56,9 +56,6 @@ public class ProcessSyncPlayerLogout implements SynchronousProcess {
if (service.getProperty(RestrictionSettings.PROTECT_INVENTORY_BEFORE_LOGIN)) {
protocolLibService.sendBlankInventoryPacket(player);
}
if (!service.getProperty(RestrictionSettings.ALLOW_UNAUTHED_MOVEMENT)){
protocolLibService.sendFreezePacket(player);
}
applyLogoutEffect(player);
commandManager.runCommandsOnLogout(player);