Interface DisplaySlot
-
- All Superinterfaces:
DefaultedRegistryValue
@CatalogedBy(DisplaySlots.class) public interface DisplaySlot extends DefaultedRegistryValue
Represents an area to display an objective.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
DisplaySlot.Factory
Used to supportDisplaySlot.Factory.findByTeamColor(NamedTextColor)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description static Optional<DisplaySlot>
findByTeamColor(NamedTextColor color)
Finds and retrieves the sidebar display slot for the specifiedNamedTextColor
associated with aTeam
, if one exists.Optional<NamedTextColor>
teamColor()
Gets theTeam
color that this objective will display.-
Methods inherited from interface org.spongepowered.api.registry.DefaultedRegistryValue
asDefaultedReference, findKey, key
-
-
-
-
Method Detail
-
findByTeamColor
static Optional<DisplaySlot> findByTeamColor(NamedTextColor color)
Finds and retrieves the sidebar display slot for the specifiedNamedTextColor
associated with aTeam
, if one exists.- Parameters:
color
- TheNamedTextColor
- Returns:
- The slot, if one was found
-
teamColor
Optional<NamedTextColor> teamColor()
Gets theTeam
color that this objective will display.- Returns:
- The team color or
Optional.empty()
if not set
-
-