Class RegisterVillagerTrades
java.lang.Object
net.darkhax.bookshelf.common.api.registry.register.RegisterVillagerTrades
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCommonWanderingTrade(net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a trade to the wandering traders common trade pool.voidaddRareWanderingTrade(net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a trade to the wandering traders rare trades pool.voidaddTrade(net.minecraft.world.entity.npc.VillagerProfession profession, int tier, net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a new trade listing to a specific profession that may become available when the specified profession tier is reached.voidaddTrade(net.minecraft.world.entity.npc.VillagerProfession profession, MerchantTier tier, net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a new trade listing to a specific profession that may become available when the specified profession tier is reached.voidaddWanderingTrade(net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade, boolean isRare) Adds a trade to the wandering villager trade pool.List<net.minecraft.world.entity.npc.VillagerTrades.ItemListing> List<net.minecraft.world.entity.npc.VillagerTrades.ItemListing> Map<net.minecraft.world.entity.npc.VillagerProfession, com.google.common.collect.Multimap<Integer, net.minecraft.world.entity.npc.VillagerTrades.ItemListing>>
-
Constructor Details
-
RegisterVillagerTrades
public RegisterVillagerTrades()
-
-
Method Details
-
addTrade
public void addTrade(net.minecraft.world.entity.npc.VillagerProfession profession, int tier, net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a new trade listing to a specific profession that may become available when the specified profession tier is reached.- Parameters:
profession- The profession to register the trade to.tier- The tier at which this trade can become available.trade- The trade listing to add.
-
addTrade
public void addTrade(net.minecraft.world.entity.npc.VillagerProfession profession, MerchantTier tier, net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a new trade listing to a specific profession that may become available when the specified profession tier is reached.- Parameters:
profession- The profession to register the trade to.tier- The tier at which this trade can become available.trade- The trade listing to add.
-
addWanderingTrade
public void addWanderingTrade(net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade, boolean isRare) Adds a trade to the wandering villager trade pool.- Parameters:
trade- The trade to add.isRare- If the trade belongs in the rare or common pool.
-
addRareWanderingTrade
public void addRareWanderingTrade(net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a trade to the wandering traders rare trades pool.- Parameters:
trade- The trade to add.
-
addCommonWanderingTrade
public void addCommonWanderingTrade(net.minecraft.world.entity.npc.VillagerTrades.ItemListing trade) Adds a trade to the wandering traders common trade pool.- Parameters:
trade- The trade to add.
-
getVillagerTrades
-
getRareWanderingTrades
-
getCommonWanderingTrades
-