Inventory Profiles Next

Inventory Profiles Next

24M Downloads

Improper Components match during profile change/apply

CreepilyCreeper opened this issue ยท 4 comments

commented

Have you asked for help in discord?

YES

commented

apparently a new hoe works but a damaged hoe doesnt

Replay.2024-06-28.14-18-50.mp4
commented

So i was following this guide on how to do the profile config thing https://inventory-profiles-next.github.io/profiles/
but i cant have multiple items in order for a slot like demonstrated in the link
Inventory Profiles Next - Profiles
An inventory sorter mod
i tried to do this

profile Usual_1
    HOT1
        "minecraft:diamond_sword" -> [ "minecraft:enchantments"("[\"minecraft:mending\",\"minecraft:sharpness\",\"minecraft:looting\"]"), "minecraft:repair_cost"("1") ]
    HOT2
        "minecraft:netherite_pickaxe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:diamond_pickaxe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:iron_pickaxe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:stone_pickaxe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:netherite_pickaxe"
        "minecraft:diamond_pickaxe"
        "minecraft:iron_pickaxe"
        "minecraft:stone_pickaxe"
    HOT3
        "minecraft:diamond_shovel"
    HOT4
        "minecraft:diamond_axe"
    HOT5
        "minecraft:netherite_hoe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:diamond_hoe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:iron_hoe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:stone_hoe" -> [ "minecraft:enchantments"("[\"minecraft:silk_touch\"]") ]
        "minecraft:netherite_hoe"
        "minecraft:diamond_hoe"
        "minecraft:iron_hoe"
        "minecraft:stone_hoe"
...

i have a stone hoe and it doesnt go into the hotbar, but the diamond sword does, the netherite pickaxe does, the diamond shovel doesnt and the diamond axe doesnt

commented

I think it's replicable for any damaged tool, which isn't enchanted (from my observations).

Isn't that related to Effect Components in v1.21 (Technical changes section)?

The effects field in an Enchantment is a map of Effect Component type the Effect List data. Most Effect Components are lists, so any number of Effects can be added of any Component Type. The data for each effect generally involves having a specified condition context and Effect Type, but some Effects also deviate from this format.
...
minecraft:item_damage: Effects for the amount of durability lost when an item is damaged

Isn't that a new way of handling durability in Minecraft?

Anyway, from my quick tests, seems like IPN requires items to overly match items with profile definitions.
e.g.

"minecraft:diamond_pickaxe" -> [ "minecraft:enchantments"("[\"minecraft:efficiency\"]") ]

won't match a pickaxe, which has also the Unbreaking enchantment. (Isn't that unintended, btw?)

Soo, I believe the damaged tool receives now an effect, which is not defined in profile conf by IPN, but is required to be defined during profile load.
That's still just a guess, but I hope it might help with fixing the issue quicker.

commented

fixed before 5ad0d0f