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

ItemStack.isSimilar on Skull with NBT and ItemMeta causing NPE

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Minor Minor
    • None
    • None
    • CraftBukkit version 3697-Spigot-6ad4b93-9381350 (MC: 1.19.4) (Implementing API version 1.19.4-R0.1-SNAPSHOT)
    • RandomPackage v18.0.0.16
    • Yes

      I get an NPE (Cannot invoke "net.minecraft.nbt.NBTTagCompound.equals(Object)" because "this.serializedProfile" is null) when I try to compare two ItemStacks where one of them is a Skull with custom NBT tags, custom display name and lore. The actual item and custom NBT tags is attached (raw text from using /data get entity @s SelectedItem).

      Referenced RandomPackage line

      I cannot replicate the error using a default skull (player, dragon, creeper, skeleton, wither skeleton, or zombie head)

      Tested on 1.19.2 and 1.19.4.

            Unassigned Unassigned
            RandomHashTags RandomHashTags
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: