mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-01 05:47:45 +01:00
Fix timings check with tick freezes
This commit is contained in:
parent
80729ab0fd
commit
7d6c55f960
@ -196,7 +196,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||||||
gameprofilerfiller.push("filteringLoadedChunks");
|
gameprofilerfiller.push("filteringLoadedChunks");
|
||||||
- List<ServerChunkCache.ChunkAndHolder> list = Lists.newArrayListWithCapacity(this.chunkMap.size());
|
- List<ServerChunkCache.ChunkAndHolder> list = Lists.newArrayListWithCapacity(this.chunkMap.size());
|
||||||
- Iterator iterator = this.chunkMap.getChunks().iterator();
|
- Iterator iterator = this.chunkMap.getChunks().iterator();
|
||||||
this.level.timings.chunkTicks.startTiming(); // Paper
|
if (this.level.getServer().tickRateManager().runsNormally()) this.level.timings.chunkTicks.startTiming(); // Paper
|
||||||
|
|
||||||
- while (iterator.hasNext()) {
|
- while (iterator.hasNext()) {
|
||||||
- ChunkHolder playerchunk = (ChunkHolder) iterator.next();
|
- ChunkHolder playerchunk = (ChunkHolder) iterator.next();
|
||||||
|
@ -1079,7 +1079,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||||||
gameprofilerfiller.push("filteringLoadedChunks");
|
gameprofilerfiller.push("filteringLoadedChunks");
|
||||||
List<ServerChunkCache.ChunkAndHolder> list = Lists.newArrayListWithCapacity(this.chunkMap.size());
|
List<ServerChunkCache.ChunkAndHolder> list = Lists.newArrayListWithCapacity(this.chunkMap.size());
|
||||||
Iterator iterator = this.chunkMap.getChunks().iterator();
|
Iterator iterator = this.chunkMap.getChunks().iterator();
|
||||||
+ this.level.timings.chunkTicks.startTiming(); // Paper
|
+ if (this.level.getServer().tickRateManager().runsNormally()) this.level.timings.chunkTicks.startTiming(); // Paper
|
||||||
|
|
||||||
while (iterator.hasNext()) {
|
while (iterator.hasNext()) {
|
||||||
ChunkHolder playerchunk = (ChunkHolder) iterator.next();
|
ChunkHolder playerchunk = (ChunkHolder) iterator.next();
|
||||||
|
Loading…
Reference in New Issue
Block a user