Uploaded image for project: 'Spigot'
  1. Spigot
  2. SPIGOT-7907

MC 1.20.5: Change in MerchantRecipe item matching

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • None
    • None
    • This server is running CraftBukkit version git-Bukkit-d69a053 (MC: 1.21.1) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
    • Yes

      Before the update for MC 1.20.5, merchant recipes would accept items with additional NBT tags (i.e. ignore any additional NBT tags that are not present on the item used inside the recipe).

      Since the update for MC 1.20.5, MerchantRecipes created via the Bukkit API now also check for the absence of components.

      Example: Creating a merchant recipe with an item without enchantments would also accept enchanted items pre 1.20.5. Now, enchanted items are no longer accepted.

      This ticket asks to revert this behavior.

      Ticket https://hub.spigotmc.org/jira/browse/SPIGOT-7828 asks for the addition of new API to have more control over how items are matched, both in merchant recipes and outside. One idea there is to use ItemMeta to represent the DataComponentPredicate data + revert how we convert ItemMeta to merchant recipes (i.e. this ticket). But to properly support the fine control over how ItemMeta properties are matched (unset vs empty), further API changes might be required to ItemMeta (see the notes in the other ticket). Hence, this separate ticket asks to at least restore the pre 1.20.5 behavior of how items are converted to merchant recipes for now.

            Unassigned Unassigned
            blablubbabc blablubbabc
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: