From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Beech Horn Date: Fri, 14 Feb 2020 19:39:59 +0000 Subject: [PATCH] Skip distance map update when spawning disabled. diff --git a/src/main/java/net/minecraft/server/level/ChunkProviderServer.java b/src/main/java/net/minecraft/server/level/ChunkProviderServer.java index f46f3ca87badefd668e70d792de5b3d3c0172a68..e542fe5fb63064e67c7fde8fad614826d6f3344c 100644 --- a/src/main/java/net/minecraft/server/level/ChunkProviderServer.java +++ b/src/main/java/net/minecraft/server/level/ChunkProviderServer.java @@ -825,7 +825,7 @@ public class ChunkProviderServer extends IChunkProvider { int l = this.chunkMapDistance.b(); // Paper start - per player mob spawning SpawnerCreature.d spawnercreature_d; // moved down - if (this.playerChunkMap.playerMobDistanceMap != null) { + if ((this.allowAnimals || this.allowMonsters) && this.playerChunkMap.playerMobDistanceMap != null) { // don't update when animals and monsters are disabled // update distance map this.world.timings.playerMobDistanceMapUpdate.startTiming(); this.playerChunkMap.playerMobDistanceMap.update(this.world.players, this.playerChunkMap.viewDistance);