Fix axolotl/fish persistence

Fixes #6643
This commit is contained in:
Nassim Jahnke 2021-09-22 13:40:13 +02:00
parent baca7d3685
commit 35ff5adaa2

View file

@ -13,7 +13,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
public void setFromBucket(boolean fromBucket) {
this.entityData.set(AbstractFish.FROM_BUCKET, fromBucket);
- this.setPersistenceRequired(this.isPersistenceRequired()); // CraftBukkit - SPIGOT-4106 update persistence
+ this.setPersistenceRequired(fromBucket); // CraftBukkit - SPIGOT-4106 update persistence // Paper - actually set as persistent
+ this.setPersistenceRequired(fromBucket || this.isPersistenceRequired()); // CraftBukkit - SPIGOT-4106 update persistence // Paper - actually set as persistent
}
@Override
@ -26,7 +26,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
public void setFromBucket(boolean fromBucket) {
this.entityData.set(Axolotl.FROM_BUCKET, fromBucket);
- this.setPersistenceRequired(this.isPersistenceRequired()); // CraftBukkit - SPIGOT-4106 update persistence
+ this.setPersistenceRequired(fromBucket); // CraftBukkit - SPIGOT-4106 update persistence // Paper - actually set as persistent
+ this.setPersistenceRequired(fromBucket || this.isPersistenceRequired()); // CraftBukkit - SPIGOT-4106 update persistence // Paper - actually set as persistent
}
@Nullable