From 740fac23baf1d2d613df8c97b937d6b0e4271a57 Mon Sep 17 00:00:00 2001 From: libraryaddict Date: Fri, 24 Apr 2020 19:34:37 +1200 Subject: [PATCH] Call setName() instead of setting name directly --- .../libraryaddict/disguise/disguisetypes/PlayerDisguise.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/me/libraryaddict/disguise/disguisetypes/PlayerDisguise.java b/src/main/java/me/libraryaddict/disguise/disguisetypes/PlayerDisguise.java index 6163f0cd..4c546407 100644 --- a/src/main/java/me/libraryaddict/disguise/disguisetypes/PlayerDisguise.java +++ b/src/main/java/me/libraryaddict/disguise/disguisetypes/PlayerDisguise.java @@ -80,6 +80,7 @@ public class PlayerDisguise extends TargetedDisguise { createDisguise(); } + @Deprecated public DisguiseUtilities.DScoreTeam getScoreboardName() { if (getName().length() <= 32 ? !DisguiseConfig.isScoreboardDisguiseNames() : !DisguiseConfig.isExtendedDisguiseNames()) { @@ -162,8 +163,6 @@ public class PlayerDisguise extends TargetedDisguise { public PlayerDisguise clone() { PlayerDisguise disguise = new PlayerDisguise(); - disguise.playerName = getName(); - if (currentLookup == null && gameProfile != null) { disguise.skinToUse = getSkin(); disguise.gameProfile = ReflectionManager @@ -172,6 +171,7 @@ public class PlayerDisguise extends TargetedDisguise { disguise.setSkin(getSkin()); } + disguise.setName(getName()); disguise.setNameVisible(isNameVisible()); disguise.setDynamicName(isDynamicName());