Class ContainingOwnedRegionArgumentType
java.lang.Object
de.z0rdak.yawp.commands.arguments.region.ContainingOwnedRegionArgumentType
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<String>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic IMarkableRegiongetRegion(com.mojang.brigadier.context.CommandContext<net.minecraft.commands.CommandSourceStack> context, String argName) static IMarkableRegiongetRegionWithMarker(com.mojang.brigadier.context.CommandContext<net.minecraft.commands.CommandSourceStack> context, String argName) <S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder) Suggests regions with permission, which are also fully containing the area provided by the create local command<S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> listSuggestionsWithMarker(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder) Suggests regions with permission, which are also fully containing the area provided by the marked blocks of the region markerUsing this as an actual argument does not work on a server-side only mod, because it needs to be registered in the corresponding registry.parse(com.mojang.brigadier.StringReader reader) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.mojang.brigadier.arguments.ArgumentType
parse
-
Field Details
-
VALID_NAME_PATTERN
-
-
Constructor Details
-
ContainingOwnedRegionArgumentType
public ContainingOwnedRegionArgumentType()
-
-
Method Details
-
owningRegions
Using this as an actual argument does not work on a server-side only mod, because it needs to be registered in the corresponding registry. -
getRegion
public static IMarkableRegion getRegion(com.mojang.brigadier.context.CommandContext<net.minecraft.commands.CommandSourceStack> context, String argName) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getRegionWithMarker
public static IMarkableRegion getRegionWithMarker(com.mojang.brigadier.context.CommandContext<net.minecraft.commands.CommandSourceStack> context, String argName) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
parse
public String parse(com.mojang.brigadier.StringReader reader) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Specified by:
parsein interfacecom.mojang.brigadier.arguments.ArgumentType<String>- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
listSuggestionsWithMarker
public <S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> listSuggestionsWithMarker(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder) Suggests regions with permission, which are also fully containing the area provided by the marked blocks of the region marker -
listSuggestions
public <S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder) Suggests regions with permission, which are also fully containing the area provided by the create local command- Specified by:
listSuggestionsin interfacecom.mojang.brigadier.arguments.ArgumentType<String>
-
getExamples
- Specified by:
getExamplesin interfacecom.mojang.brigadier.arguments.ArgumentType<String>
-