#Removing automatic recipes

134 messages · Page 1 of 1 (latest)

floral remnant
#

So, Create automagically adds extra recipes from the available ones that use their mixer, crafter and deployer. How can I disable some of them? I know what they are called after they appear, but I don't know how to remove them after they are created.

woeful stumpBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!

unkempt breach
#

if you press f3+h you can see advanced tooltips and if you hover over the output item in jei you can see the recipe id which in a recipe event you can remove specifically

#

if you have rei then it should be that little plus in the bottom right hand corner when youre looking at a specific recipe

#

heres an example of a recipe event that removes by recipe id in an array, we're going off the bonemeal's recipe id as an example ```js
ServerEvents.recipes(event => {
//Remove by recipe ID
[
'minecraft:bone_meal',
'ars_nouveau:horn_to_bonemeal'

].forEach((recipeID) => event.remove({id: recipeID}));

//Remove all recipes an item is related to. For example putting 'minecraft:bonemeal' here would remove the recipe for bone blocks as well.
[

].forEach((ingredientID) => event.remove({input: ingredientID}));

//Remove by item ID
[

].forEach((itemID) => event.remove({output: itemID}));

})```

floral remnant
#

As I've said in the ticket, I know how they are called. The problem is that they are created probably after the scripts run. So I need a way to stop them from being created in the first place.

#

Just to be clear, removing them by id does not work

unkempt breach
#

uh

ember bolt
#

so you ahve a script that does not work then

unkempt breach
#

the scripts are final

ember bolt
#

post script

floral remnant
#

Huh

unkempt breach
#

hear me out

#

how it works is create injects their recipes> then the kubejs script runs which removes them

#

🧐

floral remnant
#

I thought so too

#

Hmmm

unkempt breach
#

so whats the issue

floral remnant
#

They are still there

ember bolt
#

his removal script isnt working apparently

unkempt breach
#

you run /reload?

#

if your script isnt working the like ranker said you should post it

#

??code

stray heartBOT
# unkempt breach ??code

🗒️**Send the code!**🗒️
You may have an issue with a KubeJS script and you explain it to the best of your ability yet without the actual code in question we have very little to go off of in trying to assist you.

ember bolt
#

but we have no scirpt or logs also.

floral remnant
#

Yeah, fair

unkempt breach
#

??kjslogs

stray heartBOT
# unkempt breach ??kjslogs

You can find your KubeJS server log in /minecraft/logs/kubejs/server.log.
If you are on 1.18 or below it will be called server.txt.
Please send it if asked, as it contains helpful information.

floral remnant
#

I actually didn't expect instant response so I'm not at my pc -_-

unkempt breach
#

lol

#

its aight just post when you are

ember bolt
#

i remove create recipes wiht no isuses using the above script. works for me. give it a shot as well.. wont hurt 🙂

floral remnant
#

The thing is that I'm already used to removing recipes, it's just those automatic ones that don't agree with me

unkempt breach
#

no worries, we'll figure it out when youre at your pc

floral remnant
#

I'll talk more after I get the codes

ember bolt
#

may be a recipe after load issue

tall fiber
#

automatic recipes inherit the original recipe, so you'd have to remove the original, create a copy of it and add _manual_only to the recipe ID

floral remnant
#

It is my original to start with, so I don't need step 1, thanks for the suggestion

#

Can I know if there are some docs with info like this or is it from skimming open source?

unkempt breach
#

you able to post the script for us yet? cant really do much without it

floral remnant
#

No, sorry

#

Don't wait on me, I'll be back tomorrow

#

In fact now that I'm reading what people made with scripts it's about to become irrelevant

#

Since I would make my own crafting method

#

But I'll still post codes, if only to know for the future

unkempt breach
#

np

floral remnant
#

I'm using

ServerEvents.recipes(event => {
  event.remove({id:/^acidia:.*_chiseling_using_deployer/});
}
#

I've checked with regex tools and the id should be detected

#

I'm going to stop using item_application because I need a bit more functionality so this won't be a problem in the future

#

hopefully

stray heartBOT
#

Paste version of server.log from @floral remnant

floral remnant
#

...ah

#

I think I've figured it out

#

these recipes are not added by scripts, but by a datapack

#

I was using datapacks for some recipes since I find them easier

#

and I wasu using external datapack tool openloader instead of kubejs built-in

#

I didn't know kubejs had it

#
ServerEvents.recipes(event => {
        event.custom({
        "type": "create:item_application",
        "ingredients": [
          {
            "item": "minecraft:birch_log"
          },
          {
            "item": "kubejs:wooden_chisel"
          }
        ],
        "results": [
          {
            "item": "kubejs:birch_log_chiseling"
          }
        ]
      })
    event.remove({id:/^create:kjs.*_using_deployer/})
}

this also does not work

#

calling the recipe *_manual_only also does not work

#

now I have a birch_log_chiseling_manual_only_using_deployer recipe

stray heartBOT
#

Paste version of server.log from @floral remnant

unkempt breach
#

shouldnt matter if its a datapack recipe, kubejs should still run after it and detect it

floral remnant
#
event.remove({id:'acidia:item_application/birch_log_chiseling_using_deployer'})
stray heartBOT
#

Paste version of server.log from @floral remnant

unkempt breach
#

shouldnt it be create:item_application?

floral remnant
unkempt breach
#

i see hmm

#

you know what might be better here

#

go in game and send a screenshot of the item's recipe id from jei

#

like so

#

i wanna make sure

floral remnant
#

I did though?

unkempt breach
#

oh mb

#

didnt see lol sec

#

and you did /reload?

floral remnant
#

yeah, both server scripts and default reload

unkempt breach
#

also with jei it wont dissappear from it's ui until you restart the full game even if the recipe doesnt work

#

so test it in game and see if the recipe actually works

floral remnant
#

weird, other recipes were live with jei

unkempt breach
#

test the recipe to make sure that it's actually not removed

floral remnant
#

works

#

and by works I mean it works so it doesn't

unkempt breach
#

hmm

#

wait so lemme get this straight

#

you have this recipe in a datapack right

#

and you want to remove it

floral remnant
#

yes

stray heartBOT
#

Paste version of birch_log_chiseling.json from @floral remnant

unkempt breach
#

so why not just remove it manually from the datapack by deleting it and re adding it with kubejs?

#

with event.custom

stray heartBOT
#

[Quote ➤](#1182455863366127727 message) automatic recipes inherit the original recipe, so you'd have to remove the original, create a copy of it and add _manual_only to the recipe ID

unkempt breach
#

dont you need to add _manual_only at the end of the recipe id?

#

though ive not messed with this much tbh, squoshi would probably know more about it than me

floral remnant
#

I did, that's why the automatic recipe got called like this

#

birch_log_chiseling_manual_only <- _using_deployer

unkempt breach
#

birch_log_chiseling_using_deployer_manual_only i meant this

#

oh it got called like that because you did this?^

floral remnant
#

ok, maybe I should recap again

floral remnant
#

create:item_application creates a compat recipe that uses a deployer instead of my hand

unkempt breach
#

yeah i get it now

floral remnant
#

and calls it my_recipe_using_deployer

unkempt breach
#

wouldnt this be js event.remove({id:'acidia:item_application/birch_log_chiseling_manual_only_using_deployer'})

#

idk at this point tbh

floral remnant
#

it would but I didn't test those methods simulatenously

unkempt breach
#

i mean itd prob be the same outcome, maybe wait for squoshi to see this, he knows more than me about manual recipe creation

tall fiber
#

ID*

floral remnant
#

I was under the impression that the recipe id is literally their name

unkempt breach
tall fiber
#

i think y'all are getting confused

#

what i mean by recipe ID is the ID of the recipe you are creating

unkempt breach
#

"y'all"

#

im literally saying the same thing you are lol

stray heartBOT
tall fiber
#

can you show us what you mean by "automatic recipe"? do you mean "recipe that was automatically generated" as in bulk blasting, or do you mean "recipe that can be automated" as in a normal mixer recipe, or crushing wheels?

unkempt breach
#

not to answer for him but what he means i think is that he made an item application recipe in a datapack and it automatically added it to the deployer recipe

#

@floral remnant if theres anything you want to explain to squoshi while he's here nows your chance

tall fiber
#

i need them to explain what they mean before anything goes on

floral remnant
#

yes, automatically added recipe

#

it's a recipe that is added by create in order to make my by-hand recipe automatable