Class Title

java.lang.Object
com.destroystokyo.paper.Title

@Deprecated(since="1.16.5") public final class Title extends Object
Deprecated.
use Title
Represents a title to may be sent to a Player.

A title can be sent without subtitle text.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final class 
    Deprecated.
    A builder for creating titles
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
    Deprecated.
    The default number of ticks for the title to fade in.
    static final int
    Deprecated.
    The default number of ticks for the title to fade out.
    static final int
    Deprecated.
    The default number of ticks for the title to stay.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated.
    Create a title with the default time values and no subtitle.
    Title(@NotNull String title, @Nullable String subtitle)
    Deprecated.
    Create a title with the default time values.
    Title(@NotNull String title, @Nullable String subtitle, int fadeIn, int stay, int fadeOut)
    Deprecated.
    Creates a new title.
    Title(@NotNull net.md_5.bungee.api.chat.BaseComponent title)
    Deprecated.
    Create a title with the default time values and no subtitle.
    Title(@NotNull net.md_5.bungee.api.chat.BaseComponent[] title)
    Deprecated.
    Create a title with the default time values and no subtitle.
    Title(@NotNull net.md_5.bungee.api.chat.BaseComponent[] title, @Nullable net.md_5.bungee.api.chat.BaseComponent[] subtitle)
    Deprecated.
    Create a title with the default time values.
    Title(@NotNull net.md_5.bungee.api.chat.BaseComponent title, @Nullable net.md_5.bungee.api.chat.BaseComponent subtitle)
    Deprecated.
    Create a title with the default time values.
    Title(@NotNull net.md_5.bungee.api.chat.BaseComponent title, @Nullable net.md_5.bungee.api.chat.BaseComponent subtitle, int fadeIn, int stay, int fadeOut)
    Deprecated.
    Creates a new title.
    Title(@Nullable net.md_5.bungee.api.chat.BaseComponent[] title, @NotNull net.md_5.bungee.api.chat.BaseComponent[] subtitle, int fadeIn, int stay, int fadeOut)
    Deprecated.
    Creates a new title.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Deprecated.
    Sends the title directly to all online players
    Deprecated.
     
    int
    Deprecated.
    Gets the number of ticks to fade in.
    int
    Deprecated.
    Gets the number of ticks to fade out.
    int
    Deprecated.
    Gets the number of ticks to stay.
    @Nullable net.md_5.bungee.api.chat.BaseComponent[]
    Deprecated.
    Gets the text of this title's subtitle
    @NotNull net.md_5.bungee.api.chat.BaseComponent[]
    Deprecated.
    Gets the text of this title
    void
    send(@NotNull Collection<? extends Player> players)
    Deprecated.
    Sends the title directly to the defined players
    void
    Deprecated.
    Sends the title directly to an player
    void
    send(@NotNull Player[] players)
    Deprecated.
    Sends the title directly to the defined players

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • DEFAULT_FADE_IN

      public static final int DEFAULT_FADE_IN
      Deprecated.
      The default number of ticks for the title to fade in.
      See Also:
    • DEFAULT_STAY

      public static final int DEFAULT_STAY
      Deprecated.
      The default number of ticks for the title to stay.
      See Also:
    • DEFAULT_FADE_OUT

      public static final int DEFAULT_FADE_OUT
      Deprecated.
      The default number of ticks for the title to fade out.
      See Also:
  • Constructor Details

    • Title

      public Title(@NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent title)
      Deprecated.
      Create a title with the default time values and no subtitle.

      Times use default values.

      Parameters:
      title - the main text of the title
      Throws:
      NullPointerException - if the title is null
    • Title

      public Title(@NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent[] title)
      Deprecated.
      Create a title with the default time values and no subtitle.

      Times use default values.

      Parameters:
      title - the main text of the title
      Throws:
      NullPointerException - if the title is null
    • Title

      public Title(@NotNull @NotNull String title)
      Deprecated.
      Create a title with the default time values and no subtitle.

      Times use default values.

      Parameters:
      title - the main text of the title
      Throws:
      NullPointerException - if the title is null
    • Title

      public Title(@NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent title, @Nullable @Nullable net.md_5.bungee.api.chat.BaseComponent subtitle)
      Deprecated.
      Create a title with the default time values.

      Times use default values.

      Parameters:
      title - the main text of the title
      subtitle - the secondary text of the title
    • Title

      public Title(@NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent[] title, @Nullable @Nullable net.md_5.bungee.api.chat.BaseComponent[] subtitle)
      Deprecated.
      Create a title with the default time values.

      Times use default values.

      Parameters:
      title - the main text of the title
      subtitle - the secondary text of the title
    • Title

      public Title(@NotNull @NotNull String title, @Nullable @Nullable String subtitle)
      Deprecated.
      Create a title with the default time values.

      Times use default values.

      Parameters:
      title - the main text of the title
      subtitle - the secondary text of the title
    • Title

      public Title(@NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent title, @Nullable @Nullable net.md_5.bungee.api.chat.BaseComponent subtitle, int fadeIn, int stay, int fadeOut)
      Deprecated.
      Creates a new title.
      Parameters:
      title - the main text of the title
      subtitle - the secondary text of the title
      fadeIn - the number of ticks for the title to fade in
      stay - the number of ticks for the title to stay on screen
      fadeOut - the number of ticks for the title to fade out
      Throws:
      IllegalArgumentException - if any of the times are negative
    • Title

      public Title(@Nullable @Nullable net.md_5.bungee.api.chat.BaseComponent[] title, @NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent[] subtitle, int fadeIn, int stay, int fadeOut)
      Deprecated.
      Creates a new title.
      Parameters:
      title - the main text of the title
      subtitle - the secondary text of the title
      fadeIn - the number of ticks for the title to fade in
      stay - the number of ticks for the title to stay on screen
      fadeOut - the number of ticks for the title to fade out
      Throws:
      IllegalArgumentException - if any of the times are negative
    • Title

      public Title(@NotNull @NotNull String title, @Nullable @Nullable String subtitle, int fadeIn, int stay, int fadeOut)
      Deprecated.
      Creates a new title.

      It is recommended to the BaseComponent constrctors.

      Parameters:
      title - the main text of the title
      subtitle - the secondary text of the title
      fadeIn - the number of ticks for the title to fade in
      stay - the number of ticks for the title to stay on screen
      fadeOut - the number of ticks for the title to fade out
  • Method Details

    • getTitle

      @NotNull public @NotNull net.md_5.bungee.api.chat.BaseComponent[] getTitle()
      Deprecated.
      Gets the text of this title
      Returns:
      the text
    • getSubtitle

      @Nullable public @Nullable net.md_5.bungee.api.chat.BaseComponent[] getSubtitle()
      Deprecated.
      Gets the text of this title's subtitle
      Returns:
      the text
    • getFadeIn

      public int getFadeIn()
      Deprecated.
      Gets the number of ticks to fade in.

      The returned value is never negative.

      Returns:
      the number of ticks to fade in
    • getStay

      public int getStay()
      Deprecated.
      Gets the number of ticks to stay.

      The returned value is never negative.

      Returns:
      the number of ticks to stay
    • getFadeOut

      public int getFadeOut()
      Deprecated.
      Gets the number of ticks to fade out.

      The returned value is never negative.

      Returns:
      the number of ticks to fade out
    • send

      public void send(@NotNull @NotNull Player player)
      Deprecated.
      Sends the title directly to an player
      Parameters:
      player - the receiver of the title
    • send

      public void send(@NotNull @NotNull Collection<? extends Player> players)
      Deprecated.
      Sends the title directly to the defined players
      Parameters:
      players - the receivers of the title
    • send

      public void send(@NotNull @NotNull Player[] players)
      Deprecated.
      Sends the title directly to the defined players
      Parameters:
      players - the receivers of the title
    • broadcast

      public void broadcast()
      Deprecated.
      Sends the title directly to all online players
    • builder

      @NotNull public static @NotNull Title.Builder builder()
      Deprecated.