mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-19 19:59:55 +00:00
Fix the errors that were left, I commeneted our some code in SmelteryLogic for right now, Also changed the way ArrowEntity Sends the ChangeGameState
This commit is contained in:
1 parent
840e0cee04
commit
fffe2800bd
18 files changed
+45
-33
No files matched your search
@@ -13,9 +13,9 @@ public class Smeltery
|
||||
{
|
||||
public static Smeltery instance = new Smeltery();
|
||||
|
||||
private final HashMap<List<Item>, FluidStack> smeltingList = new HashMap<List<Item>, FluidStack>();
|
||||
private final HashMap<List<Item>, Integer> temperatureList = new HashMap<List<Item>, Integer>();
|
||||
private final HashMap<List<Item>, ItemStack> renderIndex = new HashMap<List<Item>, ItemStack>();
|
||||
private final HashMap<List<ItemStack>, FluidStack> smeltingList = new HashMap<List<ItemStack>, FluidStack>();
|
||||
private final HashMap<List<ItemStack>, Integer> temperatureList = new HashMap<List<ItemStack>, Integer>();
|
||||
private final HashMap<List<ItemStack>, ItemStack> renderIndex = new HashMap<List<ItemStack>, ItemStack>();
|
||||
private final ArrayList<AlloyMix> alloys = new ArrayList<AlloyMix>();
|
||||
|
||||
/** Adds mappings between an itemstack and an output liquid
|
||||
@@ -67,9 +67,9 @@ public class Smeltery
|
||||
*/
|
||||
public static void addMelting (ItemStack input, Item item, int metadata, int temperature, FluidStack liquid)
|
||||
{
|
||||
instance.smeltingList.put(Arrays.asList((Item)input.getItem(), input.getItemDamage()), liquid);
|
||||
instance.temperatureList.put(Arrays.asList((Item)input.getItem(), input.getItemDamage()), temperature);
|
||||
instance.renderIndex.put(Arrays.asList((Item)input.getItem(), input.getItemDamage()), new ItemStack(item, input.stackSize, metadata));
|
||||
instance.smeltingList.put(Arrays.asList(new ItemStack(input.getItem(), input.getItemDamage())), liquid);
|
||||
instance.temperatureList.put(Arrays.asList(new ItemStack(input.getItem(), input.getItemDamage())), temperature);
|
||||
instance.renderIndex.put(Arrays.asList(new ItemStack(input.getItem(), input.getItemDamage())), new ItemStack(item, input.stackSize, metadata));
|
||||
}
|
||||
|
||||
/** Adds an alloy mixing recipe.
|
||||
@@ -161,17 +161,17 @@ public class Smeltery
|
||||
return liquids;
|
||||
}
|
||||
|
||||
public static HashMap<List<Item>, FluidStack> getSmeltingList ()
|
||||
public static HashMap<List<ItemStack>, FluidStack> getSmeltingList ()
|
||||
{
|
||||
return instance.smeltingList;
|
||||
}
|
||||
|
||||
public static HashMap<List<Item>, Integer> getTemperatureList ()
|
||||
public static HashMap<List<ItemStack>, Integer> getTemperatureList ()
|
||||
{
|
||||
return instance.temperatureList;
|
||||
}
|
||||
|
||||
public static HashMap<List<Item>, ItemStack> getRenderIndex ()
|
||||
public static HashMap<List<ItemStack>, ItemStack> getRenderIndex ()
|
||||
{
|
||||
return instance.renderIndex;
|
||||
}
|
||||
|
||||
@@ -56,7 +56,7 @@ public abstract class DualHarvestTool extends HarvestTool
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getStrVsBlock (ItemStack stack, Block block, int meta)
|
||||
public float getDigSpeed (ItemStack stack, Block block, int meta)
|
||||
{
|
||||
|
||||
NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
|
||||
@@ -99,7 +99,7 @@ public abstract class DualHarvestTool extends HarvestTool
|
||||
return 0.1f;
|
||||
}
|
||||
}
|
||||
return super.getStrVsBlock(stack, block, meta);
|
||||
return super.getDigSpeed(stack, block, meta);
|
||||
}
|
||||
|
||||
public boolean canHarvestBlock (Block block)
|
||||
|
||||
@@ -58,7 +58,7 @@ public abstract class HarvestTool extends ToolCore
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getStrVsBlock (ItemStack stack, Block block, int meta)
|
||||
public float getDigSpeed (ItemStack stack, Block block, int meta)
|
||||
{
|
||||
if (!stack.hasTagCompound())
|
||||
return 1.0f;
|
||||
@@ -79,7 +79,7 @@ public abstract class HarvestTool extends ToolCore
|
||||
{
|
||||
return calculateStrength(tags, block, meta); //No issue if the harvest level is too low
|
||||
}
|
||||
return super.getStrVsBlock(stack, block, meta);
|
||||
return super.getDigSpeed(stack, block, meta);
|
||||
}
|
||||
|
||||
float calculateStrength (NBTTagCompound tags, Block block, int meta)
|
||||
|
||||
@@ -621,7 +621,7 @@ public abstract class ToolCore extends Item implements IEnergyContainerItem, IBa
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getStrVsBlock (ItemStack stack, Block block, int meta)
|
||||
public float getDigSpeed (ItemStack stack, Block block, int meta)
|
||||
{
|
||||
NBTTagCompound tags = stack.getTagCompound();
|
||||
if (tags.getCompoundTag("InfiTool").getBoolean("Broken"))
|
||||
|
||||
@@ -30,7 +30,7 @@ public abstract class Weapon extends ToolCore
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getStrVsBlock (ItemStack stack, Block block, int meta)
|
||||
public float getDigSpeed (ItemStack stack, Block block, int meta)
|
||||
{
|
||||
if (stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Broken"))
|
||||
return 0.1f;
|
||||
|
||||
Reference in new issue
Block a user