diff --git a/README.md b/README.md index cdfebb2..ec77181 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ AntiCheatReloaded helps server admins combat the use of hacked clients and spamb Installation ------------ -AntiCheatReloaded requires you to have ProtocolLib. You can download it [here](https://www.spigotmc.org/resources/protocollib.1997/). +AntiCheatReloaded **requires** you to have ProtocolLib. You can download it [here](https://www.spigotmc.org/resources/protocollib.1997/). Simply drag and drop the AntiCheatReloaded and ProtocolLib jars in your plugin folder. You can now use AntiCheatReloaded, but be sure to have a look at the configuration files, which allow you to change every aspect of the plugin. Bug Reporting diff --git a/src/main/java/com/rammelkast/anticheatreloaded/check/movement/WaterWalkCheck.java b/src/main/java/com/rammelkast/anticheatreloaded/check/movement/WaterWalkCheck.java index d551692..4d209d9 100644 --- a/src/main/java/com/rammelkast/anticheatreloaded/check/movement/WaterWalkCheck.java +++ b/src/main/java/com/rammelkast/anticheatreloaded/check/movement/WaterWalkCheck.java @@ -79,6 +79,19 @@ public final class WaterWalkCheck { + Utilities.roundDouble(movementManager.distanceXZ, 5) + ", absMotionY=" + Utilities.roundDouble(Math.abs(movementManager.lastMotionY - movementManager.motionY), 5) + ")"); } + + if (checksConfig.isSubcheckEnabled(CheckType.WATER_WALK, "lunge") && Utilities.isSurroundedByWater(player) + && movementManager.distanceXZ > 0.16 && movementManager.motionY > 0.0 + && movementManager.lastMotionY < 0.0 + && (Math.abs(movementManager.motionY) < 0.017 && Math.abs(movementManager.lastMotionY) < 0.02) + && Math.abs(movementManager.lastMotionY - 0.004) < 0.021 + && user.getVelocityTracker().getHorizontal() < 0.04 + && !Utilities.couldBeOnBoat(player, 0.3, false)) { + return new CheckResult(Result.FAILED, "Lunge", "tried to lunge in water (xz=" + + Utilities.roundDouble(movementManager.distanceXZ, 5) + ", motionY=" + + Utilities.roundDouble(movementManager.motionY, 5) + ", lastMotionY=" + + Utilities.roundDouble(movementManager.lastMotionY, 5) + ")"); + } return PASS; }