mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-20 23:46:57 +01:00
SPIGOT-6927: Fix default value of spawn-limits in Worlds
By: Doc <nachito94@msn.com>
This commit is contained in:
parent
314b83ffae
commit
8b46bfaaa2
1 changed files with 1 additions and 1 deletions
|
@ -1501,7 +1501,7 @@ public class CraftWorld extends CraftRegionAccessor implements World {
|
|||
Validate.notNull(spawnCategory, "SpawnCategory cannot be null");
|
||||
Validate.isTrue(CraftSpawnCategory.isValidForLimits(spawnCategory), "SpawnCategory." + spawnCategory + " are not supported.");
|
||||
|
||||
int limit = spawnCategoryLimit.getInt(spawnCategory);
|
||||
int limit = spawnCategoryLimit.getOrDefault(spawnCategory, -1);
|
||||
if (limit < 0) {
|
||||
limit = server.getSpawnLimit(spawnCategory);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue