mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2025-07-06 20:56:41 +00:00
This commit is contained in:
@ -26,6 +26,7 @@ import com.sk89q.worldedit.math.BlockVector3;
|
||||
import com.sk89q.worldedit.regions.selector.limit.SelectorLimits;
|
||||
import com.sk89q.worldedit.world.World;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
@ -156,4 +157,12 @@ public interface RegionSelector {
|
||||
*/
|
||||
List<String> getInformationLines();
|
||||
|
||||
/**
|
||||
* Get the verticies
|
||||
* @return
|
||||
* @throws IncompleteRegionException
|
||||
*/
|
||||
default List<BlockVector3> getVerticies() throws IncompleteRegionException {
|
||||
return Collections.singletonList(getPrimaryPosition());
|
||||
}
|
||||
}
|
||||
|
@ -277,4 +277,8 @@ public class ConvexPolyhedralRegionSelector implements RegionSelector, CUIRegion
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<BlockVector3> getVerticies() {
|
||||
return new ArrayList<>(region.getVertices());
|
||||
}
|
||||
}
|
||||
|
@ -36,6 +36,7 @@ import com.sk89q.worldedit.world.World;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -300,4 +301,8 @@ public class CuboidRegionSelector implements RegionSelector, CUIRegion {
|
||||
return "cuboid";
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<BlockVector3> getVerticies() {
|
||||
return Arrays.asList(position1, position2);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user