mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-20 20:12:30 +00:00
Fixed PRC varying reaction time not being applied
This commit is contained in:
1 parent
abd581b2f1
commit
1237230637
5 files changed
+24
-1
No files matched your search
@@ -15,6 +15,7 @@ import mekanism.api.gas.GasTank;
|
||||
import mekanism.api.gas.IGasHandler;
|
||||
import mekanism.api.gas.ITubeConnection;
|
||||
import mekanism.common.SideData;
|
||||
import mekanism.common.Upgrade;
|
||||
import mekanism.common.base.IDropperHandler;
|
||||
import mekanism.common.base.ISustainedData;
|
||||
import mekanism.common.block.BlockMachine.MachineType;
|
||||
@@ -83,7 +84,15 @@ public class TileEntityPRC extends TileEntityBasicMachine<PressurizedInput, Pres
|
||||
|
||||
if(canOperate(recipe) && MekanismUtils.canFunction(this) && getEnergy() >= energyPerTick)
|
||||
{
|
||||
boolean update = BASE_TICKS_REQUIRED != recipe.ticks;
|
||||
|
||||
BASE_TICKS_REQUIRED = recipe.ticks;
|
||||
|
||||
if(update)
|
||||
{
|
||||
recalculateUpgradables(Upgrade.SPEED);
|
||||
}
|
||||
|
||||
setActive(true);
|
||||
|
||||
if((operatingTicks+1) < ticksRequired)
|
||||
@@ -155,10 +164,12 @@ public class TileEntityPRC extends TileEntityBasicMachine<PressurizedInput, Pres
|
||||
public PressurizedRecipe getRecipe()
|
||||
{
|
||||
PressurizedInput input = getInput();
|
||||
|
||||
if(cachedRecipe == null || !input.testEquality(cachedRecipe.getInput()))
|
||||
{
|
||||
cachedRecipe = RecipeHandler.getPRCRecipe(input);
|
||||
}
|
||||
|
||||
return cachedRecipe;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user