本文整理汇总了Java中net.minecraft.entity.passive.EntityVillager.PriceInfo类的典型用法代码示例。如果您正苦于以下问题:Java PriceInfo类的具体用法?Java PriceInfo怎么用?Java PriceInfo使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
PriceInfo类属于net.minecraft.entity.passive.EntityVillager包,在下文中一共展示了PriceInfo类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: init
import net.minecraft.entity.passive.EntityVillager.PriceInfo; //导入依赖的package包/类
public static void init() {
mechanicProfession = new VillagerProfession(Names.MOD_ID + ":mechanic",
Textures.VILLAGER_MECHANIC, "minecraft:textures/entity/zombie_villager/zombie_villager.png");
VillagerCareer career = new VillagerCareer(mechanicProfession, Names.MOD_ID + ".mechanic");
career.addTrade(1,
new ListItemForEmeralds(Itemss.PCB_BLUEPRINT, new PriceInfo(10, 19)),
new ListItemForEmeralds(Itemss.NUKE_VIRUS, new PriceInfo(1, 5)),
new ListItemForEmeralds(Itemss.STOP_WORM, new PriceInfo(1, 5))
);
for (int i = 0; i < ItemAssemblyProgram.PROGRAMS_AMOUNT; i++) {
career.addTrade(1,
new ListItemForEmeralds(new ItemStack(Itemss.ASSEMBLY_PROGRAM, 1, i), new PriceInfo(5, 11)));
}
}
开发者ID:TeamPneumatic,项目名称:pnc-repressurized,代码行数:15,代码来源:VillagerHandler.java
示例2: buildDruidTrades
import net.minecraft.entity.passive.EntityVillager.PriceInfo; //导入依赖的package包/类
private EntityVillager.ITradeList[][] buildDruidTrades() {
return new EntityVillager.ITradeList[][] {
{
new EmeraldForItems(Items.COOKED_FISH, new PriceInfo(9, 12)), // GROUP 1
new EmeraldForItems(Items.APPLE, new PriceInfo(3, 6)),
new EmeraldForItems(Items.BEETROOT, new PriceInfo(8, 12))
}, {
new EmeraldForItems(Items.FEATHER, new PriceInfo(12, 13)), //GROUP 2
new EmeraldForItems(Items.WHEAT_SEEDS, new PriceInfo(50, 64)),
new EmeraldForItems(Items.POISONOUS_POTATO, new PriceInfo(1, 3))
}, {
new EmeraldForItems(Item.getItemFromBlock(Blocks.BROWN_MUSHROOM), new PriceInfo(8, 12)), //GROUP 3
new EmeraldForItems(Item.getItemFromBlock(Blocks.RED_MUSHROOM), new PriceInfo(8, 12))
}, {
new EmeraldForItems(Items.BEEF, new PriceInfo(14, 17)), //GROUP 4
new EmeraldForItems(Items.RABBIT, new PriceInfo(14, 17)),
new EmeraldForItems(Items.CHICKEN, new PriceInfo(14, 17))
}, {
new EmeraldForItems(Items.WRITTEN_BOOK, new PriceInfo(1, 1)), //GROUP 5
new EmeraldForItems(Items.FISH, new PriceInfo(9, 12)),
new EmeraldForItems(Items.SPIDER_EYE, new PriceInfo(3, 6))
}, {
new ListItemForEmeraldsFixed(new ItemStack(Blocks.GRASS, 32), new PriceInfo(1, 2)), //GROUP 6
new ListItemForEmeraldsFixed(new ItemStack(Blocks.FARMLAND, 32), new PriceInfo(1, 2)),
new ListItemForEmeraldsFixed(new ItemStack(Blocks.DIRT, 32, BlockDirt.DirtType.PODZOL.getMetadata()), new PriceInfo(1, 2)),
new ListItemForEmeraldsFixed(new ItemStack(Blocks.GRASS_PATH, 32), new PriceInfo(1, 2))
}, {
new ListItemForEmeraldsFixed(new ItemStack(Blocks.MYCELIUM, 1), new PriceInfo(12, 16)), //GROUP 7
new ListItemForEmeraldsFixed(new ItemStack(Blocks.WATERLILY, 32), new PriceInfo(1, 2)),
new ListItemForEmeraldsFixed(new ItemStack(Blocks.SAND, 32, BlockSand.EnumType.RED_SAND.ordinal()), new PriceInfo(1, 3)),
new ListItemForEmeraldsFixed(new ItemStack(Items.DYE, 16, EnumDyeColor.BLACK.getDyeDamage()), new PriceInfo(1, 3)) }
};
}
开发者ID:PrinceOfAmber,项目名称:Cyclic,代码行数:34,代码来源:VillagerCreateModule.java
示例3: buildSageTrades
import net.minecraft.entity.passive.EntityVillager.PriceInfo; //导入依赖的package包/类
private EntityVillager.ITradeList[][] buildSageTrades() {
return new EntityVillager.ITradeList[][] {
{
new EmeraldForItems(Items.GUNPOWDER, new PriceInfo(5, 8)), //GROUP 1
new EmeraldForItems(Items.NETHER_WART, new PriceInfo(12, 16))
}, {
new EmeraldForItems(Items.BONE, new PriceInfo(8, 16)), //GROUP 2
new EmeraldForItems(Items.MUTTON, new PriceInfo(4, 12))
}, {
new EmeraldForItems(Items.BLAZE_ROD, new PriceInfo(8, 16)), //GROUP 3
new EmeraldForItems(Items.SLIME_BALL, new PriceInfo(8, 16))
}, {
new EmeraldForItems(Items.GHAST_TEAR, new PriceInfo(1, 2)), //GROUP 4
new EmeraldForItems(Items.REDSTONE, new PriceInfo(4, 6))
}, {
new EmeraldForItems(Items.GLOWSTONE_DUST, new PriceInfo(6, 8)), //GROUP 5
new EmeraldForItems(Items.DIAMOND, new PriceInfo(8, 12)),
new EmeraldForItems(Items.ENDER_PEARL, new PriceInfo(12, 16))
}, {
new ListItemForEmeraldsFixed(new ItemStack(Items.EXPERIENCE_BOTTLE, 8), new PriceInfo(1, 4)), //GROUP 6
new ListItemForEmeraldsFixed(new ItemStack(Blocks.CLAY, 16), new PriceInfo(1, 1)),
}, {
new ListItemForEmeraldsFixed(new ItemStack(Blocks.QUARTZ_BLOCK, 16), new PriceInfo(2, 4)), //GROUP 7
new ListItemForEmeraldsFixed(new ItemStack(Blocks.OBSIDIAN, 16), new PriceInfo(2, 4)),
new ListItemForEmeraldsFixed(new ItemStack(Items.FISH, 4, ItemFishFood.FishType.PUFFERFISH.getMetadata()), new PriceInfo(1, 2)),
}
};
}
开发者ID:PrinceOfAmber,项目名称:Cyclic,代码行数:29,代码来源:VillagerCreateModule.java
示例4: registerUselessVillager
import net.minecraft.entity.passive.EntityVillager.PriceInfo; //导入依赖的package包/类
public static void registerUselessVillager() {
final VillagerProfession prof = new VillagerProfession(
"openblocks:radio",
"openblocks:textures/models/king-ish.png",
"minecraft:textures/entity/zombie_villager/zombie_villager.png"); // TODO: zombie texture?
GameRegistry.findRegistry(VillagerProfession.class).register(prof);
final VillagerCareer career = new VillagerCareer(prof, "audiophile")
.addTrade(1, new EmeraldForItems(Item.getItemFromBlock(Blocks.NOTEBLOCK), new PriceInfo(5, 7)))
.addTrade(2, new ListItemForEmeralds(Item.getItemFromBlock(Blocks.JUKEBOX), new PriceInfo(10, 15))); // extra for sound quality!
for (ItemStack record : OreDictionary.getOres("record"))
career.addTrade(3, new ListItemForEmeralds(record.getItem(), new PriceInfo(3, 6)));
}
开发者ID:OpenMods,项目名称:OpenBlocks,代码行数:16,代码来源:RadioVillagerTrades.java
示例5: ItemStacksAndPrices
import net.minecraft.entity.passive.EntityVillager.PriceInfo; //导入依赖的package包/类
public ItemStacksAndPrices(List<ItemStack> stacks, List<PriceInfo> prices)
{
this.stacks = stacks;
this.prices = prices;
}
开发者ID:crazysnailboy,项目名称:VillagerTrades,代码行数:6,代码来源:TradeLoader.java
示例6: getPrices
import net.minecraft.entity.passive.EntityVillager.PriceInfo; //导入依赖的package包/类
public List<PriceInfo> getPrices()
{
return this.prices;
}
开发者ID:crazysnailboy,项目名称:VillagerTrades,代码行数:5,代码来源:TradeLoader.java
示例7: ListItemForEmeraldsFixed
import net.minecraft.entity.passive.EntityVillager.PriceInfo; //导入依赖的package包/类
public ListItemForEmeraldsFixed(Item par1Item, EntityVillager.PriceInfo priceInfo) {
// super(par1Item,priceInfo);
this.itemToBuy = new ItemStack(par1Item);
this.priceInfo = priceInfo;
}
开发者ID:PrinceOfAmber,项目名称:Cyclic,代码行数:6,代码来源:VillagerCreateModule.java
注:本文中的net.minecraft.entity.passive.EntityVillager.PriceInfo类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论