Esempio n. 1
0
 public OwnerModule(DiscordSocketClient client,
                    ISettings settings,
                    ILogger <OwnerModule> logger,
                    IDiscordBotSettingsRepository discordBotSettingsRepository,
                    LavaNode lavaNode,
                    IServerService servers,
                    IServerRepository serverRepository)
 {
     _client   = client;
     _settings = settings;
     _logger   = logger;
     _discordBotSettingsRepository = discordBotSettingsRepository;
     _lavaNode         = lavaNode;
     _servers          = servers;
     _serverRepository = serverRepository;
 }
Esempio n. 2
0
        public DiscordService(IServiceProvider serviceProvider,
                              DiscordSocketClient client,
                              IConfiguration configuration,
                              CommandService commands,
                              ILogger <DiscordService> logger,
                              IDiscordBotSettingsRepository discordBotSettingsRepository,
                              LavaNode lavaNode,
                              IServerService servers,
                              ISettings settings)
        {
            _serviceProvider = serviceProvider;
            _client          = client;
            _configuration   = configuration;
            _commands        = commands;
            _logger          = logger;
            _discordBotSettingsRepository = discordBotSettingsRepository;
            _lavaNode = lavaNode;
            _servers  = servers;
            _settings = settings;

            _client.Ready           += OnReady;
            _client.MessageReceived += OnMessageReceived;
            _client.Disconnected    += OnDisconncted;
        }