mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-22 11:55:38 +01:00
template
This commit is contained in:
parent
81f3e6ef24
commit
0e9e813dbf
@ -29,6 +29,7 @@ import com.intellectualcrafters.plot.PlotSquared;
|
||||
import com.intellectualcrafters.plot.config.C;
|
||||
import com.intellectualcrafters.plot.object.PlotPlayer;
|
||||
import com.intellectualcrafters.plot.object.PlotWorld;
|
||||
import com.intellectualcrafters.plot.util.BlockManager;
|
||||
import com.intellectualcrafters.plot.util.MainUtil;
|
||||
|
||||
public class Template extends SubCommand {
|
||||
@ -42,9 +43,9 @@ public class Template extends SubCommand {
|
||||
MainUtil.sendMessage(plr, C.COMMAND_SYNTAX, "/plot template <import|export> <world>");
|
||||
return false;
|
||||
}
|
||||
final World world = Bukkit.getWorld(args[1]);
|
||||
final PlotWorld plotworld = PlotSquared.getPlotWorld(args[1]);
|
||||
if ((world == null) || (plotworld == null)) {
|
||||
String world = args[1];
|
||||
final PlotWorld plotworld = PlotSquared.getPlotWorld(world);
|
||||
if (!BlockManager.manager.isWorld(world) || (plotworld == null)) {
|
||||
MainUtil.sendMessage(plr, C.NOT_VALID_PLOT_WORLD);
|
||||
return false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user