Ignore invalid names in player heads

This commit is contained in:
Nassim Jahnke 2024-04-26 09:29:19 +02:00
parent 676e62c71f
commit 8e63fd635b
No known key found for this signature in database
GPG Key ID: EF6771C01F6EF02F
1 changed files with 1 additions and 1 deletions

View File

@ -1440,7 +1440,7 @@ public final class BlockItemPacketRewriter1_20_5 extends ItemRewriter<Clientboun
tag.put("profile", profileTag);
final String name = skullOwnerTag.getString("Name");
if (name != null) {
if (name != null && name.length() <= 16 && name.indexOf(' ') == -1) { // Ignore invalid names
profileTag.putString("name", name);
}