Class PlayerArgumentType
-
- All Implemented Interfaces:
-
com.mojang.brigadier.arguments.ArgumentType
public class PlayerArgumentType implements ArgumentType<T>
玩家选择器参数类型
-
-
Method Summary
Modifier and Type Method Description static PlayerArgumentType
player()
static Player
getPlayer(@NonNull() CommandContext<CommandSender> context, @NonNull() String name)
static PlayerSelector
getPlayerSelector(@NonNull() CommandContext<CommandSender> context, @NonNull() String name)
PlayerSelector
parse(@NonNull() StringReader reader)
<S> CompletableFuture<Suggestions>
listSuggestions(@NonNull() CommandContext<S> context, @NonNull() SuggestionsBuilder builder)
Collection<String>
getExamples()
-
-
Method Detail
-
player
@NonNull() static PlayerArgumentType player()
-
getPlayer
@Nullable() static Player getPlayer(@NonNull() CommandContext<CommandSender> context, @NonNull() String name)
-
getPlayerSelector
@NonNull() static PlayerSelector getPlayerSelector(@NonNull() CommandContext<CommandSender> context, @NonNull() String name)
-
parse
@NonNull() PlayerSelector parse(@NonNull() StringReader reader)
-
listSuggestions
<S> CompletableFuture<Suggestions> listSuggestions(@NonNull() CommandContext<S> context, @NonNull() SuggestionsBuilder builder)
-
getExamples
@NonNull() Collection<String> getExamples()
-
-
-
-