made it so that anyone can run insult and praise
This commit is contained in:
parent
f857d39ff5
commit
3f9c99d8c2
@ -63,6 +63,7 @@ namespace NadekoBot {
|
|||||||
}
|
}
|
||||||
|
|
||||||
await Stop();
|
await Stop();
|
||||||
|
await Start();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void HandleAnswers() {
|
private void HandleAnswers() {
|
||||||
|
@ -164,24 +164,16 @@ namespace NadekoBot.Modules
|
|||||||
List<string> insults = new List<string> { " you are a poop.", " you jerk.", " i will eat you when i get my powers back." };
|
List<string> insults = new List<string> { " you are a poop.", " you jerk.", " i will eat you when i get my powers back." };
|
||||||
Random r = new Random();
|
Random r = new Random();
|
||||||
var u = e.Channel.FindUsers(e.GetArg("mention")).FirstOrDefault();
|
var u = e.Channel.FindUsers(e.GetArg("mention")).FirstOrDefault();
|
||||||
|
|
||||||
if (u == null) {
|
if (u == null) {
|
||||||
await e.Send("Invalid user specified.");
|
await e.Send("Invalid user specified.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (u.Id == NadekoBot.OwnerID)
|
if (u.Id == NadekoBot.OwnerID) {
|
||||||
{
|
|
||||||
await e.Send("I would never insult my master <3");
|
await e.Send("I would never insult my master <3");
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
else if (e.User.Id == NadekoBot.OwnerID)
|
|
||||||
{
|
|
||||||
await e.Send(u.Mention + insults[r.Next(0, insults.Count)]);
|
await e.Send(u.Mention + insults[r.Next(0, insults.Count)]);
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
await e.Send(e.User.Mention + " Eww, why would i do that for you ?!");
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand("praise")
|
cgb.CreateCommand("praise")
|
||||||
@ -189,7 +181,7 @@ namespace NadekoBot.Modules
|
|||||||
.Parameter("mention", ParameterType.Required)
|
.Parameter("mention", ParameterType.Required)
|
||||||
.Do(async e =>
|
.Do(async e =>
|
||||||
{
|
{
|
||||||
List<string> praises = new List<string> { " You are cool.", " You are nice... But don't get any wrong ideas.", " You did a good job." };
|
List<string> praises = new List<string> { " You are cool.", " You are nice!", " You did a good job.", " You did something nice.", " is awesome!" };
|
||||||
Random r = new Random();
|
Random r = new Random();
|
||||||
var u = e.Channel.FindUsers(e.GetArg("mention")).FirstOrDefault();
|
var u = e.Channel.FindUsers(e.GetArg("mention")).FirstOrDefault();
|
||||||
|
|
||||||
@ -199,26 +191,11 @@ namespace NadekoBot.Modules
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (e.User.Id == NadekoBot.OwnerID)
|
if (u.Id == NadekoBot.OwnerID) {
|
||||||
{
|
|
||||||
if (u.Id != NadekoBot.OwnerID)
|
|
||||||
await e.Send(u.Mention + praises[r.Next(0, praises.Count)]);
|
|
||||||
else
|
|
||||||
{
|
|
||||||
await e.Send(u.Mention + " No need, you know I love you <3");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (u.Id == NadekoBot.OwnerID)
|
|
||||||
{
|
|
||||||
await e.Send(e.User.Mention + " I don't need your permission to praise my beloved Master <3");
|
await e.Send(e.User.Mention + " I don't need your permission to praise my beloved Master <3");
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
else
|
await e.Send(u.Mention + praises[r.Next(0, praises.Count)]);
|
||||||
{
|
|
||||||
await e.Send(e.User.Mention + " Yeah... No.");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand("are you real")
|
cgb.CreateCommand("are you real")
|
||||||
|
Loading…
Reference in New Issue
Block a user