Class ProxyData

java.lang.Object
net.glowstone.net.ProxyData

public final class ProxyData extends Object
Container for proxy (e.g. BungeeCord) player data spoofing.
  • Constructor Details

    • ProxyData

      public ProxyData(GlowSession session, String sourceText) throws Exception
      Create a proxy data structure for a session from the given source text.
      Parameters:
      session - The session to create the data for.
      sourceText - Contents of the hostname field of the handshake.
      Throws:
      Exception - if an error occurs parsing the source text.
    • ProxyData

      public ProxyData(String hostname, InetSocketAddress address, UUID uuid, List<com.destroystokyo.paper.profile.ProfileProperty> properties)
  • Method Details

    • getProfile

      public GlowPlayerProfile getProfile(String name)
      Get a spoofed profile to use with the given name.
      Parameters:
      name - The player name.
      Returns:
      The spoofed profile.
    • getHostname

      public String getHostname()
      The spoofed hostname to use instead of the actual one.
    • getAddress

      public InetSocketAddress getAddress()
      The spoofed address to use instead of the actual one.
      Returns:
      The spoofed address.