Merge pull request #3677 from bmiddle/dev
[Chat Color] Add ability to change public chat friend name color in config
This commit is contained in:
@@ -123,9 +123,19 @@ public class ChatMessageManager
|
||||
case AUTOCHAT:
|
||||
case PUBLIC:
|
||||
case PUBLIC_MOD:
|
||||
usernameColor = isChatboxTransparent ? chatColorConfig.transparentUsername() : chatColorConfig.opaqueUsername();
|
||||
break;
|
||||
{
|
||||
boolean isFriend = client.isFriended(setMessage.getName(), true) && !client.getLocalPlayer().getName().equals(setMessage.getName());
|
||||
|
||||
if (isFriend)
|
||||
{
|
||||
usernameColor = isChatboxTransparent ? chatColorConfig.transparentPublicFriendUsernames() : chatColorConfig.opaquePublicFriendUsernames();
|
||||
}
|
||||
if (usernameColor == null)
|
||||
{
|
||||
usernameColor = isChatboxTransparent ? chatColorConfig.transparentUsername() : chatColorConfig.opaqueUsername();
|
||||
}
|
||||
break;
|
||||
}
|
||||
case CLANCHAT:
|
||||
usernameColor = isChatboxTransparent ? chatColorConfig.transparentClanUsernames() : chatColorConfig.opaqueClanUsernames();
|
||||
break;
|
||||
|
||||
@@ -262,6 +262,14 @@ public interface ChatColorConfig extends Config
|
||||
)
|
||||
Color opaqueClanUsernames();
|
||||
|
||||
@ConfigItem(
|
||||
position = 57,
|
||||
keyName = "opaquePublicFriendUsernames",
|
||||
name = "Public friend usernames",
|
||||
description = "Color of Friend Usernames in Public Chat"
|
||||
)
|
||||
Color opaquePublicFriendUsernames();
|
||||
|
||||
@ConfigItem(
|
||||
position = 61,
|
||||
keyName = "transparentPublicChat",
|
||||
@@ -490,4 +498,12 @@ public interface ChatColorConfig extends Config
|
||||
description = "Color of Usernames in Clan Chat (transparent)"
|
||||
)
|
||||
Color transparentClanUsernames();
|
||||
|
||||
@ConfigItem(
|
||||
position = 87,
|
||||
keyName = "transparentPublicFriendUsernames",
|
||||
name = "Public friend usernames (transparent)",
|
||||
description = "Color of Friend Usernames in Public Chat (transparent)"
|
||||
)
|
||||
Color transparentPublicFriendUsernames();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user