mirror of
https://github.com/TotalFreedomMC/TF-PlotSquared.git
synced 2024-12-23 00:15:06 +00:00
Fixes #972
This commit is contained in:
parent
9e32ce9885
commit
fe43143bdb
1 changed files with 3 additions and 4 deletions
|
@ -23,7 +23,6 @@ package com.intellectualcrafters.plot.commands;
|
|||
import com.intellectualcrafters.plot.config.C;
|
||||
import com.intellectualcrafters.plot.config.Settings;
|
||||
import com.intellectualcrafters.plot.flag.FlagManager;
|
||||
import com.intellectualcrafters.plot.object.Location;
|
||||
import com.intellectualcrafters.plot.object.Plot;
|
||||
import com.intellectualcrafters.plot.object.PlotPlayer;
|
||||
import com.intellectualcrafters.plot.util.MainUtil;
|
||||
|
@ -40,8 +39,7 @@ public class Continue extends SubCommand {
|
|||
|
||||
@Override
|
||||
public boolean onCommand(final PlotPlayer plr, final String[] args) {
|
||||
final Location loc = plr.getLocation();
|
||||
final Plot plot = loc.getPlotAbs();
|
||||
final Plot plot = plr.getCurrentPlot();
|
||||
if ((plot == null) || !plot.hasOwner()) {
|
||||
return !sendMessage(plr, C.NOT_IN_PLOT);
|
||||
}
|
||||
|
@ -53,7 +51,8 @@ public class Continue extends SubCommand {
|
|||
MainUtil.sendMessage(plr, C.DONE_NOT_DONE);
|
||||
return false;
|
||||
}
|
||||
if (Settings.DONE_COUNTS_TOWARDS_LIMIT && (plr.getAllowedPlots() >= plr.getPlotCount())) {
|
||||
int size = plot.getConnectedPlots().size();
|
||||
if (Settings.DONE_COUNTS_TOWARDS_LIMIT && (plr.getAllowedPlots() < plr.getPlotCount() + size)) {
|
||||
MainUtil.sendMessage(plr, C.NO_PERMISSION, "plots.admin.command.continue");
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue