CraftTweaker

CraftTweaker

151M Downloads

removing shaped and shapeless not actually affecting recipes

Mofo50C opened this issue ยท 12 comments

commented

Issue Description:

removeShaped and removeShapeless not working. The script's syntax is correct and all the items involved are correct, in fact the crafttweaker log just goes past it like it was correct but instead of saying removing 1 shaped/shapeless recipe it says 0. eventhough i am staring at the recipe on jei and it certainly exists when crafting.
im 100% sure ive typed the recipes right and the items correctly

What happens:

run the game, iterally no errors i did ctrl f on the log and no errors or warnings, go in game and the recipes are still there. logs lower down the page

the recipes.remove() functions all work and ive tried doing recipes.remove() on the items in question and that works just not removeShaped and removeShapeless. and ive double checked the ingredients so much ive memorised them

What you expected to happen:

removes the specific shaped and shapeless recipes

Script used:

link

crafttweaker.log file:

part of the log that says the issue


Affected Versions:

  • Minecraft: 1.12.2
  • Forge: 1.12.2 - 14.23.5.2854
  • Crafttweaker: 1.12-4.1.20.602
  • Using a server: no
  • If yes, does the client have the exact same scripts?

Your most recent log file where the issue was present:

the whole log is useless but ill put it here anyway
whole log

appreciate any help in advance, cheers.

commented

Remove null from that as well

commented

Firstly don't give us truncated files.

Secondly why are you specifying the input? Just using remove should work fine.

This is probably an issue with your recipe matrix though, just because a recipe is 3x2, doesn't mean you need to put a row of null

Try this

recipes.removeShaped(<earthworks:itemslab_planks_vert_dark_oak> * 6, [[<quark:vertical_planks:4>, <quark:vertical_planks:4>, <quark:vertical_planks:4>]); 
commented

Firstly don't give us truncated files.

Secondly why are you specifying the input? Just using remove should work fine.

This is probably an issue with your recipe matrix though, just because a recipe is 3x2, doesn't mean you need to put a row of null

Try this

recipes.removeShaped(<earthworks:itemslab_planks_vert_dark_oak> * 6, [[<quark:vertical_planks:4>, <quark:vertical_planks:4>, <quark:vertical_planks:4>]); 

godly speed of replying sheeeesh. ive put the full log and the relevant log and the script is just that small i havent taken anything out. also i need the removeShaped and shapeless ones cuz the items have other recipes and i thought it would remove all of them except just the specific ones

ah tbf i used ctgui for the shaped ones ill try it out without the nulls thank you

commented

Ah yea, honestly the gui isn't going to get you very far, a lot of it just doesn't work that great, it would honestly be better to just learn the script language.

Also the gui is removed in newer versions, so may as well start now

commented

Ah yea, honestly the gui isn't going to get you very far, a lot of it just doesn't work that great, it would honestly be better to just learn the script language.

Also thr gui is removed in newer versions, so may as well start now

ye nah i know the scripting method i just thought the gui would be faster

and for using the shaped versions i actually need it to remove a specific one cuz the items have more than one recipe

commented

oh mad it has actually worked thank you very much thats strange that having empty nulls breaks it

commented

hmm but for some reason the other recipe that has 'null's in it still doesnt work

recipes.removeShaped(<tropicraft:bundle> * 2, [[<minecraft:reeds>, <minecraft:reeds>, null],[<minecraft:reeds>, <minecraft:reeds>, null], [null, null, null]]);

ive tried it like this as well:

recipes.removeShaped(<tropicraft:bundle> * 2, [[<minecraft:reeds>, <minecraft:reeds>, null],[<minecraft:reeds>, <minecraft:reeds>, null]]);
commented

Remove null from that as well

even from the rows that have items in them? so like turn [<minecraft:reeds>, <minecraft:reeds>, null] into [<minecraft:reeds>, <minecraft:reeds>]

commented

Yip, exactly that

commented

Yip, exactly that

holy shit absolute life saver mate thank you it has worked perfectly. ive got a slightly unrelated question when were adding shaped reciepes do we need the empty rows to be an array of nulls, something like this:

recipes.addShaped(<earthworks:itemslab_planks_vert_dark_oak> * 6, [[null, null, null],[<quark:vertical_planks:5>, <quark:vertical_planks:5>, <quark:vertical_planks:5>], [null, null, null]]);

or can we just leave them as empty arrays:

recipes.addShaped(<earthworks:itemslab_planks_vert_dark_oak> * 6, [[], [<quark:vertical_planks:5>, <quark:vertical_planks:5>, <quark:vertical_planks:5>], []]);
commented

I wouldn't even include the arrays, so it defines the shape of the recipe, if you put a null, it means that slot needs to be empty, so if you had like

[[item, null, null], [item, null, null], [null, null, null]] 

That would be an item on top of another item, but because there are nulls, you can only do it in the top left, and middle left slots of the crafting grid, but if you left the nulls out, you could craft it in any 2 vertical slots in the grid, as well as the 2x2 crafting grid

commented

I wouldn't even include the arrays, so it defines the shape of the recipe, if you put a null, it means that slot needs to be empty, so if you had like

[[item, null, null], [item, null, null], [null, null, null]] 

That would be an item on top of another item, but because there are nulls, you can only do it in the top left, and middle left slots of the crafting grid, but if you left the nulls out, you could craft it in any 2 vertical slots in the grid, as well as the 2x2 crafting grid

oh ye that makes sense ok got it thank you again. i guess ill close the issue then