Use fancy name style for channel messages

This commit is contained in:
Ashcon Partovi 2018-05-21 20:31:22 -07:00
parent 44481e4b63
commit cec4d5f262
No known key found for this signature in database
GPG Key ID: 97468B9EF2123630
1 changed files with 5 additions and 1 deletions

View File

@ -11,6 +11,7 @@ import tc.oc.api.docs.Chat;
import tc.oc.api.docs.PlayerId;
import tc.oc.commons.bukkit.chat.Audiences;
import tc.oc.commons.bukkit.chat.ChatCreator;
import tc.oc.commons.bukkit.chat.NameStyle;
import tc.oc.commons.bukkit.chat.PlayerComponent;
import tc.oc.commons.bukkit.nick.IdentityProvider;
import tc.oc.commons.core.chat.Audience;
@ -65,7 +66,10 @@ public abstract class SimpleChannel implements MultiAudience, Channel, PluginFac
if(chatCache.getIfPresent(chat._id()) == null) {
chatCache.put(chat._id(), true);
sendMessage(format(
new PlayerComponent(identityProvider.currentOrConsoleIdentity(chat.sender())),
new PlayerComponent(
identityProvider.currentOrConsoleIdentity(chat.sender()),
NameStyle.FANCY
),
chat.message()
));
}