Skip to content

Commit edb76b2

Browse files
authored
fix another issue (#74)
1 parent 2b86734 commit edb76b2

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

src/main/java/gregicality/multiblocks/common/metatileentities/multiblock/standard/MetaTileEntityLargeDistillery.java

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -52,22 +52,17 @@
5252
*/
5353
public class MetaTileEntityLargeDistillery extends GCYMRecipeMapMultiblockController implements IDistillationTower {
5454

55-
protected DistillationTowerLogicHandler handler = null;
55+
protected final DistillationTowerLogicHandler handler;
5656

5757
public MetaTileEntityLargeDistillery(ResourceLocation metaTileEntityId) {
58-
this(metaTileEntityId, false);
59-
}
60-
61-
public MetaTileEntityLargeDistillery(ResourceLocation metaTileEntityId, boolean useAdvHatchLogic) {
6258
super(metaTileEntityId, new RecipeMap[] { RecipeMaps.DISTILLATION_RECIPES, RecipeMaps.DISTILLERY_RECIPES });
6359
this.recipeMapWorkable = new LargeDistilleryRecipeLogic(this);
64-
if (useAdvHatchLogic)
65-
this.handler = new DistillationTowerLogicHandler(this);
60+
this.handler = new DistillationTowerLogicHandler(this);
6661
}
6762

6863
@Override
6964
public MetaTileEntity createMetaTileEntity(IGregTechTileEntity metaTileEntityHolder) {
70-
return new MetaTileEntityLargeDistillery(this.metaTileEntityId, usesAdvHatchLogic());
65+
return new MetaTileEntityLargeDistillery(this.metaTileEntityId);
7166
}
7267

7368
/**
@@ -118,7 +113,7 @@ protected void formStructure(PatternMatchContext context) {
118113
}
119114

120115
protected boolean usesAdvHatchLogic() {
121-
return getCurrentRecipeMap() == RecipeMaps.DISTILLATION_RECIPES && this.handler != null;
116+
return getCurrentRecipeMap() == RecipeMaps.DISTILLATION_RECIPES;
122117
}
123118

124119
@Override
@@ -265,7 +260,10 @@ protected boolean setupAndConsumeRecipeInputs(@NotNull Recipe recipe,
265260

266261
@Override
267262
protected IMultipleTankHandler getOutputTank() {
268-
return handler.getFluidTanks();
263+
if (usesAdvHatchLogic())
264+
return handler.getFluidTanks();
265+
266+
return super.getOutputTank();
269267
}
270268
}
271269
}

0 commit comments

Comments
 (0)