mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 07:20:24 +01:00
Add legacy ping support to PaperServerListPingEvent
Add a new method to StatusClient check if the client is a legacy client that does not support all of the features provided in the event.
This commit is contained in:
parent
635e3fa1fa
commit
16b17bdc68
1 changed files with 12 additions and 0 deletions
|
@ -10,4 +10,16 @@ import com.destroystokyo.paper.event.server.PaperServerListPingEvent;
|
|||
*/
|
||||
public interface StatusClient extends NetworkClient {
|
||||
|
||||
/**
|
||||
* Returns whether the client is using an older version that doesn't
|
||||
* support all the features in {@link PaperServerListPingEvent}.
|
||||
*
|
||||
* <p>For Vanilla, this returns {@code true} for all clients older than 1.7.</p>
|
||||
*
|
||||
* @return {@code true} if the client is using legacy ping
|
||||
*/
|
||||
default boolean isLegacy() {
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue