mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2025-07-04 22:54:43 +02:00
Compare commits
3 Commits
feat/plotB
...
fix/compon
Author | SHA1 | Date | |
---|---|---|---|
c77037ce47 | |||
746bf93813 | |||
a1d94af242 |
@ -37,7 +37,9 @@ import com.sk89q.worldedit.regions.CuboidRegion;
|
|||||||
import com.sk89q.worldedit.world.biome.BiomeType;
|
import com.sk89q.worldedit.world.biome.BiomeType;
|
||||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||||
import org.checkerframework.checker.nullness.qual.Nullable;
|
import org.checkerframework.checker.nullness.qual.Nullable;
|
||||||
|
import org.jetbrains.annotations.NotNull;
|
||||||
|
|
||||||
|
import java.util.Objects;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
public class FaweRegionManager extends BukkitRegionManager {
|
public class FaweRegionManager extends BukkitRegionManager {
|
||||||
@ -59,7 +61,10 @@ public class FaweRegionManager extends BukkitRegionManager {
|
|||||||
@Nullable PlotPlayer<?> actor,
|
@Nullable PlotPlayer<?> actor,
|
||||||
@Nullable QueueCoordinator queue
|
@Nullable QueueCoordinator queue
|
||||||
) {
|
) {
|
||||||
return delegate.setCuboids(area, regions, blocks, minY, maxY, queue.getCompleteTask());
|
return delegate.setCuboids(
|
||||||
|
area, regions, blocks, minY, maxY,
|
||||||
|
Objects.requireNonNullElseGet(queue, area::getQueue).getCompleteTask()
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -111,7 +116,7 @@ public class FaweRegionManager extends BukkitRegionManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean regenerateRegion(final Location pos1, final Location pos2, boolean ignore, final Runnable whenDone) {
|
public boolean regenerateRegion(final @NotNull Location pos1, final @NotNull Location pos2, boolean ignore, final Runnable whenDone) {
|
||||||
return delegate.regenerateRegion(pos1, pos2, ignore, whenDone);
|
return delegate.regenerateRegion(pos1, pos2, ignore, whenDone);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2401,7 +2401,8 @@ public class SQLManager implements AbstractDB {
|
|||||||
addPlotTask(plot, new UniqueStatement("setPosition") {
|
addPlotTask(plot, new UniqueStatement("setPosition") {
|
||||||
@Override
|
@Override
|
||||||
public void set(PreparedStatement statement) throws SQLException {
|
public void set(PreparedStatement statement) throws SQLException {
|
||||||
statement.setString(1, position == null ? "" : position);
|
// Please see the table creation statement. There is the default value of "default"
|
||||||
|
statement.setString(1, position == null ? "DEFAULT" : position);
|
||||||
statement.setInt(2, getId(plot));
|
statement.setInt(2, getId(plot));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1483,7 +1483,7 @@ public class Plot {
|
|||||||
*/
|
*/
|
||||||
public void setHome(BlockLoc location) {
|
public void setHome(BlockLoc location) {
|
||||||
Plot plot = this.getBasePlot(false);
|
Plot plot = this.getBasePlot(false);
|
||||||
if (BlockLoc.ZERO.equals(location) || BlockLoc.MINY.equals(location)) {
|
if (location != null && (BlockLoc.ZERO.equals(location) || BlockLoc.MINY.equals(location))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
plot.getSettings().setPosition(location);
|
plot.getSettings().setPosition(location);
|
||||||
|
Reference in New Issue
Block a user