Skip to content

Commit

Permalink
Fix Essence Furnaces not cooking when recipes have shorter cook times
Browse files Browse the repository at this point in the history
closes #764
  • Loading branch information
BlakeBr0 committed Jan 26, 2025
1 parent fc8d5cd commit e4b71f2
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ public static void tick(Level level, BlockPos pos, BlockState state, EssenceFurn
++tile.cookingProgress;
if (tile.cookingProgress == tile.cookingTotalTime) {
tile.cookingProgress = 0;
tile.cookingTotalTime = (int) (getTotalCookTime(level, tile) * tile.getTier().getCookTimeMultiplier());
tile.cookingTotalTime = Math.max(1, (int) (getTotalCookTime(level, tile) * tile.getTier().getCookTimeMultiplier()));
if (tile.burn(recipe, tile.items, i)) {
tile.setRecipeUsed(recipe);
}
Expand Down Expand Up @@ -154,7 +154,7 @@ public void setItem(int slot, ItemStack stack) {
}

if (slot == 0 && !flag) {
this.cookingTotalTime = (int) (getTotalCookTime(level, this) * this.getTier().getCookTimeMultiplier());
this.cookingTotalTime = Math.max(1, (int) (getTotalCookTime(level, this) * this.getTier().getCookTimeMultiplier()));
this.cookingProgress = 0;
this.setChanged();
}
Expand Down

0 comments on commit e4b71f2

Please sign in to comment.