mirror of
https://github.com/TotalFreedomMC/TF-LibsDisguises.git
synced 2025-02-14 04:38:11 +00:00
The name to fetch is either the skin or the name. Not both
This commit is contained in:
parent
837de50833
commit
3173ceec77
1 changed files with 3 additions and 2 deletions
|
@ -218,12 +218,13 @@ public class PacketsManager {
|
|||
}
|
||||
} else {
|
||||
WrappedGameProfile gameProfile;
|
||||
String name = ((PlayerDisguise) disguise).getName();
|
||||
PlayerDisguise playerDisguise = (PlayerDisguise) disguise;
|
||||
String name = playerDisguise.getSkin() != null ? playerDisguise.getSkin() : playerDisguise.getName();
|
||||
boolean removeName = false;
|
||||
if (!DisguiseUtilities.hasGameProfile(name)) {
|
||||
removeName = !DisguiseUtilities.getAddedByPlugins().contains(name);
|
||||
}
|
||||
gameProfile = ((PlayerDisguise) disguise).getGameProfile();
|
||||
gameProfile = playerDisguise.getGameProfile();
|
||||
if (removeName) {
|
||||
DisguiseUtilities.getAddedByPlugins().remove(name);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue