Builder

interface Builder

A builder for building teams.

Functions

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun addMember(member: Component): Team.Builder

Adds the given member to the team's list of members.

Link copied to clipboard
@Contract(value = "-> this", mutates = "this")
open fun allowFriendlyFire(): Team.Builder

Allows all team members to attack each other.

Link copied to clipboard
@Contract(value = "-> new", pure = true)
abstract fun buildAndRegister(): Team

Builds the team and adds it to the scoreboard.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun canSeeInvisibleMembers(value: Boolean): Team.Builder

Sets whether or not team members can see invisible team members.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun collisionRule(rule: CollisionRule): Team.Builder

Sets the collision rule for the team to the given rule.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun color(color: NamedTextColor): Team.Builder

Sets the team colour to the given color.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun deathMessageVisibility(visibility: Visibility): Team.Builder

Sets the death message visibility for the team to the given visibility.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun displayName(name: Component): Team.Builder

Sets the display name for the team to the given name.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun friendlyFire(value: Boolean): Team.Builder

Sets whether or not team members are allowed to attack each other.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun nameTagVisibility(visibility: Visibility): Team.Builder

Sets the name tag visibility for the team to the given visibility.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun prefix(prefix: Component): Team.Builder

Sets the prefix for the team to the given prefix.

Link copied to clipboard
@Contract(value = "-> this", mutates = "this")
open fun seeInvisibleMembers(): Team.Builder

Allows all team members to see invisible team members.

Link copied to clipboard
@Contract(value = "_ -> this", mutates = "this")
abstract fun suffix(suffix: Component): Team.Builder

Sets the suffix for the team to the given suffix.