mirror of
https://github.com/SunNetservers/MiniGames.git
synced 2025-04-04 18:56:25 +02:00
30 lines
848 B
Java
30 lines
848 B
Java
package net.knarcraft.dropper.command;
|
|
|
|
import net.knarcraft.dropper.util.TabCompleteHelper;
|
|
import org.bukkit.command.Command;
|
|
import org.bukkit.command.CommandSender;
|
|
import org.bukkit.command.TabCompleter;
|
|
import org.jetbrains.annotations.NotNull;
|
|
import org.jetbrains.annotations.Nullable;
|
|
|
|
import java.util.ArrayList;
|
|
import java.util.List;
|
|
|
|
/**
|
|
* The tab-completer for the remove arena command
|
|
*/
|
|
public class RemoveArenaTabCompleter implements TabCompleter {
|
|
|
|
@Nullable
|
|
@Override
|
|
public List<String> onTabComplete(@NotNull CommandSender commandSender, @NotNull Command command, @NotNull String s,
|
|
@NotNull String[] arguments) {
|
|
if (arguments.length == 1) {
|
|
return TabCompleteHelper.getArenas();
|
|
} else {
|
|
return new ArrayList<>();
|
|
}
|
|
}
|
|
|
|
}
|