Call setName() instead of setting name directly

This commit is contained in:
libraryaddict 2020-04-24 19:34:37 +12:00
parent a63e617b0a
commit 740fac23ba
No known key found for this signature in database
GPG Key ID: 052E4FBCD257AEA4

View File

@ -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());