broadcastFormattedTitle

open fun broadcastFormattedTitle(title: String = "", subtitle: String = "", predicate: Predicate<P>)

Broadcasts a formatted title and subtitle to all players satisfying the given predicate.

This method sends a formatted title and subtitle to players that meet the condition specified by the provided predicate.

Parameters

title

The main title to be displayed to the players. Defaults to an empty string.

subtitle

The subtitle to be displayed under the main title. Defaults to an empty string.

predicate

A filter function determining the players who should receive the formatted title.


open fun broadcastFormattedTitle(title: String = "", subtitle: String = "", fadeIn: @Range(from = 0, to = 72000) Int, stay: @Range(from = 0, to = 72000) Int, fadeOut: @Range(from = 0, to = 72000) Int, predicate: Predicate<P> = Predicate { true })

Broadcasts a formatted title to all eligible recipients.

Parameters

title

The main title text to display. Defaults to an empty string if not provided.

subtitle

The subtitle text to display below the title. Defaults to an empty string if not provided.

fadeIn

The duration (in ticks) for the fade-in animation of the title. Must be between 0 and 72,000 inclusive.

stay

The duration (in ticks) for which the title should remain visible