Class SphereRegionSelector
java.lang.Object
com.sk89q.worldedit.regions.selector.EllipsoidRegionSelector
com.sk89q.worldedit.regions.selector.SphereRegionSelector
- All Implemented Interfaces:
CUIRegion
,RegionSelector
Creates a
SphereRegion
from a user's selections.-
Field Summary
Fields inherited from class com.sk89q.worldedit.regions.selector.EllipsoidRegionSelector
region, selectedRadius, started
-
Constructor Summary
ConstructorDescriptionCreate a new selector with anull world
.SphereRegionSelector
(RegionSelector oldSelector) Create a new selector from another one.SphereRegionSelector
(World world) Create a new selector.SphereRegionSelector
(World world, BlockVector3 center, int radius) Create a new selector. -
Method Summary
Modifier and TypeMethodDescriptionvoid
explainSecondarySelection
(Actor player, LocalSession session, BlockVector3 pos) Tell the player information about his/her secondary selection.Get a lowercase name of this region selector type.boolean
selectSecondary
(BlockVector3 position, SelectorLimits limits) Called when the second point is selected.Methods inherited from class com.sk89q.worldedit.regions.selector.EllipsoidRegionSelector
clear, describeCUI, describeLegacyCUI, explainPrimarySelection, explainRegionAdjust, getIncompleteRegion, getLegacyTypeID, getPrimaryPosition, getProtocolVersion, getRegion, getSelectionInfoLines, getTypeID, getVolume, getWorld, isDefined, learnChanges, selectPrimary, setWorld
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.sk89q.worldedit.regions.RegionSelector
getArea, getInformationLines
-
Constructor Details
-
SphereRegionSelector
public SphereRegionSelector()Create a new selector with anull world
. -
SphereRegionSelector
Create a new selector.- Parameters:
world
- the world, which may benull
-
SphereRegionSelector
Create a new selector from another one.- Parameters:
oldSelector
- the old selector
-
SphereRegionSelector
Create a new selector.- Parameters:
world
- the worldcenter
- the center positionradius
- the radius
-
-
Method Details
-
selectSecondary
Description copied from interface:RegionSelector
Called when the second point is selected.- Specified by:
selectSecondary
in interfaceRegionSelector
- Overrides:
selectSecondary
in classEllipsoidRegionSelector
- Parameters:
position
- the position- Returns:
- true if something changed
-
explainSecondarySelection
Description copied from interface:RegionSelector
Tell the player information about his/her secondary selection.- Specified by:
explainSecondarySelection
in interfaceRegionSelector
- Overrides:
explainSecondarySelection
in classEllipsoidRegionSelector
- Parameters:
player
- the actorsession
- the sessionpos
- position
-
getTypeName
Description copied from interface:RegionSelector
Get a lowercase name of this region selector type.- Specified by:
getTypeName
in interfaceRegionSelector
- Overrides:
getTypeName
in classEllipsoidRegionSelector
- Returns:
- a lower case name of the type
-