Class CachedPlayer

All Implemented Interfaces:
RemotePlayer

public class CachedPlayer extends RemotePlayer implements RemotePlayer
Cached RemotePlayer Data Class
  • Constructor Details

    • CachedPlayer

      public CachedPlayer(ProxiedPlayer player)
      Convert a Local Player to a Cached Remote Player
      Parameters:
      player - Local Player
    • CachedPlayer

      public CachedPlayer(ObjectMap<String> raw)
      Create a Cached Remote Player
      Parameters:
      raw - Raw representation of the Remote Player
  • Method Details

    • translate

      public static ObjectMap<String> translate(ProxiedPlayer player)
      Convert a Local Player to a Cached Remote Player
      Parameters:
      player - Local Player
      Returns:
      Raw representation of the Remote Player
    • get

      public ProxiedPlayer get()
      Description copied from interface: RemotePlayer
      Get Local Player
      Specified by:
      get in interface RemotePlayer
      Returns:
      Local Player (or null when not local)
    • getServer

      public ServerInfo getServer()
      Description copied from interface: RemotePlayer
      Gets the server this player is connected to.
      Specified by:
      getServer in interface RemotePlayer
      Returns:
      the server this player is connected to
    • broadcastMessage

      public static void broadcastMessage(net.md_5.bungee.api.chat.BaseComponent... message)
      Description copied from interface: RemotePlayer
      Sends a message to all players
      Parameters:
      message - Message to send
    • broadcastMessage

      public static void broadcastMessage(net.md_5.bungee.api.chat.BaseComponent message, IntConsumer response)
      Description copied from interface: RemotePlayer
      Sends a message to all players
      Parameters:
      message - Message to send
      response - Success Status
    • broadcastMessage

      public static void broadcastMessage(net.md_5.bungee.api.chat.BaseComponent[] message, IntConsumer response)
      Description copied from interface: RemotePlayer
      Sends a message to all players
      Parameters:
      message - Message to send
      response - Success Status
    • broadcastMessage

      public static void broadcastMessage(net.md_5.bungee.api.chat.BaseComponent[]... messages)
      Description copied from interface: RemotePlayer
      Sends a message to all players
      Parameters:
      messages - Message to send
    • broadcastMessage

      public static void broadcastMessage(net.md_5.bungee.api.chat.BaseComponent[][] messages, IntConsumer response)
      Description copied from interface: RemotePlayer
      Sends a message to all players
      Parameters:
      messages - Message to send
      response - Success Status
    • sendMessage

      public static void sendMessage(UUID[] players, net.md_5.bungee.api.chat.BaseComponent... message)
      Description copied from interface: RemotePlayer
      Sends a message to these players
      Parameters:
      players - Players to select
      message - Message to send
    • sendMessage

      public static void sendMessage(UUID[] players, net.md_5.bungee.api.chat.BaseComponent message, IntConsumer response)
      Description copied from interface: RemotePlayer
      Sends a message to these players
      Parameters:
      players - Players to select
      message - Message to send
      response - Success Status
    • sendMessage

      public static void sendMessage(UUID[] players, net.md_5.bungee.api.chat.BaseComponent[] message, IntConsumer response)
      Description copied from interface: RemotePlayer
      Sends a message to these players
      Parameters:
      players - Players to select
      message - Message to send
      response - Success Status
    • sendMessage

      public static void sendMessage(UUID[] players, net.md_5.bungee.api.chat.BaseComponent[]... messages)
      Description copied from interface: RemotePlayer
      Sends a message to these players
      Parameters:
      players - Players to select
      messages - Message to send
    • sendMessage

      public static void sendMessage(UUID[] players, net.md_5.bungee.api.chat.BaseComponent[][] messages, IntConsumer response)
      Description copied from interface: RemotePlayer
      Sends a message to these players
      Parameters:
      players - Players to select
      messages - Message to send
      response - Success Status
    • transfer

      public static void transfer(UUID[] players, ServerInfo server)
      Description copied from interface: RemotePlayer
      Transfers these players to another server
      Parameters:
      players - Players to select
      server - Target server
    • transfer

      public static void transfer(UUID[] players, ServerInfo server, IntConsumer response)
      Description copied from interface: RemotePlayer
      Transfers these players to another server
      Parameters:
      players - Players to select
      server - Target server
      response - Success status