Fix most modded fluids not working in our machines
This commit is contained in:
parent
89beff99c7
commit
84aeeb978c
5 changed files with 17 additions and 15 deletions
|
@ -25,6 +25,7 @@
|
|||
package techreborn.api.generator;
|
||||
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
import reborncore.common.util.FluidUtils;
|
||||
|
||||
public class FluidGeneratorRecipe {
|
||||
private final EFluidGenerator generatorType;
|
||||
|
@ -79,7 +80,7 @@ public class FluidGeneratorRecipe {
|
|||
if (fluid == null) {
|
||||
if (other.fluid != null)
|
||||
return false;
|
||||
} else if (!fluid.equals(other.fluid))
|
||||
} else if (!FluidUtils.fluidEquals(other.fluid, fluid))
|
||||
return false;
|
||||
if (generatorType != other.generatorType)
|
||||
return false;
|
||||
|
|
|
@ -26,6 +26,7 @@ package techreborn.api.generator;
|
|||
|
||||
import com.google.common.collect.Sets;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
import reborncore.common.util.FluidUtils;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.Optional;
|
||||
|
@ -48,7 +49,7 @@ public class FluidGeneratorRecipeList {
|
|||
}
|
||||
|
||||
public Optional<FluidGeneratorRecipe> getRecipeForFluid(Fluid fluid) {
|
||||
return this.recipes.stream().filter(recipe -> recipe.getFluid().equals(fluid)).findAny();
|
||||
return this.recipes.stream().filter(recipe -> FluidUtils.fluidEquals(recipe.getFluid(), fluid)).findAny();
|
||||
}
|
||||
|
||||
public HashSet<FluidGeneratorRecipe> getRecipes() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue