Clean up ShapedOreRecipe and ShapelessOreRecipe
This commit is contained in:
parent
f009435fa4
commit
864b05074e
|
@ -84,7 +84,7 @@ public class ShapedOreRecipe extends IForgeRegistryEntry.Impl<IRecipe> implement
|
||||||
public ItemStack getRecipeOutput(){ return output; }
|
public ItemStack getRecipeOutput(){ return output; }
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean matches(InventoryCrafting inv, World world)
|
public boolean matches(@Nonnull InventoryCrafting inv, @Nonnull World world)
|
||||||
{
|
{
|
||||||
for (int x = 0; x <= MAX_CRAFT_GRID_WIDTH - width; x++)
|
for (int x = 0; x <= MAX_CRAFT_GRID_WIDTH - width; x++)
|
||||||
{
|
{
|
||||||
|
@ -143,13 +143,15 @@ public class ShapedOreRecipe extends IForgeRegistryEntry.Impl<IRecipe> implement
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Nonnull
|
||||||
public NonNullList<Ingredient> func_192400_c()
|
public NonNullList<Ingredient> func_192400_c()
|
||||||
{
|
{
|
||||||
return this.input;
|
return this.input;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public NonNullList<ItemStack> getRemainingItems(InventoryCrafting inv) //getRecipeLeftovers
|
@Nonnull
|
||||||
|
public NonNullList<ItemStack> getRemainingItems(@Nonnull InventoryCrafting inv) //getRecipeLeftovers
|
||||||
{
|
{
|
||||||
return ForgeHooks.defaultRecipeGetRemainingItems(inv);
|
return ForgeHooks.defaultRecipeGetRemainingItems(inv);
|
||||||
}
|
}
|
||||||
|
@ -164,6 +166,8 @@ public class ShapedOreRecipe extends IForgeRegistryEntry.Impl<IRecipe> implement
|
||||||
return height;
|
return height;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Nonnull
|
||||||
public String func_193358_e()
|
public String func_193358_e()
|
||||||
{
|
{
|
||||||
return this.group.toString();
|
return this.group.toString();
|
||||||
|
|
|
@ -90,7 +90,7 @@ public class ShapelessOreRecipe extends IForgeRegistryEntry.Impl<IRecipe> implem
|
||||||
public ItemStack getCraftingResult(@Nonnull InventoryCrafting var1){ return output.copy(); }
|
public ItemStack getCraftingResult(@Nonnull InventoryCrafting var1){ return output.copy(); }
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean matches(InventoryCrafting var1, World world)
|
public boolean matches(@Nonnull InventoryCrafting var1, @Nonnull World world)
|
||||||
{
|
{
|
||||||
NonNullList<Ingredient> required = NonNullList.create();
|
NonNullList<Ingredient> required = NonNullList.create();
|
||||||
required.addAll(input);
|
required.addAll(input);
|
||||||
|
@ -124,7 +124,8 @@ public class ShapelessOreRecipe extends IForgeRegistryEntry.Impl<IRecipe> implem
|
||||||
return required.isEmpty();
|
return required.isEmpty();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Nonnull
|
||||||
public NonNullList<Ingredient> func_192400_c()
|
public NonNullList<Ingredient> func_192400_c()
|
||||||
{
|
{
|
||||||
return this.input;
|
return this.input;
|
||||||
|
@ -132,11 +133,13 @@ public class ShapelessOreRecipe extends IForgeRegistryEntry.Impl<IRecipe> implem
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@Nonnull
|
@Nonnull
|
||||||
public NonNullList<ItemStack> getRemainingItems(InventoryCrafting inv)
|
public NonNullList<ItemStack> getRemainingItems(@Nonnull InventoryCrafting inv)
|
||||||
{
|
{
|
||||||
return ForgeHooks.defaultRecipeGetRemainingItems(inv);
|
return ForgeHooks.defaultRecipeGetRemainingItems(inv);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Nonnull
|
||||||
public String func_193358_e()
|
public String func_193358_e()
|
||||||
{
|
{
|
||||||
return this.group == null ? "" : this.group.toString();
|
return this.group == null ? "" : this.group.toString();
|
||||||
|
|
Loading…
Reference in New Issue