Example #1
0
 public PaginationService(DiscordShardedClient client)
 {
     if (Instance != null)
     {
         throw new InvalidOperationException("Cannot create another instance of a singleton");
     }
     Instance               = this;
     _messages              = new Dictionary <ulong, PageBase>();
     _client                = client;
     _client.ReactionAdded += _client_ReactionAdded;
 }
Example #2
0
		public Frequency3Client()
		{
			if(_instance != null)
			{
				throw new InvalidOperationException("Cannot create another instnace of a singleton.");
			}
			_client = new DiscordShardedClient(new DiscordSocketConfig
			{
				AlwaysDownloadUsers = true,
				LogLevel = LogSeverity.Info,
			});
			_commands = new CommandProvider(_client);
			_pagination = new PaginationService(_client);
			_config = BotConfiguration.Config;
			var lava = _config.LavaLinkSettings;
			
			_service = new AudioService(lava.Host, lava.Password, lava.Port, _client);
			_logger = new Logger(@$"{Environment.GetFolderPath(Environment.SpecialFolder.UserProfile)
}\Desktop\Logs\");