mirror of
https://github.com/darksaid98/AntiCheatReloaded.git
synced 2026-12-03 06:28:52 +00:00
Fixed Glide false positive, added config
This commit is contained in:
1 parent
bf1d929390
commit
461f22cc55
3 files changed
+6
-1
No files matched your search
@@ -32,7 +32,7 @@ public class GlideCheck {
|
|||||||
YAxisCheck.lastYcoord.put(name, player.getLocation().getY());
|
YAxisCheck.lastYcoord.put(name, player.getLocation().getY());
|
||||||
double currentY = player.getLocation().getY();
|
double currentY = player.getLocation().getY();
|
||||||
double math = currentY - YAxisCheck.lastYcoord.get(name);
|
double math = currentY - YAxisCheck.lastYcoord.get(name);
|
||||||
if(math < 0 && !AntiCheat.getManager().getBackend().isMovingExempt(player))
|
if((math < 0 && math > AntiCheat.getManager().getBackend().getMagic().GLIDE_MAX()) && !AntiCheat.getManager().getBackend().isMovingExempt(player))
|
||||||
{
|
{
|
||||||
if(math <= lastYDelta.get(name) && !(player.getEyeLocation().getBlock().getType() == Material.LADDER)
|
if(math <= lastYDelta.get(name) && !(player.getEyeLocation().getBlock().getType() == Material.LADDER)
|
||||||
&& !Utilities.isInWater(player) && !Utilities.isInWeb(player)
|
&& !Utilities.isInWater(player) && !Utilities.isInWeb(player)
|
||||||
|
|||||||
@@ -161,6 +161,10 @@ public interface Magic {
|
|||||||
* Number of times a player can be caught in-glide before action is taken; Type=INTEGER, Leniency=INCREASE.
|
* Number of times a player can be caught in-glide before action is taken; Type=INTEGER, Leniency=INCREASE.
|
||||||
*/
|
*/
|
||||||
public int GLIDE_LIMIT();
|
public int GLIDE_LIMIT();
|
||||||
|
/**
|
||||||
|
* The max fallspeed after which glide check is disabled; Type=DOUBLE
|
||||||
|
*/
|
||||||
|
public double GLIDE_MAX();
|
||||||
/**
|
/**
|
||||||
* How many blocks you can travel before action is taken; Type=INTEGER, Leniency=INCREASE.
|
* How many blocks you can travel before action is taken; Type=INTEGER, Leniency=INCREASE.
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -84,3 +84,4 @@ Y_MAXVIOTIME: 5000
|
|||||||
Y_SPEED_MAX: 0.5
|
Y_SPEED_MAX: 0.5
|
||||||
Y_TIME: 1000
|
Y_TIME: 1000
|
||||||
GLIDE_LIMIT: 10
|
GLIDE_LIMIT: 10
|
||||||
|
GLIDE_MAX: -3.75
|
||||||
Reference in new issue
Block a user