-
-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Glowing changes the players nametag #10
Comments
Can you show me an example? |
The code looks like this: glow.clearGlowing(player)
team.players
.filter { it.uniqueId != player.uniqueId }
.filter { it.isOnline }
.map { it.player!! }
.filter { it.gameMode != GameMode.SPECTATOR }
.forEach {
val color = getColorTeamAsInt(getTeamId(team)!!)
val textColor = TextColor.color(color)
glow.setGlowing(it, player, NamedTextColor.nearestTo(textColor).toChatColor())
glow.setGlowing(player, it, NamedTextColor.nearestTo(textColor).toChatColor())
}
fun GlowingEntities.clearGlowing(entity: Entity) {
Bukkit.getOnlinePlayers().forEach {
unsetGlowing(entity, it)
if(entity is Player) unsetGlowing(it, entity);
}
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When I set a glow, it changes the player's nametag. How can I avoid this?
The text was updated successfully, but these errors were encountered: