1
0
Fork 0
mirror of https://github.com/PaperMC/Paper.git synced 2025-02-16 18:31:53 +01:00

Allow spawners to be disabled without adding a stupid high tick rate ()

This commit is contained in:
HexedHero 2021-10-31 07:51:57 +00:00
parent fed4fa20ae
commit e0cac960b1

View file

@ -37,6 +37,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ // Paper start - Configurable mob spawner tick rate
+ if (spawnDelay > 0 && --tickDelay > 0) return;
+ tickDelay = world.paperConfig.mobSpawnerTickRate;
+ if (tickDelay == -1) { return; } // If disabled
+ // Paper end
if (this.isNearPlayer(world, pos)) {
- if (this.spawnDelay == -1) {