Brewery

Brewery

101k Downloads

Some recipe conflict with each other.

Deiscorides opened this issue ยท 4 comments

commented

The two recipes below conflict with each other. The Red Wine recipe overrides the recipe below it. If I follow the 91 recipe perfectly I only ever get recipe 14 Red Wine. I've had similar problems with other recipes, up to a certain point. When aging they will change from one brew name to another brew name once the aging years have passed those of the brew with the least amount of aging time. This only seems to happen when recipes are somewhat similar. Is there a way to have the plugin do more checks to make sure recipes are different? I think this may have something to do with how the difficulty is done. Where Difficulty of 1 will allow great lee-way and this lee-way overlaps too much into other recipes and overrides them because it was higher on the list of recipes in the config file. Here's an example of two recipes that conflict:

14:
name: Red Wine
ingredients:
- 372/10
cookingtime: 8
distillruns: 0
wood: 0
age: 15
color: DARK_RED
difficulty: 1
alcohol: 20

91:
# Category: Wine
name: Goblin Wine/Orc Wine/&eElven Wine
ingredients:
# NETHER_WART
- 372/8
- SAPLING/1
cookingtime: 10
# Wood of the barrel 0=any 1=Birch 2=Oak 3=Jungle 4=Spruce
wood: 4
age: 15
color: DARK_RED
difficulty: 5
alcohol: 20
effects:
- NIGHT_VISION/15
- SPEED/3
- JUMPX/1
- SATURATION/30

commented

same problem, I try to cook nr.2

2:
    name: "&8(Schlecht) Tiefwurzlerzwergenschnaps/&8(Normal) Tiefwurzlerzwergenschnaps/&6Tiefwurzlerzwergenschnaps"
    ingredients:
    - WHEAT/3
    - SEEDS/2
    - SUGAR_CANE/1
    - GOLD_INGOT/1
    cookingtime: 20
    distillruns: 10
    age: 6
    wood: 4
    color: Grey
    difficulty: 2
    alcohol: 16
    effects:
    - BLINDNESS/2
    - FAST_DIGGING/2
    - HUNGER/3
    - HEAL/2

and the result after 20min cooking is "(Normal) Echelon-Met":

22:
    name: "&8(Schlecht) Echelon-Met/&8(Normal) Echelon-Met/&6Echelon-Met"
    ingredients:
    - SUGAR_CANE/6
    cookingtime: 50
    distillruns: 0
    age: 0
    wood: 0
    color: GREY
    difficulty: 1
    alcohol: 5

Whats wrong? :S

commented

cook 8min "SiliciRum"

23:
    name: "&8(Schlecht) SiliciRum/&8(Normal) SiliciRum/&6SiliciRum"
    ingredients:
    - SUGAR_CANE/14
    cookingtime: 8
    distillruns: 5
    age: 14
    wood: 2
    color: DARK_RED
    difficulty: 6
    alcohol: 30
    effects:
    - FIRE_RESISTANCE/100

and the result was "(Schlecht) Echelon-Met":

22:
    name: "&8(Schlecht) Echelon-Met/&8(Normal) Echelon-Met/&6Echelon-Met"
    ingredients:
    - SUGAR_CANE/6
    cookingtime: 50
    distillruns: 0
    age: 0
    wood: 0
    color: GREY
    difficulty: 1
    alcohol: 5
commented

Recipes with a very low difficulty are extremely easy to get, especially with difficulty of 1. That means if your brewed potion is just near such an easy recipe, it will already be enough for the plugin to choose this easy one over the more difficult one. So if the Difficult recipe overlaps too much with the easy one, the easy one may always be preferred.

A possible solution would to use higher difficulty than 1

Simply add "debug: true" to the config to see output into the console on how and why a certain recipe is chosen by the plugin over the others.

Maybe I can introduce more checks to better differentiate between similar recipes, if I can find a way without breaking existing recipes.

commented

When you are nearing 500 recipes and 1,500 possible brews, things like metadata ingredients, and better checks for recipes are really needed.

I'm glad to read things are progressing with this plugin. It is a blast.