Adventure 4.3.0: Player list header/footer

This commit is contained in:
Riley Park
2020-12-06 17:50:57 -08:00
parent 9825f5891b
commit 5da085d82f
9 changed files with 89 additions and 33 deletions

View File

@@ -32,11 +32,12 @@ dependencies {
// DEPRECATED: Will be removed in Velocity 2.0.0
api 'com.moandjiezana.toml:toml4j:0.7.2'
api "net.kyori:adventure-api:${adventureVersion}"
api "net.kyori:adventure-text-serializer-gson:${adventureVersion}"
api "net.kyori:adventure-text-serializer-legacy:${adventureVersion}"
api "net.kyori:adventure-text-serializer-plain:${adventureVersion}"
api "net.kyori:adventure-text-serializer-legacy-text3:${adventurePlatformVersion}"
api(platform("net.kyori:adventure-bom:${adventureVersion}"))
api("net.kyori:adventure-api")
api("net.kyori:adventure-text-serializer-gson")
api("net.kyori:adventure-text-serializer-legacy")
api("net.kyori:adventure-text-serializer-plain")
api("net.kyori:adventure-text-serializer-legacy-text3:${adventurePlatformVersion}") // adventure-platform
api "org.slf4j:slf4j-api:${slf4jVersion}"
api 'com.google.inject:guice:4.2.3'

View File

@@ -146,6 +146,20 @@ public interface Player extends CommandSource, Identified, InboundConnection,
@Deprecated
void clearHeaderAndFooter();
/**
* Returns the player's player list header.
*
* @return this player's player list header
*/
Component getPlayerListHeader();
/**
* Returns the player's player list footer.
*
* @return this player's tab list
*/
Component getPlayerListFooter();
/**
* Returns the player's tab list.
*

View File

@@ -28,7 +28,9 @@ public interface TabList {
*
* @param header the header component
* @param footer the footer component
* @deprecated Use {@link Player#sendPlayerListHeaderAndFooter(Component, Component)} instead
*/
@Deprecated
void setHeaderAndFooter(Component header, Component footer);
/**