Support 1.14 Minecraft Barrels for Aging

This commit is contained in:
Sn0wStorm
2019-08-17 18:53:06 +02:00
parent a95437cdf1
commit 67ab8e7de3
15 changed files with 324 additions and 121 deletions
+2 -8
View File
@@ -302,20 +302,14 @@ public class BIngredients {
}
int quality = 10 - Math.round(recipe.getWoodDiff(wood) * recipe.getDifficulty());
if (quality > 0) {
return quality;
}
return 0;
return Math.max(quality, 0);
}
// returns the quality regarding the ageing time conditioning given Recipe
public int getAgeQuality(BRecipe recipe, float time) {
int quality = 10 - Math.round(Math.abs(time - recipe.getAge()) * ((float) recipe.getDifficulty() / 2));
if (quality > 0) {
return quality;
}
return 0;
return Math.max(quality, 0);
}
// Creates a copy ingredients