From 8fd0e25fdff5995f5c147e1e3df22a246f92edc0 Mon Sep 17 00:00:00 2001 From: XIII-MC Date: Sat, 19 Oct 2024 16:26:08 +0200 Subject: [PATCH] Fixed right click false --- src/main/java/net/gteam/wave/checks/impl/fly/Fly10A.java | 6 ------ .../net/gteam/wave/playerdata/data/impl/ActionData.java | 9 +++++++++ .../gteam/wave/playerdata/data/impl/MovementData.java | 3 +++ 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/main/java/net/gteam/wave/checks/impl/fly/Fly10A.java b/src/main/java/net/gteam/wave/checks/impl/fly/Fly10A.java index c8de9c6..ce8d32f 100644 --- a/src/main/java/net/gteam/wave/checks/impl/fly/Fly10A.java +++ b/src/main/java/net/gteam/wave/checks/impl/fly/Fly10A.java @@ -69,12 +69,6 @@ public void handle(final ClientPlayPacket clientPlayPacket) { if (invalid && !exempt) { - // GREEN (§a) till here - // YELLOW (§e) till here - // ORANGE (§6) till here - // GREEN (§a) till here - // YELLOW (§e) till here - // ORANGE (§6) till here fail("§a" + "deltaY=" + deltaY + "\n" + "predictedDeltaY=" + predictedDeltaY + "\n" + "maximumOffset=" + maximumOffset + "\n" // GREEN (§a) till here diff --git a/src/main/java/net/gteam/wave/playerdata/data/impl/ActionData.java b/src/main/java/net/gteam/wave/playerdata/data/impl/ActionData.java index dc8a51b..949e2d2 100644 --- a/src/main/java/net/gteam/wave/playerdata/data/impl/ActionData.java +++ b/src/main/java/net/gteam/wave/playerdata/data/impl/ActionData.java @@ -27,6 +27,11 @@ public class ActionData implements Data { private int lastAllowFlightTicks, lastSleepingTicks, lastRidingTicks; + /* + * 1.9+ + */ + private int lastDuplicateOnePointSeventeenPacketTicks = 100; + public ActionData(final Profile profile) { this.desync = new Desync(profile); @@ -81,4 +86,8 @@ public int getLastSleepingTicks() { public GameMode getGameMode() { return gameMode; } + + public int getLastDuplicateOnePointSeventeenPacketTicks() { + return lastDuplicateOnePointSeventeenPacketTicks; + } } diff --git a/src/main/java/net/gteam/wave/playerdata/data/impl/MovementData.java b/src/main/java/net/gteam/wave/playerdata/data/impl/MovementData.java index 073ba0c..13f2401 100644 --- a/src/main/java/net/gteam/wave/playerdata/data/impl/MovementData.java +++ b/src/main/java/net/gteam/wave/playerdata/data/impl/MovementData.java @@ -97,6 +97,9 @@ public void process(final ClientPlayPacket packet) { case PLAYER_POSITION_AND_ROTATION: + //1.17+ + if (profile.getActionData().getLastDuplicateOnePointSeventeenPacketTicks() == 0) break; // TODO: sus? + final WrapperPlayClientPlayerPositionAndRotation posLook = packet.getPositionLookWrapper(); this.lastOnGround = this.onGround;