-
Bug
-
Resolution: Fixed
-
24w13a, 24w14a, 1.20.5 Release Candidate 2
-
None
-
Confirmed
-
Entities, Save Data
-
Important
-
1215343
-
Expansion B
The minecraft:ominous_item_spawner entity introduced in 24w13a doesn't load the spawn_item_after_ticks field when being read from NBT. This means that they instantly drop their contents when reloaded, and they cannot be summoned.
The code in OminousItemSpawner#readAdditionalSaveData appears to have a typo when reading the field (it calls the method, but does not store it back into the field on the entity):
protected void readAdditionalSaveData(CompoundTag lvt1) { ItemStack lvt2 = lvt1.contains("item", 10) ? ItemStack.parse(this.registryAccess(), lvt1.getCompound("item")).orElse(ItemStack.EMPTY) : ItemStack.EMPTY; this.setItem(lvt2); lvt1.getLong("spawn_item_after_ticks"); }