diff --git a/gradle.properties b/gradle.properties index 68bb939c..efdf2554 100644 --- a/gradle.properties +++ b/gradle.properties @@ -13,7 +13,7 @@ loader_version_range=[4,) mod_id=sophisticatedbackpacks mod_name=Sophisticated Backpacks mod_license=GNU General Public License v3.0 -mod_version=3.20.29 +mod_version=3.20.30 mod_group_id=sophisticatedbackpacks mod_authors=P3pp3rF1y, Ridanisaurus mod_description=Fancy and functional backpacks. diff --git a/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/backpack/BackpackStorage.java b/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/backpack/BackpackStorage.java index d4bdefa2..0bce4af8 100644 --- a/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/backpack/BackpackStorage.java +++ b/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/backpack/BackpackStorage.java @@ -105,6 +105,7 @@ public void putAccessLog(AccessLogRecord alr) { public void removeBackpackContents(UUID backpackUuid) { backpackContents.remove(backpackUuid); + setDirty(); } public void setBackpackContents(UUID backpackUuid, CompoundTag contents) { diff --git a/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/common/EntityBackpackAdditionHandler.java b/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/common/EntityBackpackAdditionHandler.java index f2b78ea1..2f665c9e 100644 --- a/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/common/EntityBackpackAdditionHandler.java +++ b/src/main/java/net/p3pp3rf1y/sophisticatedbackpacks/common/EntityBackpackAdditionHandler.java @@ -286,7 +286,7 @@ public static void removeBeneficialEffects(Creeper creeper) { } public static void removeBackpackUuid(Monster entity, Level level) { - if (level.isClientSide() || (entity.getRemovalReason() != Entity.RemovalReason.KILLED && entity.getRemovalReason() != Entity.RemovalReason.DISCARDED) || !entity.getTags().contains(SPAWNED_WITH_BACKPACK)) { + if (level.isClientSide() || !entity.getTags().contains(SPAWNED_WITH_BACKPACK)) { return; }