Search in sources :

Example 1 with EntitySelectorParserAccessor

use of org.spongepowered.common.accessor.commands.arguments.selector.EntitySelectorParserAccessor in project SpongeCommon by SpongePowered.

the class SpongeSelectorType method toBuilder.

@SuppressWarnings("ConstantConditions")
@Override
public final Selector.@NonNull Builder toBuilder() {
    final EntitySelectorParser parser = new EntitySelectorParser(new StringReader(this.selectorToken));
    ((EntitySelectorParserAccessor) parser).invoker$parseSelector();
    return (Selector.Builder) parser;
}
Also used : EntitySelectorParser(net.minecraft.commands.arguments.selector.EntitySelectorParser) StringReader(com.mojang.brigadier.StringReader) EntitySelectorParserAccessor(org.spongepowered.common.accessor.commands.arguments.selector.EntitySelectorParserAccessor)

Aggregations

StringReader (com.mojang.brigadier.StringReader)1 EntitySelectorParser (net.minecraft.commands.arguments.selector.EntitySelectorParser)1 EntitySelectorParserAccessor (org.spongepowered.common.accessor.commands.arguments.selector.EntitySelectorParserAccessor)1