Search in sources :

Example 6 with CommandInfo

use of ws.nmathe.saber.commands.CommandInfo in project Saber-Bot by notem.

the class ListCommand method info.

@Override
public CommandInfo info(String prefix) {
    String head = prefix + this.name();
    String usage = "``" + head + "`` - show an event's rsvp list";
    CommandInfo info = new CommandInfo(usage, CommandInfo.CommandType.USER);
    String cat1 = "- Usage\n" + head + " <ID> [mode] [filters]";
    String cont1 = "The list command will show all users who have rsvp'ed yes.\n" + "The command takes a single argument which should be the ID of the event you wish query." + "\n\n" + "The schedule holding the event must have 'rsvp' turned on in the configuration settings.\n" + "RSVP can be enabled on a channel using the config command as followed, ``" + prefix + "config #channel rsvp on``" + "\n\n" + "The list may be filtered by either users or roles by appending \"r: @role\", \"u: @user\", or " + "\"t: [type]\" to the command.\n" + "Any number of filters may be appended to the command.\n" + "To display only users who have not rsvp'ed, use *no-input* as the ``[type]``." + "\n\n" + "The list command has two optional 'modes' of display. \n" + "If the term 'mobile' is added as an argument to the command, non-mentionable usernames will be displayed.\n" + "If the term 'id' is added as an argument, usernames will be displayed as they escaped mentionable ID tags.";
    info.addUsageCategory(cat1, cont1);
    info.addUsageExample(head + " 01JAO3");
    info.addUsageExample(head + " 01JAO3 \"u: @notem\"");
    info.addUsageExample(head + " 01JAO3 mobile \"t: yes\" \"t: no\"");
    return info;
}
Also used : CommandInfo(ws.nmathe.saber.commands.CommandInfo)

Example 7 with CommandInfo

use of ws.nmathe.saber.commands.CommandInfo in project Saber-Bot by notem.

the class HelpCommand method info.

@Override
public CommandInfo info(String prefix) {
    String head = prefix + this.name();
    String usage = "``" + head + "`` - receive info messages";
    CommandInfo info = new CommandInfo(usage, CommandInfo.CommandType.USER);
    String cat1 = "- Usage\n" + head + " [<command name>]";
    String cont1 = "This commands provides access to the command help documentation.\n" + "To get detailed information concerning the usage of any particular" + " commands use the command ``" + head + " <command>`` where the prefix for <command> is stripped off.\n\n";
    info.addUsageCategory(cat1, cont1);
    return info;
}
Also used : CommandInfo(ws.nmathe.saber.commands.CommandInfo)

Example 8 with CommandInfo

use of ws.nmathe.saber.commands.CommandInfo in project Saber-Bot by notem.

the class InitCommand method info.

@Override
public CommandInfo info(String prefix) {
    String head = prefix + this.name();
    String usage = "``" + head + "`` - initialize a new schedule";
    CommandInfo info = new CommandInfo(usage, CommandInfo.CommandType.CORE);
    String cat1 = "- Usage\n" + head + " [<channel>|<name>]";
    String cont1 = "With this bot, all events must be placed on a schedule." + "\nSchedules are discord channels which are used to store and display the details of an event." + "\n\n" + "This command is used to either create a new schedule or to convert an existing channel to a schedule.\n" + "Converting a channel to schedule can only be undone by deleting the schedule.\n" + "Existing messages in that schedule will not be removed." + "\n\n" + "The single argument the command takes is optional." + "\nThe argument should either be an existing #channel, or the name of the schedule you wish to create." + "\nIf omitted, a new schedule named 'new_schedule' will be created.";
    info.addUsageCategory(cat1, cont1);
    info.addUsageExample(head);
    info.addUsageExample(head + " \"Guild Events\"");
    info.addUsageExample(head + " #events");
    return info;
}
Also used : CommandInfo(ws.nmathe.saber.commands.CommandInfo)

Example 9 with CommandInfo

use of ws.nmathe.saber.commands.CommandInfo in project Saber-Bot by notem.

the class TestCommand method info.

@Override
public CommandInfo info(String prefix) {
    String head = prefix + this.name();
    String usage = "``" + head + "`` - test an event's announcement message";
    CommandInfo info = new CommandInfo(usage, CommandInfo.CommandType.MISC);
    String cat1 = "- Usage\n" + head + " <ID> [<type>]";
    String cont1 = "The test command will send an test announcement for the event to the channel in which the command was used.\n" + "The announcement message for an event is controlled by the schedule to which the event belongs to, and " + "can be changed using the ``config`` command." + "\n\n" + "An optional ``<type>`` argument can be supplied.\n" + "The ``<type>`` argument is used to determine which announcement type to test.\n" + "Valid options are: **start**, **end**, and **remind**.";
    info.addUsageCategory(cat1, cont1);
    info.addUsageExample(head + " J09DlA");
    info.addUsageExample(head + " J09DlA end");
    info.addUsageExample(head + " J09DlA remind");
    return info;
}
Also used : CommandInfo(ws.nmathe.saber.commands.CommandInfo)

Example 10 with CommandInfo

use of ws.nmathe.saber.commands.CommandInfo in project Saber-Bot by notem.

the class TimeZonesCommand method info.

@Override
public CommandInfo info(String prefix) {
    String head = prefix + this.name();
    String usage = "``" + head + "`` - show available timezones";
    CommandInfo info = new CommandInfo(usage, CommandInfo.CommandType.MISC);
    String cat1 = "- Usage\n" + head + " <filter>";
    String cont1 = "The zones command will provide a list of valid timezone strings for schedule configuration." + "\nA search filter argument is required (ex. ``us``).";
    info.addUsageCategory(cat1, cont1);
    info.addUsageExample(head + " america");
    info.addUsageExample(head + " tokyo");
    return info;
}
Also used : CommandInfo(ws.nmathe.saber.commands.CommandInfo)

Aggregations

CommandInfo (ws.nmathe.saber.commands.CommandInfo)20 Command (ws.nmathe.saber.commands.Command)1