mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-11-27 21:27:44 +01:00
parent
77f9f4869b
commit
4958304aa5
@ -86,6 +86,13 @@ public class Settings implements DataObject {
|
||||
@ConfigEntry(path = "panel.close-on-click-outside")
|
||||
private boolean closePanelOnClickOutside = true;
|
||||
|
||||
@ConfigComment("Toggle whether superflat chunks regeneration should be logged in the server logs or not.")
|
||||
@ConfigComment("It can be spammy if there are a lot of superflat chunks to regenerate.")
|
||||
@ConfigComment("However, as superflat chunks regeneration can be performance-intensive, it is recommended to keep")
|
||||
@ConfigComment("this setting set to true, as it will help you know if there are regenerations taking place.")
|
||||
@ConfigEntry(path = "logs.clean-super-flat-chunks", since = "1.1")
|
||||
private boolean logCleanSuperFlatChunks = true;
|
||||
|
||||
/*
|
||||
* Island
|
||||
*/
|
||||
@ -418,4 +425,12 @@ public class Settings implements DataObject {
|
||||
public void setUniqueId(String uniqueId) {
|
||||
this.uniqueId = uniqueId;
|
||||
}
|
||||
|
||||
public boolean isLogCleanSuperFlatChunks() {
|
||||
return logCleanSuperFlatChunks;
|
||||
}
|
||||
|
||||
public void setLogCleanSuperFlatChunks(boolean logCleanSuperFlatChunks) {
|
||||
this.logCleanSuperFlatChunks = logCleanSuperFlatChunks;
|
||||
}
|
||||
}
|
@ -75,7 +75,9 @@ public class CleanSuperFlatListener extends FlagListener {
|
||||
if (!chunkQueue.isEmpty()) {
|
||||
Pair<Integer, Integer> chunkXZ = chunkQueue.poll();
|
||||
world.regenerateChunk(chunkXZ.x, chunkXZ.z); // NOSONAR - the deprecation doesn't cause any issues to us
|
||||
plugin.log(chunkQueue.size() + " Regenerating superflat chunk " + world.getName() + " " + chunkXZ.x + ", " + chunkXZ.z);
|
||||
if (plugin.getSettings().isLogCleanSuperFlatChunks()) {
|
||||
plugin.log(chunkQueue.size() + " Regenerating superflat chunk " + world.getName() + " " + chunkXZ.x + ", " + chunkXZ.z);
|
||||
}
|
||||
}
|
||||
}, 0L, 1L);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user