Use Google's reflection library to register commands

This commit is contained in:
Focusvity
2022-03-19 14:33:23 +11:00
parent 6a569bb638
commit cc97612101
11 changed files with 97 additions and 41 deletions

View File

@ -4,6 +4,7 @@ import com.google.common.collect.ImmutableList;
import dev.plex.command.PlexCommand;
import dev.plex.command.annotation.CommandParameters;
import dev.plex.command.annotation.CommandPermissions;
import dev.plex.command.annotation.System;
import dev.plex.rank.enums.Rank;
import dev.plex.util.PlexUtils;
import java.util.List;
@ -15,6 +16,7 @@ import org.jetbrains.annotations.Nullable;
@CommandParameters(name = "deop", description = "Deop a player on the server", usage = "/<command> <player>")
@CommandPermissions(level = Rank.ADMIN, permission = "plex.deop")
@System("ranks")
public class DeopCMD extends PlexCommand
{
@Override