mirror of
https://github.com/essentials/Essentials.git
synced 2025-02-25 17:02:48 +01:00
Don't change color of op if setting is set to none.
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1410 e251c2fe-e539-e718-e476-b85c1f46cddb
This commit is contained in:
parent
a28e08e3eb
commit
402b26531d
@ -150,14 +150,14 @@ public class Settings implements IConf
|
|||||||
return kits.get(name.replace('.', '_').replace('/', '_'));
|
return kits.get(name.replace('.', '_').replace('/', '_'));
|
||||||
}
|
}
|
||||||
|
|
||||||
public ChatColor getOperatorColor()
|
public ChatColor getOperatorColor() throws Exception
|
||||||
{
|
{
|
||||||
String colorName = config.getString("ops-name-color", null);
|
String colorName = config.getString("ops-name-color", null);
|
||||||
|
|
||||||
if (colorName == null)
|
if (colorName == null)
|
||||||
return ChatColor.RED;
|
return ChatColor.RED;
|
||||||
if("none".equalsIgnoreCase(colorName) || colorName.isEmpty())
|
if("none".equalsIgnoreCase(colorName) || colorName.isEmpty())
|
||||||
return ChatColor.WHITE;
|
throw new Exception();
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
@ -244,7 +244,13 @@ public class User extends UserData implements Comparable<User>, IReplyTo
|
|||||||
}
|
}
|
||||||
if (isOp())
|
if (isOp())
|
||||||
{
|
{
|
||||||
nickname = ess.getSettings().getOperatorColor().toString() + nickname + "§f";
|
try
|
||||||
|
{
|
||||||
|
nickname = ess.getSettings().getOperatorColor().toString() + nickname + "§f";
|
||||||
|
}
|
||||||
|
catch(Exception e)
|
||||||
|
{
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return nickname;
|
return nickname;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user