Name: AntiServerPing Category: Admin Tools Description: Is there a pesky player who keeps pinging your server? Well not any more. With this plugin, just add the IP of the player to the config file, and watch the magic. I'm thinking you can use ProtocolLib for this. Basically I want a plugin, that will detect a blacklisted IP (from the config) that pings the server, and makes the server not return the ping. The server will look like it is offline to the player, but in reality it is not. Thanks in advance! - Blue
So you're asking for a plugin where you define a list of IP addresses and the plugin will just cancel the ServerListPingEvent if they try to ping the server?
What the OP wants is pretty much ddos protection if you ask me. If you cancel the event then the ping is already send
AeroUK Correct. Exactly what I want. I have never seen it been done, but Id like to see it. I know you can't do .setCancelled(true) on the PingEvent. I saw in a post (can't find it any more), a person was able to modify the packet to return the X over the bars, but when you hovered over it, it said Maintenance. The player could not join the server, but It showed the MOTD. Im pretty sure that you could fake the fact that the server is down. I'm not good with ProtocolLib, but I'm sure someone else could do this.
Change the return version to alpha v0.0.0.0.0.0.0.1 or something as it would look like it's not working.