Merge pull request #1789 from KingLemming/1.7.10-fluid

1.7.10 fluid
This commit is contained in:
KingLemming 2015-04-10 16:41:29 -04:00
commit 291c57b624
2 changed files with 4 additions and 3 deletions

View file

@ -51,7 +51,7 @@ public abstract class FluidContainerRegistry
code = 31*code + container.getItem().hashCode();
code = 31*code + container.getItemDamage();
if (stack != null)
code = 31*code + stack.getFluidID();
code = 31*code + stack.fluid.hashCode();
return code;
}
@Override

View file

@ -81,11 +81,12 @@ public abstract class FluidRegistry
{
if (fluids.containsKey(fluid.getName()))
{
FMLLog.bigWarning("Duplicate registration attempt for fluid %s (type %s) has occurred. This is not a problem itself, but subsequent failed FluidStacks might be a result if not handled properly", fluid.getName(), fluid.getClass().getName());
FMLLog.bigWarning("Duplicate registration attempt for fluid %s (type %s) has occurred. This is not a problem itself, but subsequent failed FluidStacks result if this is not handled properly", fluid.getName(), fluid.getClass().getName());
return false;
}
fluids.put(fluid.getName(), fluid);
fluidIDs.put(fluid, ++maxID);
maxID++;
fluidIDs.put(fluid, maxID);
fluidNames.put(maxID, fluid.getName());
MinecraftForge.EVENT_BUS.post(new FluidRegisterEvent(fluid.getName(), maxID));