Class TabListEntry.Builder
java.lang.Object
com.velocitypowered.api.proxy.player.TabListEntry.Builder
- Enclosing interface:
- TabListEntry
Represents a builder which creates
TabListEntry
s.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
chatSession
(ChatSession chatSession) Sets theIdentifiedKey
of theTabListEntry
.displayName
(@Nullable Component displayName) Sets the displayed name of theTabListEntry
.gameMode
(int gameMode) Sets the game mode of theTabListEntry
.latency
(int latency) Sets the latency of theTabListEntry
.listed
(boolean listed) Sets wether this entry should be visible.profile
(GameProfile profile) Sets theGameProfile
of theTabListEntry
.
-
Method Details
-
tabList
Sets the parentTabList
for this entry, the entry will only be able to be added to that specificTabList
.- Parameters:
tabList
- to set- Returns:
this
, for chaining
-
profile
Sets theGameProfile
of theTabListEntry
.- Parameters:
profile
- to set- Returns:
this
, for chaining- See Also:
-
chatSession
Sets theIdentifiedKey
of theTabListEntry
.This only works for players currently not connected to this proxy.
For any player currently connected to this proxy this will be filled automatically.
Will ignore mismatching key revisions data.
- Parameters:
chatSession
- session to set- Returns:
this
, for chaining- See Also:
-
displayName
Sets the displayed name of theTabListEntry
.- Parameters:
displayName
- to set- Returns:
this
, for chaining- See Also:
-
latency
Sets the latency of theTabListEntry
.- Parameters:
latency
- to set- Returns:
this
, for chaining- See Also:
-
gameMode
Sets the game mode of theTabListEntry
.- Parameters:
gameMode
- to set- Returns:
this
, for chaining- See Also:
-
listed
Sets wether this entry should be visible.- Parameters:
listed
- to set- Returns:
- ${code this}, for chaining
- See Also:
-
build
- Returns:
- the constructed
TabListEntry
-