Class FancyAdvancementDisplay.Builder
java.lang.Object
com.fren_gor.ultimateAdvancementAPI.advancement.display.AdvancementDisplayBuilder<FancyAdvancementDisplay.Builder,FancyAdvancementDisplay>
com.fren_gor.ultimateAdvancementAPI.advancement.display.FancyAdvancementDisplay.Builder
- Enclosing class:
FancyAdvancementDisplay
public static class FancyAdvancementDisplay.Builder
extends AdvancementDisplayBuilder<FancyAdvancementDisplay.Builder,FancyAdvancementDisplay>
A builder for
FancyAdvancementDisplay
.- Since:
- 2.1.0
-
Field Summary
Modifier and TypeFieldDescriptionprotected ChatColor
The default color of the description.protected ChatColor
The default color of the title.Fields inherited from class com.fren_gor.ultimateAdvancementAPI.advancement.display.AdvancementDisplayBuilder
announceChat, description, frame, icon, showToast, title, x, y
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the advancement display.descriptionColor
(@NotNull ChatColor descriptionColor) Sets the default color of the description.Gets the default color of the description.Gets the default color of the title.titleColor
(@NotNull ChatColor titleColor) Sets the default color of the title.Methods inherited from class com.fren_gor.ultimateAdvancementAPI.advancement.display.AdvancementDisplayBuilder
announceChat, announceChat, challengeFrame, coords, coords, description, description, doesAnnounceToChat, doesShowToast, frame, getDescription, getFrame, getIcon, getTitle, getX, getY, goalFrame, showToast, showToast, taskFrame, x, y
-
Field Details
-
defaultTitleColor
The default color of the title. -
defaultDescriptionColor
The default color of the description.
-
-
Constructor Details
-
Builder
Creates a newFancyAdvancementDisplay.Builder
.By default, the fancy advancement display returned by
build()
won't show both the toast message and the announcement message in the chat upon advancement completion.The default
frame
isAdvancementFrameType.TASK
.- Parameters:
icon
- The material of the advancement's icon in the advancement GUI.title
- The title of the advancement.
-
Builder
Creates a newFancyAdvancementDisplay.Builder
.By default, the fancy advancement display returned by
build()
won't show both the toast message and the announcement message in the chat upon advancement completion.The default
frame
isAdvancementFrameType.TASK
.- Parameters:
icon
- The advancement's icon in the advancement GUI.title
- The title of the advancement.
-
-
Method Details
-
titleColor
@NotNull public @NotNull FancyAdvancementDisplay.Builder titleColor(@NotNull @NotNull ChatColor titleColor) Sets the default color of the title.- Parameters:
titleColor
- The default color of the title.- Returns:
- This builder.
-
descriptionColor
@NotNull public @NotNull FancyAdvancementDisplay.Builder descriptionColor(@NotNull @NotNull ChatColor descriptionColor) Sets the default color of the description.- Parameters:
descriptionColor
- The default color of the description.- Returns:
- This builder.
-
build
Builds the advancement display.- Specified by:
build
in classAdvancementDisplayBuilder<FancyAdvancementDisplay.Builder,
FancyAdvancementDisplay> - Returns:
- The built advancement display.
-
getDefaultTitleColor
Gets the default color of the title.- Returns:
- The default color of the title.
-
getDefaultDescriptionColor
Gets the default color of the description.- Returns:
- The default color of the description.
-