mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-25 22:56:45 +01:00
we could just drop support for worldedit...
This commit is contained in:
parent
0d305463fc
commit
0aaf573186
@ -10,6 +10,8 @@ import com.sk89q.worldedit.LocalWorld;
|
||||
import com.sk89q.worldedit.Vector;
|
||||
import com.sk89q.worldedit.WorldEdit;
|
||||
import com.sk89q.worldedit.bukkit.BukkitPlayer;
|
||||
import com.sk89q.worldedit.function.mask.Mask;
|
||||
import com.sk89q.worldedit.function.mask.RegionMask;
|
||||
import com.sk89q.worldedit.regions.CuboidRegion;
|
||||
|
||||
/**
|
||||
@ -55,8 +57,7 @@ public class PWE {
|
||||
LocalWorld lw = PlotMain.worldEdit.wrapPlayer(p).getWorld();
|
||||
|
||||
CuboidRegion region = new CuboidRegion(lw, bvec, tvec);
|
||||
com.sk89q.worldedit.masks.RegionMask mask = new com.sk89q.worldedit.masks.RegionMask(region);
|
||||
|
||||
RegionMask mask = new RegionMask(region);
|
||||
s.setMask(mask);
|
||||
return;
|
||||
}
|
||||
@ -65,8 +66,7 @@ public class PWE {
|
||||
if (noMask(s)) {
|
||||
BukkitPlayer plr = PlotMain.worldEdit.wrapPlayer(p);
|
||||
Vector p1 = new Vector(69, 69, 69), p2 = new Vector(69, 69, 69);
|
||||
|
||||
s.setMask(new com.sk89q.worldedit.masks.RegionMask(new CuboidRegion(plr.getWorld(), p1, p2)));
|
||||
s.setMask(new RegionMask(new CuboidRegion(plr.getWorld(), p1, p2)));
|
||||
}
|
||||
}
|
||||
catch (Exception e) {
|
||||
@ -76,33 +76,13 @@ public class PWE {
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
public static boolean noMask(LocalSession s) {
|
||||
// try {
|
||||
// com.sk89q.worldedit.masks.Mask mask = s.getMask();
|
||||
// return mask == null;
|
||||
// }
|
||||
|
||||
|
||||
|
||||
// catch (Throwable e) {
|
||||
//
|
||||
//
|
||||
// return true;
|
||||
//
|
||||
//
|
||||
// }
|
||||
return true;
|
||||
return s.getMask() == null;
|
||||
}
|
||||
|
||||
public static void removeMask(Player p, LocalSession s) {
|
||||
// try {
|
||||
// s.setMask(null);
|
||||
// }
|
||||
// catch (Throwable e) {
|
||||
// com.sk89q.worldedit.masks.Mask mask = null;
|
||||
// s.setMask(mask);
|
||||
// }
|
||||
Mask mask = null;
|
||||
s.setMask(mask);
|
||||
}
|
||||
|
||||
public static void removeMask(Player p) {
|
||||
|
@ -6,8 +6,12 @@ package com.intellectualcrafters.plot.database.sqlobjects;
|
||||
public class PlotTable extends SQLTable {
|
||||
|
||||
public PlotTable() {
|
||||
super("plots");
|
||||
super("plots", name, fields);
|
||||
}
|
||||
|
||||
public
|
||||
@Override
|
||||
public void create() {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -71,7 +71,7 @@ public class WorldGenerator extends PlotGenerator {
|
||||
return manager;
|
||||
}
|
||||
/**
|
||||
* Allow spawning everywhere (up to server owners to keep it safe)
|
||||
* Allow spawning everywhere
|
||||
*/
|
||||
@Override
|
||||
public boolean canSpawn(World world, int x, int z) {
|
||||
|
Loading…
Reference in New Issue
Block a user