mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2025-06-25 02:04:44 +02:00
Move comments to ChunkCoordinator, remove Range annotations
This commit is contained in:
@ -38,7 +38,6 @@ import org.bukkit.World;
|
||||
import org.bukkit.block.Biome;
|
||||
import org.bukkit.generator.BlockPopulator;
|
||||
import org.bukkit.generator.ChunkGenerator;
|
||||
import org.jetbrains.annotations.Range;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
import java.util.Random;
|
||||
@ -72,8 +71,7 @@ final class DelegatePlotGenerator extends IndependentPlotGenerator {
|
||||
Random random = new Random(MathMan.pair((short) chunkX, (short) chunkZ));
|
||||
try {
|
||||
ChunkGenerator.BiomeGrid grid = new ChunkGenerator.BiomeGrid() {
|
||||
@Override public void setBiome(@Range(from = 0, to = 15) int x,
|
||||
@Range(from = 0, to = 15) int z, @Nonnull Biome biome) {
|
||||
@Override public void setBiome(int x, int z, @Nonnull Biome biome) {
|
||||
result.setBiome(x, z, BukkitAdapter.adapt(biome));
|
||||
}
|
||||
|
||||
|
@ -97,9 +97,6 @@ public final class BukkitChunkCoordinator extends ChunkCoordinator {
|
||||
this.bukkitWorld = Bukkit.getWorld(world.getName());
|
||||
}
|
||||
|
||||
/**
|
||||
* Start the coordinator instance
|
||||
*/
|
||||
@Override public void start() {
|
||||
// Request initial batch
|
||||
this.requestBatch();
|
||||
@ -195,20 +192,10 @@ public final class BukkitChunkCoordinator extends ChunkCoordinator {
|
||||
chunk.removePluginChunkTicket(this.plugin);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the amount of remaining chunks (at the time of the method call)
|
||||
*
|
||||
* @return Snapshot view of remaining chunk count
|
||||
*/
|
||||
@Override public int getRemainingChunks() {
|
||||
return this.expectedSize.get();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the amount of requested chunks
|
||||
*
|
||||
* @return Requested chunk count
|
||||
*/
|
||||
@Override public int getTotalChunks() {
|
||||
return this.totalSize;
|
||||
}
|
||||
|
Reference in New Issue
Block a user