Fix entity limit patch deleting unnecessary entities

We need to continue the save loop, not break from it
when a limit is reached.
This commit is contained in:
Spottedleaf 2024-08-18 11:14:39 -07:00
parent 1f6969e350
commit 9ceadbe9f1

View file

@ -23,7 +23,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ final int saveLimit = world.paperConfig().chunks.entityPerChunkSaveLimit.getOrDefault(entityType, -1);
+ if (saveLimit > -1) {
+ if (savedEntityCounts.getOrDefault(entityType, 0) >= saveLimit) {
+ break;
+ continue;
+ }
+ savedEntityCounts.merge(entityType, 1, Integer::sum);
+ }