Class SelectorComponent

java.lang.Object
net.md_5.bungee.api.chat.BaseComponent
net.md_5.bungee.api.chat.SelectorComponent

public final class SelectorComponent extends BaseComponent
This component processes a target selector into a pre-formatted set of discovered names.
Multiple targets may be obtained, and with commas separating each one and a final "and" for the last target. The resulting format cannot be overwritten. This includes all styling from team prefixes, insertions, click events, and hover events.
These values are filled in by the server-side implementation.
As of 1.12.2, a bug ( MC-56373 ) prevents full usage within hover events.
  • Constructor Details

    • SelectorComponent

      public SelectorComponent(SelectorComponent original)
      Creates a selector component from the original to clone it.
      Parameters:
      original - the original for the new selector component
    • SelectorComponent

      public SelectorComponent(String selector)
      Creates a selector component from the selector
      Parameters:
      selector - the selector as a String
  • Method Details