Lets break past the limits of mortal strings, it's not always 16 chars!

This commit is contained in:
libraryaddict 2020-04-07 21:31:47 +12:00
parent 1c0c5100c5
commit 5119358252
No known key found for this signature in database
GPG Key ID: 052E4FBCD257AEA4

View File

@ -222,8 +222,10 @@ public class PlayerDisguise extends TargetedDisguise {
return;
}
if (!DisguiseConfig.isExtendedDisguiseNames() && name.length() > 16) {
name = name.substring(0, 16);
int cLimit = DisguiseConfig.isExtendedDisguiseNames() ? 16 * 3 :
DisguiseConfig.isScoreboardDisguiseNames() ? 16 * 2 : 16;
if (!DisguiseConfig.isExtendedDisguiseNames() && name.length() > cLimit) {
name = name.substring(0, cLimit);
}
if (isDisguiseInUse()) {