Disabled cleverot and flower generation on public bot

This commit is contained in:
Kwoth 2017-01-03 18:48:06 +01:00
parent 8ee66817b4
commit 96ede41e52
3 changed files with 7 additions and 2 deletions

View File

@ -88,7 +88,7 @@ namespace NadekoBot.Modules.Games
}
return true;
}
#if !GLOBAL_NADEKO
[NadekoCommand, Usage, Description, Aliases]
[RequireContext(ContextType.Guild)]
[RequireUserPermission(ChannelPermission.ManageMessages)]
@ -120,6 +120,7 @@ namespace NadekoBot.Modules.Games
await Context.Channel.SendConfirmAsync($"{Context.User.Mention} Enabled cleverbot on this server.").ConfigureAwait(false);
}
#endif
}
}
}

View File

@ -47,7 +47,10 @@ namespace NadekoBot.Modules.Games
_log = LogManager.GetCurrentClassLogger();
var sw = Stopwatch.StartNew();
#if !GLOBAL_NADEKO
NadekoBot.Client.MessageReceived += PotentialFlowerGeneration;
#endif
using (var uow = DbHandler.UnitOfWork())
{

View File

@ -124,10 +124,10 @@ namespace NadekoBot.Services
return;
}
#if !GLOBAL_NADEKO
try
{
var cleverbotExecuted = await Games.CleverBotCommands.TryAsk(usrMsg);
if (cleverbotExecuted)
{
_log.Info($@"CleverBot Executed
@ -139,6 +139,7 @@ namespace NadekoBot.Services
}
}
catch (Exception ex) { _log.Warn(ex, "Error in cleverbot"); }
#endif
try
{
// maybe this message is a custom reaction