KubeJS

KubeJS

61M Downloads

Destroy mod recipe works in json file but not in recipe events

PancakeInvaders2 opened this issue ยท 0 comments

commented

Minecraft Version

1.20.1

KubeJS Version

2001.6.5-build.7

Rhino Version

2001.2.2-build.18

Architectury Version

9.2.14

Forge/Fabric Version

Forge 47.2.32

Describe your issue

When I make a recipe involving the destroy inputs types in a json file at kubejs/data/destroyintegration/recipes/mixing/testrecipe.json, it works totally fine. Example:

{
    "type": "create:mixing",
    "ingredients": [
        {
            "mixtureFluidWithSalt":"destroy:mixture",
            "cation":"destroy:sodium_ion",
            "anion":"destroy:chloride",
            "amount":200,
            "concentration":1.0
        }
    ],
    "results": [
        {
            "fluid": "minecraft:water",
            "nbt": {},
            "amount": 25
        }
    ],
    "heatRequirement": "heated"
}

No error is logged, the recipe is created, and it can be viewed in jei when the game is launched

But when I create it in a recipe event in kubejs/server_scripts/example.js

ServerEvents.recipes(event => {

    event.custom({
        'type': 'create:mixing',
        'ingredients': [
            {
                'mixtureFluidWithSalt':'destroy:mixture',
                'cation':'destroy:sodium_ion',
                'anion':'destroy:chloride',
                'amount':200,
                'concentration':1.0
            }
        ],
        'results': [
            {
                'fluid': 'minecraft:water',
                'nbt': {},
                'amount': 25
            }
        ],
        'heatRequirement': 'heated'
    })

})

I get the error

[16:21:08] [WARN] Error parsing recipe create:kjs/812k7y7pkgcdia55cdq63av2j[create:mixing]: {"type":"create:mixing","ingredients":[{"min_concentration":0.9,"max_concentration":1.1,"cation":"destroy:sodium_ion","anion":"destroy:chloride","amount":200}],"results":[{"fluid":"minecraft:water","amount":25,"nbt":"{}"}],"heatRequirement":"heated"}: An ingredient entry needs either a tag or an item

The destroy mod apparently uses several custom fluid ingredient sub types: mixtureFluidWithIon, mixtureFluidWithMolecule, mixtureFluidWithTaggedMolecules, mixtureFluidWithRefrigerants, mixtureFluidWithSalt, and it seems that kubejs doesn't see that in it's

through trial and error I have found that the error does not appear with this mod list:

kubejs-forge-2001.6.5-build.7.jar
destroy-1.20.1-0.8.jar
create-1.20.1-0.5.1.f.jar
rhino-forge-2001.2.2-build.18.jar
architectury-9.2.14-forge.jar
jei-1.20.1-forge-15.3.0.4.jar

but does appear if I add kubejs-create-forge-2001.2.5-build.2.jar

Crash report/logs

No response