-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathFact.cs
47 lines (39 loc) · 886 Bytes
/
Fact.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
using System.Collections.Specialized;
using MikuBot.Commands;
using MikuBot.Modules;
namespace MikuBot.ExtraPlugins
{
public class Fact : MsgCommandModuleBase
{
private readonly StringCollection facts = new StringCollection {
"Miku's favorite food is Japanese green onions (negis)",
"Teto's favorite food is French Bread"
};
public override int CooldownChannelMs
{
get { return 1000; }
}
public override int CooldownUserMs
{
get { return 30000; }
}
public override string CommandDescription
{
get
{
return "Get your Vocaloid/UTAU facts.";
}
}
public override string Name
{
get { return "Fact"; }
}
public override void HandleCommand(MsgCommand msg, IBotContext bot)
{
if (!CheckCall(msg, bot))
return;
var fact = BotHelper.ChooseRandom(facts);
bot.Writer.Msg(msg.ChannelOrSenderNick, fact);
}
}
}