本文整理匯總了Java中net.minecraftforge.oredict.OreDictionary.getOreNames方法的典型用法代碼示例。如果您正苦於以下問題:Java OreDictionary.getOreNames方法的具體用法?Java OreDictionary.getOreNames怎麽用?Java OreDictionary.getOreNames使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類net.minecraftforge.oredict.OreDictionary
的用法示例。
在下文中一共展示了OreDictionary.getOreNames方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: ContainerSmelter
import net.minecraftforge.oredict.OreDictionary; //導入方法依賴的package包/類
public ContainerSmelter(InventoryPlayer playerInventory, TileEntitySmelter smelter) {
for(String ore : OreDictionary.getOreNames())
if(ore.toLowerCase().contains("ore"))
ores.addAll(OreDictionary.getOres(ore));
this.addSlotToContainer(new SlotSmelterInput(ores, smelter.getInventory(), 0, 56, 17));
this.addSlotToContainer(new SlotPanOutput(playerInventory.player, smelter.getInventory(), 1, 116, 35));
this.addSlotToContainer(new SlotPanOutput(playerInventory.player, smelter.getInventory(), 2, 140, 39));
for (int i = 0; i < 3; ++i)
for (int j = 0; j < 9; ++j)
this.addSlotToContainer(new Slot(playerInventory, j + i * 9 + 9, 8 + j * 18, 84 + i * 18));
for (int k = 0; k < 9; ++k)
this.addSlotToContainer(new Slot(playerInventory, k, 8 + k * 18, 142));
}