Package net.kyori.adventure.audience
Interface ForwardingAudience.Single
- All Superinterfaces:
Audience,ForwardingAudience
- Enclosing interface:
- ForwardingAudience
public static interface ForwardingAudience.Single extends ForwardingAudience
An audience that forwards everything to a single other audience.
- Since:
- 4.0.0
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.kyori.adventure.audience.ForwardingAudience
ForwardingAudience.Single -
Method Summary
Modifier and Type Method Description @NonNull Audienceaudience()Gets the audience.default @NonNull Iterable<? extends Audience>audiences()Deprecated.this audience only supports forwarding to a single audiencedefault voidclearTitle()Clears the title, if one is being displayed.default voidhideBossBar(@NonNull BossBar bar)Hides a boss bar.default voidopenBook(@NonNull Book book)Opens a book.default voidplaySound(@NonNull Sound sound)Plays a sound.default voidplaySound(@NonNull Sound sound, double x, double y, double z)Plays a sound at a location.default voidresetTitle()Resets the title and timings back to their default.default voidsendActionBar(@NonNull Component message)Sends a message on the action bar.default voidsendMessage(@NonNull Identified source, @NonNull Component message, @NonNull MessageType type)Sends a chat message.default voidsendMessage(@NonNull Identity source, @NonNull Component message, @NonNull MessageType type)Sends a chat message.default voidshowBossBar(@NonNull BossBar bar)Shows a boss bar.default voidshowTitle(@NonNull Title title)Shows a title.default voidstopSound(@NonNull SoundStop stop)Stops a sound, or many sounds.Methods inherited from interface net.kyori.adventure.audience.Audience
openBook, sendActionBar, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage
-
Method Details
-
audience
@NonNull Audience audience()Gets the audience.- Returns:
- the audience
- Since:
- 4.0.0
-
audiences
Deprecated.this audience only supports forwarding to a single audienceGets the audiences.- Specified by:
audiencesin interfaceForwardingAudience- Returns:
audience()
-
sendMessage
default void sendMessage(@NonNull Identified source, @NonNull Component message, @NonNull MessageType type)Description copied from interface:AudienceSends a chat message.- Specified by:
sendMessagein interfaceAudience- Specified by:
sendMessagein interfaceForwardingAudience- Parameters:
source- the source of the messagemessage- a messagetype- the type- See Also:
Component
-
sendMessage
default void sendMessage(@NonNull Identity source, @NonNull Component message, @NonNull MessageType type)Description copied from interface:AudienceSends a chat message.- Specified by:
sendMessagein interfaceAudience- Specified by:
sendMessagein interfaceForwardingAudience- Parameters:
source- the identity of the source of the messagemessage- a messagetype- the type- See Also:
Component
-
sendActionBar
Description copied from interface:AudienceSends a message on the action bar.- Specified by:
sendActionBarin interfaceAudience- Specified by:
sendActionBarin interfaceForwardingAudience- Parameters:
message- a message- See Also:
Component
-
showTitle
Description copied from interface:AudienceShows a title.- Specified by:
showTitlein interfaceAudience- Specified by:
showTitlein interfaceForwardingAudience- Parameters:
title- a title- See Also:
Title
-
clearTitle
default void clearTitle()Description copied from interface:AudienceClears the title, if one is being displayed.- Specified by:
clearTitlein interfaceAudience- Specified by:
clearTitlein interfaceForwardingAudience- See Also:
Title
-
resetTitle
default void resetTitle()Description copied from interface:AudienceResets the title and timings back to their default.- Specified by:
resetTitlein interfaceAudience- Specified by:
resetTitlein interfaceForwardingAudience- See Also:
Title
-
showBossBar
Description copied from interface:AudienceShows a boss bar.- Specified by:
showBossBarin interfaceAudience- Specified by:
showBossBarin interfaceForwardingAudience- Parameters:
bar- a boss bar- See Also:
BossBar
-
hideBossBar
Description copied from interface:AudienceHides a boss bar.- Specified by:
hideBossBarin interfaceAudience- Specified by:
hideBossBarin interfaceForwardingAudience- Parameters:
bar- a boss bar- See Also:
BossBar
-
playSound
Description copied from interface:AudiencePlays a sound.- Specified by:
playSoundin interfaceAudience- Specified by:
playSoundin interfaceForwardingAudience- Parameters:
sound- a sound- See Also:
Sound
-
playSound
Description copied from interface:AudiencePlays a sound at a location.- Specified by:
playSoundin interfaceAudience- Specified by:
playSoundin interfaceForwardingAudience- Parameters:
sound- a soundx- x coordinatey- y coordinatez- z coordinate- See Also:
Sound
-
stopSound
Description copied from interface:AudienceStops a sound, or many sounds.- Specified by:
stopSoundin interfaceAudience- Specified by:
stopSoundin interfaceForwardingAudience- Parameters:
stop- a sound stop- See Also:
SoundStop
-
openBook
Description copied from interface:AudienceOpens a book.When possible, no item should persist after closing the book.
- Specified by:
openBookin interfaceAudience- Specified by:
openBookin interfaceForwardingAudience- Parameters:
book- a book- See Also:
Book
-