Consider full team display name. Fixes BUKKIT-4186

Through a miscalculation, team display names were being created via
command ignoring the first word in the submitted display names.

By: mbax <github@phozop.net>
This commit is contained in:
Bukkit/Spigot 2013-05-04 14:19:19 -04:00
parent 1078240410
commit 1839404cbf

View File

@ -309,7 +309,7 @@ public class ScoreboardCommand extends VanillaCommand {
} else {
String displayName = null;
if (args.length > 3) {
displayName = StringUtils.join(ArrayUtils.subarray(args, 4, args.length), ' ');
displayName = StringUtils.join(ArrayUtils.subarray(args, 3, args.length), ' ');
if (displayName.length() > 32) {
sender.sendMessage(ChatColor.RED + "The display name '" + displayName + "' is too long for a team, it can be at most 32 characters long");
return false;