]> jfr.im git - z_archive/kelsier.git/blob - Command.cs
Adding auth
[z_archive/kelsier.git] / Command.cs
1 // Kelsier project - Command info code (Command.cs)
2 // Written by the Jobbig codeteam. <http://jobbig.eu/code/>
3 //
4 // Copyright 2013 John Runyon.
5 //
6 // This file is part of the Kelsier project.
7 //
8 // Kelsier is free software: you can redistribute it and/or modify
9 // it under the terms of the GNU Affero General Public License as published by
10 // the Free Software Foundation, either version 3 of the License, or
11 // (at your option) any later version.
12 //
13 // This program is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 // GNU Affero General Public License for more details.
17 //
18 // You should have received a copy of the GNU Affero General Public License
19 // along with this program. If not, see <http://www.gnu.org/licenses/>.
20 //
21
22 using System;
23 namespace Kelsier.Common {
24 public class Command {
25 public Bot bot { get; private set; }
26 public string cmd { get; private set; }
27 public string[] args { get; private set; }
28 public User user { get; private set; }
29 public Channel chan { get; private set; }
30 public bool chanmsg { get; private set; }
31 public string replyTo { get; private set; }
32
33 public Command(Bot bot, string cmd, string[] args, User user, Channel chan, bool chanmsg) {
34 this.bot = bot;
35 this.cmd = cmd;
36 this.args = args;
37 this.user = user;
38 this.chan = chan;
39 this.chanmsg = chanmsg;
40 if (chanmsg)
41 this.replyTo = chan.name;
42 else
43 this.replyTo = user.nick;
44 }
45 }
46 }
47