mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-20 03:59:37 +00:00
Fix a different, unrelated OreDict issue.
This commit is contained in:
1 parent
39c6b45a2c
commit
700cc76c35
6 files changed
+60
-23
No files matched your search
@@ -11,11 +11,11 @@ import net.minecraftforge.oredict.OreDictionary;
|
||||
public class MekanismAPI
|
||||
{
|
||||
//Add a BlockInfo value here if you don't want a certain block to be picked up by cardboard boxes
|
||||
private static Set<ItemInfo> cardboardBoxIgnore = new HashSet<ItemInfo>();
|
||||
private static Set<BlockInfo> cardboardBoxIgnore = new HashSet<BlockInfo>();
|
||||
|
||||
public static boolean isBlockCompatible(Item item, int meta)
|
||||
{
|
||||
for(ItemInfo i : cardboardBoxIgnore)
|
||||
for(BlockInfo i : cardboardBoxIgnore)
|
||||
{
|
||||
if(i.block == Block.getBlockFromItem(item) && (i.meta == OreDictionary.WILDCARD_VALUE || i.meta == meta))
|
||||
{
|
||||
@@ -28,15 +28,15 @@ public class MekanismAPI
|
||||
|
||||
public static void addBoxBlacklist(Block block, int meta)
|
||||
{
|
||||
cardboardBoxIgnore.add(new ItemInfo(block, meta));
|
||||
cardboardBoxIgnore.add(new BlockInfo(block, meta));
|
||||
}
|
||||
|
||||
public static void removeBoxBlacklist(Block block, int meta)
|
||||
{
|
||||
cardboardBoxIgnore.remove(new ItemInfo(block, meta));
|
||||
cardboardBoxIgnore.remove(new BlockInfo(block, meta));
|
||||
}
|
||||
|
||||
public static Set<ItemInfo> getBoxIgnore()
|
||||
public static Set<BlockInfo> getBoxIgnore()
|
||||
{
|
||||
return cardboardBoxIgnore;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user