mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 01:37:37 +00:00
Don't require Selection classifier for region binding
This commit is contained in:
parent
f43faae917
commit
963d1192c2
@ -81,15 +81,14 @@ public class WorldEditBinding extends BindingHelper {
|
|||||||
* Gets a selection from a {@link ArgumentStack}.
|
* Gets a selection from a {@link ArgumentStack}.
|
||||||
*
|
*
|
||||||
* @param context the context
|
* @param context the context
|
||||||
* @param selection the annotation
|
|
||||||
* @return a selection
|
* @return a selection
|
||||||
* @throws IncompleteRegionException if no selection is available
|
* @throws IncompleteRegionException if no selection is available
|
||||||
* @throws ParameterException on other error
|
* @throws ParameterException on other error
|
||||||
*/
|
*/
|
||||||
@BindingMatch(classifier = Selection.class,
|
@BindingMatch(
|
||||||
type = Region.class,
|
type = Region.class,
|
||||||
behavior = BindingBehavior.PROVIDES)
|
behavior = BindingBehavior.PROVIDES)
|
||||||
public Object getSelection(ArgumentStack context, Selection selection) throws IncompleteRegionException, ParameterException {
|
public Object getSelection(ArgumentStack context) throws IncompleteRegionException, ParameterException {
|
||||||
Player sender = getPlayer(context);
|
Player sender = getPlayer(context);
|
||||||
LocalSession session = worldEdit.getSessionManager().get(sender);
|
LocalSession session = worldEdit.getSessionManager().get(sender);
|
||||||
return session.getSelection(FawePlayer.wrap(sender).getWorldForEditing());
|
return session.getSelection(FawePlayer.wrap(sender).getWorldForEditing());
|
||||||
|
Loading…
Reference in New Issue
Block a user