Exemple #1
0
        public static bool LoadInto(BotBitsClient client, ListeningBehavior listeningBehavior, params char[] commandPrefixes)
        {
            if (commandPrefixes.Length == 0)
            {
                throw new ArgumentException("At least one command prefix must be provided.", nameof(commandPrefixes));
            }

            return(LoadInto(client, new Settings(commandPrefixes, listeningBehavior)));
        }
Exemple #2
0
 public CakeSetup WithCommandsExtension(ListeningBehavior listeningBehavior, params char[] commandPrefixes)
 {
     this._actions += bot => CommandsExtension.LoadInto(bot, listeningBehavior, commandPrefixes);
     return(this);
 }
Exemple #3
0
 public Settings(char[] commandPrefixes, ListeningBehavior listeningBehavior = ListeningBehavior.Both)
 {
     this.CommandPrefixes   = commandPrefixes;
     this.ListeningBehavior = listeningBehavior;
 }