Merge pull request #605 from Dynious/OreRecipeFix
Fixed OreStack EMC values not being looked up properly
This commit is contained in:
commit
ccd5ebaefd
2 changed files with 23 additions and 1 deletions
|
@ -314,6 +314,17 @@ public class EmcRegistry
|
|||
}
|
||||
}
|
||||
}
|
||||
else if (stack.getWrappedStack() instanceof OreStack)
|
||||
{
|
||||
OreStack oreStack = (OreStack)stack.getWrappedStack();
|
||||
for (ItemStack oreItemStack : OreDictionary.getOres(oreStack.oreName))
|
||||
{
|
||||
if (emcRegistry.stackMappings.containsKey(new WrappedStack(oreItemStack)))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -399,6 +410,17 @@ public class EmcRegistry
|
|||
return lowestValue;
|
||||
}
|
||||
}
|
||||
else if (stack.getWrappedStack() instanceof OreStack)
|
||||
{
|
||||
OreStack oreStack = (OreStack)stack.getWrappedStack();
|
||||
for (ItemStack oreItemStack : OreDictionary.getOres(oreStack.oreName))
|
||||
{
|
||||
if (emcRegistry.stackMappings.containsKey(new WrappedStack(oreItemStack)))
|
||||
{
|
||||
return emcRegistry.stackMappings.get(new WrappedStack(oreItemStack));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -98,7 +98,7 @@ public class RecipeHelper
|
|||
|
||||
if (oreStack.getWrappedStack() instanceof OreStack)
|
||||
{
|
||||
recipeInputs.add(new WrappedStack(shapedOreRecipe.getInput()[i]));
|
||||
recipeInputs.add(oreStack);
|
||||
}
|
||||
}
|
||||
else if (shapedOreRecipe.getInput()[i] instanceof ItemStack)
|
||||
|
|
Loading…
Reference in a new issue