Skip to content

Instantly share code, notes, and snippets.

@MageProtocol
Created October 26, 2015 22:48
Show Gist options
  • Save MageProtocol/b2b302d4b7d77449c3a2 to your computer and use it in GitHub Desktop.
Save MageProtocol/b2b302d4b7d77449c3a2 to your computer and use it in GitHub Desktop.
if(mc.thePlayer.inventory.getCurrentItem() != null) {
//Render Item in Output slot of grid
CraftingManager manager = CraftingManager.getInstance();
ItemStack resultItem = new ItemStack(mc.thePlayer.getHeldItem().getItem(), 1);
List<IRecipe> recipes = manager.getRecipeList();
for(int i = 0; i < recipes.size(); i++) {
IRecipe tmpRecipe = recipes.get(i);
ItemStack recipeResult = tmpRecipe.getRecipeOutput();
if(recipeResult == resultItem)
{
System.out.println("RECIPE FOUND!");
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment