CraftTweaker

CraftTweaker

151M Downloads

Custom item transformer issue

Weisstrieb opened this issue ยท 3 comments

commented

Issue Description:

Custom item transformer doesn't work intentionally.

What happens:

  1. https://youtu.be/wchRBIyBUvA
  2. https://youtu.be/JEWVCJ2DkxI

What you expected to happen:

  1. Other ingredients should not return.
  2. Ingredient that has its own transformer should not disappear. (apple in the video above)

Script used (Please Pastebin or gist your script, posting an unpasted or ungist'd script will automatically close this issue):

  1. https://pastebin.com/uYTudtR6
  2. https://pastebin.com/z8eJ8Uwb

Minetweaker.log file (Please Pastebin or gist your file, posting an unpasted or ungist'd file will automatically close this issue):

[INITIALIZATION][CLIENT][INFO] CraftTweaker: Building registry
[INITIALIZATION][CLIENT][INFO] CraftTweaker: Successfully built item registry
[INITIALIZATION][CLIENT][INFO] Loading scripts
[INITIALIZATION][CLIENT][INFO] [crafttweaker | SIDE_CLIENT]: Loading Script: {[0:crafttweaker]: remittance.zs}
[INITIALIZATION][CLIENT][INFO] [crafttweaker | SIDE_CLIENT]: Loading Script: {[0:crafttweaker]: test.zs}
[POSTINITIALIZATION][CLIENT][INFO] Adding shapeless recipe for Credit Card with name satchel_deposit.0
[POSTINITIALIZATION][CLIENT][INFO] Adding shapeless recipe for Credit Card with name satchel_deposit.1
[POSTINITIALIZATION][CLIENT][INFO] Adding shapeless recipe for Credit Card with name satchel_deposit.2
[POSTINITIALIZATION][CLIENT][INFO] Adding shapeless recipe for Credit Card with name satchel_deposit.3
[POSTINITIALIZATION][CLIENT][INFO] Adding shapeless recipe for Credit Card with name satchel_deposit.4
[POSTINITIALIZATION][CLIENT][INFO] Adding shapeless recipe for Credit Card with name cache_deposit.0
[POSTINITIALIZATION][CLIENT][INFO] Adding shapeless recipe for Sand with name test_1
[SERVER_STARTED][CLIENT][INFO] Fixed the RecipeBook

This is end.


Affected Versions (Do not use "latest"):

  • Minecraft: 1.12.2
  • Forge: 14.23.2.2618
  • Crafttweaker: 4.1.4
commented

Please test if that issue persists in the latest CrT release (release ~15h ago)
I recommend switching to the new IItemTransformer though, since the old one will most likely become deprecated in 1.13 syntax is

ingredient.transformNew(function(item){
//return item to stay in the grid
return item;
});
commented

IItemTransformer works fine as I expected, but ICraftingInfo parameter in IRecipeFunction doesn't seem to be working in new version(4.1.5). I'll open new issue.

commented

Second bug is solved by updating new version(4.1.5).
Reducing operations and not using immutable map for operation directly can prevent the script from causing the first bug. Close the issue.