From a11f8d33eb98b0ae5e30fbd68def448a9eef8a9c Mon Sep 17 00:00:00 2001 From: Sollace Date: Thu, 22 Feb 2024 00:04:39 +0000 Subject: [PATCH] Fixed clients slinging sneaky superfluous flight control packets. Fixes #267 --- .../minelittlepony/unicopia/entity/player/PlayerPhysics.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java index 2b4b93d0..6005489a 100644 --- a/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java +++ b/src/main/java/com/minelittlepony/unicopia/entity/player/PlayerPhysics.java @@ -234,7 +234,7 @@ public class PlayerPhysics extends EntityPhysics implements Tickab public void tick() { super.tick(); - if (pony.isClient() && this.isFlying()) { + if (pony.isClientPlayer() && isFlying() && (pony.getJumpingHeuristic().hasChanged(Heuristic.ONCE) || pony.sneakingChanged())) { Channel.FLIGHT_CONTROLS_INPUT.sendToServer(new MsgPlayerFlightControlsInput(pony)); }