1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-08-07 23:27:08 +02:00

Split colour permissions into 3: color/magic/format

This commit is contained in:
KHobbits
2012-03-22 22:07:13 +00:00
parent e7adb6c78b
commit 35b14d2b58
17 changed files with 93 additions and 61 deletions

View File

@@ -37,14 +37,7 @@ public class EssentialsChatPlayerListenerLowest extends EssentialsChatPlayer
/**
* This listener should apply the general chat formatting only...then return control back the event handler
*/
if (user.isAuthorized("essentials.chat.color"))
{
event.setMessage(Util.replaceColor(event.getMessage()));
}
else
{
event.setMessage(Util.stripColor(event.getMessage()));
}
event.setMessage(Util.formatString(user, "essentials.chat", event.getMessage()));
String group = user.getGroup();
String world = user.getWorld().getName();
event.setFormat(ess.getSettings().getChatFormat(group).format(new Object[] {group, world, world.substring(0, 1).toUpperCase(Locale.ENGLISH)}));