Class VelocityPingCounter

  • All Implemented Interfaces:
    java.lang.Runnable

    @Singleton
    public class VelocityPingCounter
    extends TaskSystem.Task
    Task that handles player ping calculation on Velocity based servers.

    Based on PingCountTimerBungee

    • Constructor Summary

      Constructors 
      Constructor Description
      VelocityPingCounter​(net.playeranalytics.plugin.server.Listeners listeners, PlanVelocity plugin, PlanConfig config, DBSystem dbSystem, ServerInfo serverInfo, net.playeranalytics.plugin.scheduling.RunnableFactory runnableFactory)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()  
      void onPlayerJoin​(com.velocitypowered.api.event.player.ServerConnectedEvent joinEvent)  
      void onPlayerQuit​(com.velocitypowered.api.event.connection.DisconnectEvent quitEvent)  
      void register​(net.playeranalytics.plugin.scheduling.RunnableFactory runnableFactory)  
      void removePlayer​(com.velocitypowered.api.proxy.Player player)  
      void run()  
      • Methods inherited from class net.playeranalytics.plugin.scheduling.PluginRunnable

        cancel
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • VelocityPingCounter

        @Inject
        public VelocityPingCounter​(net.playeranalytics.plugin.server.Listeners listeners,
                                   PlanVelocity plugin,
                                   PlanConfig config,
                                   DBSystem dbSystem,
                                   ServerInfo serverInfo,
                                   net.playeranalytics.plugin.scheduling.RunnableFactory runnableFactory)
    • Method Detail

      • run

        public void run()
      • register

        public void register​(net.playeranalytics.plugin.scheduling.RunnableFactory runnableFactory)
        Specified by:
        register in class TaskSystem.Task
      • removePlayer

        public void removePlayer​(com.velocitypowered.api.proxy.Player player)
      • onPlayerJoin

        public void onPlayerJoin​(com.velocitypowered.api.event.player.ServerConnectedEvent joinEvent)
      • onPlayerQuit

        public void onPlayerQuit​(com.velocitypowered.api.event.connection.DisconnectEvent quitEvent)
      • clear

        public void clear()