Closed alyip98 closed 6 years ago
Could provide the version of Tinker I/O ? Thanks!
tinker_io-1.12.2-release 2.6.1, playing Enigmatica 2 Expert
From tinker-IO/src/main/java/tinker_io/tileentity/TileEntitySmartOutput.java:
private void updateRecipe() {
ItemStack cast = inventory.getStackInSlot(ContainerSmartOutput.PATTERN);
FluidStack fluidStack = tank.getFluid();
if(currentMode == MODE_BASIN) {
currentRecipe = SmartOutputRecipeHandler.findBasinCastingRecipe(cast, fluidStack);
} else if(currentMode == MODE_CAST) {
currentRecipe = SmartOutputRecipeHandler.findTableCastingRecipe(cast, fluidStack);
}
}
I suggest storing currentRecipe locally and only calling findBasinCastingRecipe when the fluid type has changed
The code you found is in the RW version. And findBasinCastingRecipe()
will be called only if private boolean isChanged()
return true.
I believe that the problem is due to SORecipeChecker rebuilding a list of recipes from all registered casting recipes every tick. I'm not sure if this is addressed in the rw version, but if not, could you cache the recipes?