Migration added to remove damage tag from existing poss balls to allow stacking again

This commit is contained in:
Tara Piccari 2024-01-30 15:07:29 -07:00
parent 9ffe626273
commit 1e92e698b0

View file

@ -114,6 +114,12 @@ public class ThrownPossBall extends ThrowableItemProjectile
ItemStack item = getItem();
CompoundTag tag = item.getTag();
if(tag == null)tag=new CompoundTag();
if(tag.contains(ItemStack.TAG_DAMAGE))
{
tag.remove(ItemStack.TAG_DAMAGE); // Migrate existing poss balls to remove the obsolete damage tag
}
if(tag.contains("entity"))
{
if(captured)