ImpossibleLatency 1.0.0

"0ms ping? On my server? It's more likely than you think."

  1. MrPowerGamerBR
    Tested Minecraft Versions:
    • 1.12
    Source Code:
    https://github.com/PerfectDreams/ImpossibleLatency
    [​IMG]
    [​IMG]

    [​IMG]
    [​IMG] [​IMG] [​IMG]
    ImpossibleLatency
    [​IMG] [​IMG]

    "0ms ping? On my server? It's more likely than you think."

    (soon BungeeCord version)​

    How it works?
    When Minecraft pings a server, it sends two packets:
    Request Server Info Packet: This asks the server to send the server info (player count, MOTD, etc)
    Ping Packet: This is used to calculate the latency between the client and the server, the latency is calculated by time since the client sent the ping packet - time when the client received the pong packet

    And the server sends two packets:
    Server Info Packet: A JSON string with all the server information.
    Pong Packet: When the server receives a ping packet, the server should reply with this packet.

    However... we can expoit a little issue with this... the client doesn't check if the pong packet was sent before the ping packet!

    In vanilla, the order goes something like this:

    Client asks the server for the server information
    Server sends the server information
    Client processes the information
    Client sends a ping packet
    Server responds the ping packet with a pong packet
    Latency is calculated

    However, ImpossibleLatency changes the order a little bit...

    Client asks the server for the server information
    Server sends the server information
    Server sends the pong packet
    Client processes the information and also receives the pong packet, however the pong packet is moved to the packet queue.
    Client sends a ping packet
    The next packet in the queue is processed, in this case, the pong packet.
    Latency is calculated, because the pong packet is processed right after the server info packet, the latency is very small, ranging from 0ms to 3ms!

    This won't make your server less "laggy"!

    Dependencies
    • ProtocolLib
    ‍ GitHub
    https://github.com/PerfectDreams/ImpossibleLatency
    MIOR likes this.

Recent Reviews

  1. Aureom
    Aureom
    5/5,
    Version: 1.0.0
    #1 Ping manipulation on spigot, awesome plugin, and awesome dev.


    - macumbeiro -
  2. MIOR
    MIOR
    5/5,
    Version: 1.0.0
    Good Plugin! Totally innovator! Congratulations! !
    1. MrPowerGamerBR
      Author's Response
      Thanks for your review!