mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-22 13:09:53 +00:00
1.6.2 test - Finished liquids, added connected textures on glass
This commit is contained in:
1 parent
40c6f445a2
commit
a80fcbce86
704 files changed
+60909
No files matched your search
@@ -0,0 +1,38 @@
|
||||
package tconstruct.library.crafting;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
|
||||
public class CastingRecipe
|
||||
{
|
||||
public ItemStack output;
|
||||
public FluidStack castingMetal;
|
||||
public ItemStack cast;
|
||||
public boolean consumeCast;
|
||||
public int coolTime;
|
||||
|
||||
public CastingRecipe(ItemStack replacement, FluidStack metal, ItemStack cast, boolean consume, int delay)
|
||||
{
|
||||
castingMetal = metal;
|
||||
this.cast = cast;
|
||||
output = replacement;
|
||||
consumeCast = consume;
|
||||
coolTime = delay;
|
||||
}
|
||||
|
||||
public boolean matches (FluidStack metal, ItemStack inputCast)
|
||||
{
|
||||
if (castingMetal.isFluidEqual(metal)
|
||||
&& ((cast != null && cast.getItemDamage() == Short.MAX_VALUE && inputCast.getItem() == cast.getItem()) || ItemStack.areItemStacksEqual(this.cast, inputCast)))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
public ItemStack getResult ()
|
||||
{
|
||||
return output.copy();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user