use of org.spongepowered.api.data.type.Career in project SpongeForge by SpongePowered.
the class MixinVillagerCareer method registerTrades.
private void registerTrades() {
Career career = SpongeForgeVillagerRegistry.fromNative((VillagerRegistry.VillagerCareer) (Object) this).get();
for (int i = 0; i < this.trades.size(); i++) {
int level = i + 1;
List<EntityVillager.ITradeList> trades = this.trades.get(i);
for (EntityVillager.ITradeList trade : trades) {
SpongeVillagerRegistry.getInstance().addMutator(career, level, (TradeOfferListMutator) trade);
}
}
}
Aggregations