Posted August 7, 20232 yr Wrong forum, sorry for the trouble. Im trying to change some of the librarian, armorer, toolsmith and weaponsmith vanilla trades in order to avoid a source of infinite diamond gear, avoid the workstation rerolling for enchanted books and make enchanted books expencier. Here is what im doing. //level 4 clear ----------------------------------------------------------------------- if (event.getType() == VillagerProfession.ARMORER) { Int2ObjectMap<List<VillagerTrades.ItemListing>> trades = event.getTrades(); int villagerLevel = 4; trades.get(villagerLevel).clear(); } //level 4 add trade ---------------------------------------------------------------------- if (event.getType() == VillagerProfession.ARMORER) { Int2ObjectMap<List<VillagerTrades.ItemListing>> trades = event.getTrades(); ItemStack stack = new ItemStack(Items.DIAMOND_LEGGINGS, 1); int villagerLevel = 4; trades.get(villagerLevel).add((pTrader, pRandom) -> new MerchantOffer( new ItemStack(Items.EMERALD, 19), new ItemStack(Items.DIAMOND, 5), stack, 3, 50, 0.4f)); } The problem is i couldn't figure out how to enchant the output item in the merchant recipe. Here some examples of the goal (without the enchantments). Edited August 7, 20232 yr by Farck make topic in the wrong forum
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.