Update to 1.16.5, found code issue that caused #119, patched #128

This commit is contained in:
Rammelkast committed 2021-01-23 11:55:12 +01:00
1 parent 7f9d3c1396
commit 6f5cd70ba3
7 files changed
+68 -39

No files matched your search

@@ -89,10 +89,6 @@ public class MovementManager {
public boolean hasSpeedEffect = false;
// If the player had speed effect previous tick
public boolean hadSpeedEffect = false;
// If the player has a speed increasing effect
public boolean hasIncreasingEffect = false;
// If the player had a speed increasing effect previous tick
public boolean hadIncreasingEffect = false;
// Riptiding ticks
public int riptideTicks;
// Time of last update
@@ -121,12 +117,13 @@ public class MovementManager {
// Handle 1.9+ potion effects
if (MinecraftVersion.atOrAbove(MinecraftVersion.COMBAT_UPDATE)) {
for (PotionEffect effect : player.getActivePotionEffects()) {
if (!VersionUtil.isLevitationEffect(effect))
return;
if (!VersionUtil.isLevitationEffect(effect)) {
continue;
}
AntiCheatReloaded.getManager().getBackend().logLevitating(player, 1);
}
}
this.touchedGroundThisTick = false;
this.halfMovement = false;
if (!this.onGround) {
@@ -197,9 +194,6 @@ public class MovementManager {
this.hadSpeedEffect = this.hasSpeedEffect;
this.hasSpeedEffect = player.hasPotionEffect(PotionEffectType.SPEED);
this.hadIncreasingEffect = this.hasIncreasingEffect;
this.hasIncreasingEffect = !player.getActivePotionEffects().isEmpty();
double lastDistanceSq = Math.sqrt(this.lastDistance.getXDifference() * this.lastDistance.getXDifference()
+ this.lastDistance.getZDifference() * this.lastDistance.getZDifference());