Package kr.toxicity.model.api.nms
Interface ModelNametag
public interface ModelNametag
Represents a nametag associated with a model part.
Nametags are typically implemented as invisible armor stands or text displays that float above a specific bone.
- Since:
- 1.15.2
-
Method Summary
Modifier and TypeMethodDescriptionvoidalwaysVisible(boolean alwaysVisible) Sets whether the nametag should always be visible (even through blocks).voidcomponent(@Nullable net.kyori.adventure.text.Component component) Sets the text component of the nametag.voidremove(@NotNull PacketBundler bundler) Removes the nametag.voidsend(@NotNull PlatformPlayer player) Sends the nametag packet to a specific player.voidteleport(@NotNull PlatformLocation location) Teleports the nametag to a new location.
-
Method Details
-
alwaysVisible
void alwaysVisible(boolean alwaysVisible) Sets whether the nametag should always be visible (even through blocks).- Parameters:
alwaysVisible- true for always visible, false otherwise- Since:
- 1.15.2
-
component
void component(@Nullable @Nullable net.kyori.adventure.text.Component component) Sets the text component of the nametag.- Parameters:
component- the text component, or null to clear- Since:
- 1.15.2
-
teleport
Teleports the nametag to a new location.- Parameters:
location- the target location- Since:
- 1.15.2
-
send
Sends the nametag packet to a specific player.- Parameters:
player- the target player- Since:
- 1.15.2
-
remove
Removes the nametag.- Parameters:
bundler- the packet bundler to use- Since:
- 1.15.2
-