- Started cleanup of command handler

- Removed IUnloadableService
- Started removing INService (removed it from services which implement behavior interfaces) - wip
- Added scrutor for better service registration - wip
This commit is contained in:
Kwoth
2021-06-28 23:20:02 +02:00
parent 1e90d7f7bb
commit 3c82c1f919
30 changed files with 217 additions and 360 deletions

View File

@@ -1,6 +1,5 @@
using System.Threading.Tasks;
using Discord;
using Discord.WebSocket;
namespace NadekoBot.Common.ModuleBehaviors
{
@@ -12,7 +11,7 @@ namespace NadekoBot.Common.ModuleBehaviors
int Priority { get; }
ModuleBehaviorType BehaviorType { get; }
Task<bool> RunBehavior(DiscordSocketClient client, IGuild guild, IUserMessage msg);
Task<bool> RunBehavior(IGuild guild, IUserMessage msg);
}
public enum ModuleBehaviorType

View File

@@ -8,7 +8,6 @@ namespace NadekoBot.Common.ModuleBehaviors
{
public int Priority { get; }
Task<bool> TryBlockLate(DiscordSocketClient client, ICommandContext context,
string moduleName, CommandInfo command);
Task<bool> TryBlockLate(ICommandContext context, string moduleName, CommandInfo command);
}
}

View File

@@ -1,6 +1,5 @@
using System.Threading.Tasks;
using Discord;
using Discord.WebSocket;
namespace NadekoBot.Common.ModuleBehaviors
{
@@ -9,6 +8,6 @@ namespace NadekoBot.Common.ModuleBehaviors
/// </summary>
public interface ILateExecutor
{
Task LateExecute(DiscordSocketClient client, IGuild guild, IUserMessage msg);
Task LateExecute(IGuild guild, IUserMessage msg);
}
}