Disabling player list updates by default (can mess with tab completion)

Hopefully this will be reverted if/when patch is found.
This commit is contained in:
KHobbits 2012-03-23 00:15:22 +00:00
parent c5eb1bb105
commit 42d01471d3
4 changed files with 21 additions and 7 deletions

View File

@ -127,6 +127,8 @@ public interface ISettings extends IConf
boolean removeGodOnDisconnect();
boolean changeDisplayName();
boolean changePlayerListName();
boolean isPlayerCommand(String string);

View File

@ -609,6 +609,12 @@ public class Settings implements ISettings
{
return config.getBoolean("change-displayname", true);
}
@Override
public boolean changePlayerListName()
{
return config.getBoolean("change-playerlist", false);
}
@Override
public boolean useBukkitPermissions()

View File

@ -328,15 +328,18 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
{
name = Util.stripFormat(name);
}
try
if (ess.getSettings().changePlayerListName())
{
setPlayerListName(name);
}
catch (IllegalArgumentException e)
{
if (ess.getSettings().isDebug())
try
{
logger.log(Level.INFO, "Playerlist for " + name + " was not updated. Name clashed with another online player.");
setPlayerListName(name);
}
catch (IllegalArgumentException e)
{
if (ess.getSettings().isDebug())
{
logger.log(Level.INFO, "Playerlist for " + name + " was not updated. Name clashed with another online player.");
}
}
}
}

View File

@ -33,6 +33,9 @@ nickname-prefix: '~'
# Disable this if you have any other plugin, that modifies the displayname of a user.
change-displayname: true
# When this option is enabled, the (tab) player list will be updated with nicknames and colours.
#change-playerlist: true
# Adds the prefix and suffix to the displayname of the player, so it will be displayed in messages and lists.
# The prefix/suffix can be set using Permissions, Group Manager or PermissionsEx.
# The value of change-displayname (above) has to be true.