public interface Team
scoreboard
.Modifier and Type | Method and Description |
---|---|
void |
addEntry(String entry)
This puts the specified entry onto this team for the scoreboard.
|
void |
addPlayer(OfflinePlayer player)
Deprecated.
Teams can contain entries that aren't players
|
boolean |
allowFriendlyFire()
Gets the team friendly fire state
|
boolean |
canSeeFriendlyInvisibles()
Gets the team's ability to see
invisible teammates. |
String |
getDisplayName()
Gets the name displayed to entries for this team
|
Set<String> |
getEntries()
Gets the Set of entries on the team
|
String |
getName()
Gets the name of this Team
|
NameTagVisibility |
getNameTagVisibility()
Gets the team's ability to see name tags
|
Set<OfflinePlayer> |
getPlayers()
Deprecated.
Teams can contain entries that aren't players
|
String |
getPrefix()
Gets the prefix prepended to the display of entries on this team.
|
Scoreboard |
getScoreboard()
Gets the Scoreboard to which this team is attached
|
int |
getSize()
Gets the size of the team
|
String |
getSuffix()
Gets the suffix appended to the display of entries on this team.
|
boolean |
hasEntry(String entry)
Checks to see if the specified entry is a member of this team.
|
boolean |
hasPlayer(OfflinePlayer player)
Deprecated.
Teams can contain entries that aren't players
|
boolean |
removeEntry(String entry)
Removes the entry from this team.
|
boolean |
removePlayer(OfflinePlayer player)
Deprecated.
Teams can contain entries that aren't players
|
void |
setAllowFriendlyFire(boolean enabled)
Sets the team friendly fire state
|
void |
setCanSeeFriendlyInvisibles(boolean enabled)
Sets the team's ability to see
invisible teammates. |
void |
setDisplayName(String displayName)
Sets the name displayed to entries for this team
|
void |
setNameTagVisibility(NameTagVisibility visibility)
Set's the team's ability to see name tags
|
void |
setPrefix(String prefix)
Sets the prefix prepended to the display of entries on this team.
|
void |
setSuffix(String suffix)
Sets the suffix appended to the display of entries on this team.
|
void |
unregister()
Unregisters this team from the Scoreboard
|
String getName() throws IllegalStateException
IllegalStateException
- if this team has been unregisteredString getDisplayName() throws IllegalStateException
IllegalStateException
- if this team has been unregisteredvoid setDisplayName(String displayName) throws IllegalStateException, IllegalArgumentException
displayName
- New display nameIllegalArgumentException
- if displayName is longer than 32
characters.IllegalStateException
- if this team has been unregisteredString getPrefix() throws IllegalStateException
IllegalStateException
- if this team has been unregisteredvoid setPrefix(String prefix) throws IllegalStateException, IllegalArgumentException
prefix
- New prefixIllegalArgumentException
- if prefix is nullIllegalArgumentException
- if prefix is longer than 16
charactersIllegalStateException
- if this team has been unregisteredString getSuffix() throws IllegalStateException
IllegalStateException
- if this team has been unregisteredvoid setSuffix(String suffix) throws IllegalStateException, IllegalArgumentException
suffix
- the new suffix for this team.IllegalArgumentException
- if suffix is nullIllegalArgumentException
- if suffix is longer than 16
charactersIllegalStateException
- if this team has been unregisteredboolean allowFriendlyFire() throws IllegalStateException
IllegalStateException
- if this team has been unregisteredvoid setAllowFriendlyFire(boolean enabled) throws IllegalStateException
enabled
- true if friendly fire is to be allowedIllegalStateException
- if this team has been unregisteredboolean canSeeFriendlyInvisibles() throws IllegalStateException
invisible
teammates.IllegalStateException
- if this team has been unregisteredvoid setCanSeeFriendlyInvisibles(boolean enabled) throws IllegalStateException
invisible
teammates.enabled
- true if invisible teammates are to be visibleIllegalStateException
- if this team has been unregisteredNameTagVisibility getNameTagVisibility() throws IllegalArgumentException
IllegalArgumentException
- if this team has been unregisteredvoid setNameTagVisibility(NameTagVisibility visibility) throws IllegalArgumentException
visibility
- The nameTagVisibilty to setIllegalArgumentException
- if this team has been unregistered@Deprecated Set<OfflinePlayer> getPlayers() throws IllegalStateException
IllegalStateException
- if this team has been unregistered\getEntries()
Set<String> getEntries() throws IllegalStateException
IllegalStateException
- if this entries has been unregistered\int getSize() throws IllegalStateException
IllegalStateException
- if this team has been unregisteredScoreboard getScoreboard()
unregistered
@Deprecated void addPlayer(OfflinePlayer player) throws IllegalStateException, IllegalArgumentException
This will remove the player from any other team on the scoreboard.
player
- the player to addIllegalArgumentException
- if player is nullIllegalStateException
- if this team has been unregisteredaddEntry(String)
void addEntry(String entry) throws IllegalStateException, IllegalArgumentException
This will remove the entry from any other team on the scoreboard.
entry
- the entry to addIllegalArgumentException
- if entry is nullIllegalStateException
- if this team has been unregistered@Deprecated boolean removePlayer(OfflinePlayer player) throws IllegalStateException, IllegalArgumentException
player
- the player to removeIllegalArgumentException
- if player is nullIllegalStateException
- if this team has been unregisteredremoveEntry(String)
boolean removeEntry(String entry) throws IllegalStateException, IllegalArgumentException
entry
- the entry to removeIllegalArgumentException
- if entry is nullIllegalStateException
- if this team has been unregisteredvoid unregister() throws IllegalStateException
IllegalStateException
- if this team has been unregistered@Deprecated boolean hasPlayer(OfflinePlayer player) throws IllegalArgumentException, IllegalStateException
player
- the player to search forIllegalArgumentException
- if player is nullIllegalStateException
- if this team has been unregisteredhasEntry(String)
boolean hasEntry(String entry) throws IllegalArgumentException, IllegalStateException
entry
- the entry to search forIllegalArgumentException
- if entry is nullIllegalStateException
- if this team has been unregisteredCopyright © 2015. All rights reserved.