How can I use custom args using Aikar Command Framework?
I've created a class like this:
@Getter
@Setter
@RequiredArgsConstructor
public class Arena {
private final UUID id;
private final String name;
private final ArenaType type;
private final World world;
private final int maxPlayers;
private final Map<TeamColor, Location> spawns;
private final Map<GeneratorType, List<Location>> generators;
private final Location lobby;
private final Location[] shop, upgrade, beds;
private GameStatus status = GameStatus.WAITING;
}
And I would like to use it inside a subcommand arg
public void join(final CommandSender sender, Arena arena) {
How can I make it resolve the arg?
(Transform the player string to an arena obj)