mirror of
https://github.com/ViaVersion/ViaVersion.git
synced 2024-12-22 16:38:20 +01:00
Fix idle ticking in proxies (#2631)
This commit is contained in:
parent
d7966567e7
commit
d14db9396b
@ -39,13 +39,14 @@ public class BungeeMovementTransmitter extends MovementTransmitterProvider {
|
||||
public void sendPlayer(UserConnection userConnection) {
|
||||
if (userConnection.getProtocolInfo().getState() == State.PLAY) {
|
||||
PacketWrapper wrapper = PacketWrapper.create(0x03, null, userConnection);
|
||||
wrapper.write(Type.BOOLEAN, userConnection.get(MovementTracker.class).isGround());
|
||||
MovementTracker tracker = userConnection.get(MovementTracker.class);
|
||||
wrapper.write(Type.BOOLEAN, tracker.isGround());
|
||||
try {
|
||||
wrapper.scheduleSendToServer(Protocol1_9To1_8.class);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
// PlayerPackets will increment idle
|
||||
tracker.incrementIdlePacket();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -39,13 +39,14 @@ public class VelocityMovementTransmitter extends MovementTransmitterProvider {
|
||||
public void sendPlayer(UserConnection userConnection) {
|
||||
if (userConnection.getProtocolInfo().getState() == State.PLAY) {
|
||||
PacketWrapper wrapper = PacketWrapper.create(0x03, null, userConnection);
|
||||
wrapper.write(Type.BOOLEAN, userConnection.get(MovementTracker.class).isGround());
|
||||
MovementTracker tracker = userConnection.get(MovementTracker.class);
|
||||
wrapper.write(Type.BOOLEAN, tracker.isGround());
|
||||
try {
|
||||
wrapper.scheduleSendToServer(Protocol1_9To1_8.class);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
// PlayerPackets will increment idle
|
||||
tracker.incrementIdlePacket();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user