FlightAssistant icon indicating copy to clipboard operation
FlightAssistant copied to clipboard

Mod triggers Anti-cheat

Open Kishku7 opened this issue 1 year ago • 1 comments

After upgrading from FlightHUD to Flight Assistant today, I started to trigger my servers Anti-cheats.

From the log:

Anticheat Alert Kishku7 failed Elytra (Type F) [1/10] Description: Sending Elytra packets too quickly. Information: delay=7 Server Name: Default Client Brand: Fabric Client Version: 1.21 Ping | TPS: 89ms | 20 Location: (Quantum, -5271, 76, 8000)

This happen when just standing on the edge of a block, and while falling down an "elevator"

Kishku7 avatar Aug 21 '24 17:08 Kishku7

This issue is caused by the automatic elytra opening feature (called "Open Elytra Automatically" in the Flight Automations page of the config).

This happen when just standing on the edge of a block

The code that triggers the automatic open incorrectly activates when the player is on the ground because the fall damage calculation takes into account the ground below the player (which may not be the block they're actually standing on). If there are more than 3 blocks below the edge, then the check passes and an Elytra Switch Packet is sent to the server.

There is a measure supposed to avoid packet spam. When a packet is sent, it won't send more packets until the server confirms the state switch. But the server will not confirm the switch if the player lands in between the time the packet is sent and processed. For that reason, a check was added - count the packet as "processed" when the player is on the ground. This causes the code to send packets at every update. This one is easy to fix (fixing this is easier than explaining it)

while falling down an "elevator"

Please elaborate on what that elevator is and how it functions. I'm not sure on how an elevator might cause the check to be tripped, so details are important.

Octol1ttle avatar Aug 21 '24 17:08 Octol1ttle

@Kishku7 I have published version 2.3.4 BETA 1 containing a fix for this issue. Please verify that the issue is fixed and write back.

Octol1ttle avatar Aug 22 '24 15:08 Octol1ttle

Forgive my ignorance, how do I obtain the beta .jar file?

Kishku7 avatar Aug 22 '24 16:08 Kishku7

Download it from Modrinth: https://modrinth.com/mod/flightassistant/versions

Octol1ttle avatar Aug 22 '24 16:08 Octol1ttle

@Kishku7 any updates on this issue?

Octol1ttle avatar Aug 27 '24 08:08 Octol1ttle

Assuming fixed by https://github.com/Octol1ttle/FlightAssistant/commit/3ac10399f6c1965ffe85fd21f287686e4b3cb0e1 (no response)

Octol1ttle avatar Sep 03 '24 07:09 Octol1ttle