package de.shiewk.smoderation.command; import de.shiewk.smoderation.SModeration; import de.shiewk.smoderation.inventory.SModMenu; import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.command.TabExecutor; import org.bukkit.entity.Player; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import java.util.List; public class SModCommand implements TabExecutor { @Override public boolean onCommand(@NotNull CommandSender commandSender, @NotNull Command command, @NotNull String s, @NotNull String[] strings) { if (commandSender instanceof Player player){ new SModMenu(player, SModeration.container).open(); } return true; } @Override public @Nullable List onTabComplete(@NotNull CommandSender commandSender, @NotNull Command command, @NotNull String s, @NotNull String[] strings) { return List.of(); } }