Fix /npc villager --type

This commit is contained in:
fullwall 2019-07-13 21:42:57 +08:00
parent c7b59c84a7
commit 7a52682b87
1 changed files with 2 additions and 2 deletions

View File

@ -398,8 +398,8 @@ public class Commands {
throw new CommandException(Messages.INVALID_VILLAGER_TYPE,
Util.listValuesPretty(Villager.Type.values()));
}
trait.setLevel(args.getFlagInteger("type"));
output += Messaging.tr(Messages.VILLAGER_TYPE_SET, args.getFlagInteger("type"));
trait.setType(type);
output += Messaging.tr(Messages.VILLAGER_TYPE_SET, args.getFlag("type"));
}
if (args.hasValueFlag("profession")) {
Profession parsed = Util.matchEnum(Profession.values(), args.getFlag("profession"));