Update to version 2.9.3a
[tropbot.git] / objects.h
1 //-----------------------------------------------------------------------------
2
3 #ifndef OBJECTS_H
4 #define OBJECTS_H
5
6 #include "list.cc"
7
8 #define LEVEL_MAX 4
9 #define LEVEL_MASTER 4
10 #define LEVEL_DEFENCE 3
11 #define LEVEL_OP 2
12 #define LEVEL_FRIEND 1
13
14 enum
15 {
16   MODE_SHIT_NICK, MODE_SHIT_SITE, MODE_SHIT_HOST,
17   MODE_UNSHIT_NICK, MODE_UNBAN_NICK,
18   MODE_FILTER_KICK,
19   MODE_BAN_NICK, MODE_BAN_SITE,
20   MODE_LEVEL,
21   MODE_SHITLIST,
22   MODE_MSG
23 };
24
25 //-----------------------------------------------------------------------------
26
27 class DCCChat
28 {
29 public:
30   char *prefix;
31   int socket;
32   int level;
33 public:
34   DCCChat(char *p, int s, int l);
35   ~DCCChat();
36 };
37
38 class WaitPing
39 {
40 public:
41   char *nick, *value;
42   int time_max;
43 public:
44   WaitPing(char *n, char *v, int t);
45   ~WaitPing();
46 };
47
48 class WaitInfos
49 {
50 public:
51   DCCChat *chat;
52   char *nick, *comment, *user;
53   int mode;
54   int duration;
55 public:
56   WaitInfos(char *n, char *c, DCCChat *ch, char *u, int m, int d);
57   ~WaitInfos();
58 };
59
60 class Welcome
61 {
62 public:
63   char *pattern, *comment;
64   int time_max;
65 public:
66   Welcome(char *p, char *c, int time);
67   ~Welcome();
68 };
69
70 class DelayModeChange
71 {
72 public:
73   char *where, *mode, *parameter;
74   int time;
75 public:
76   DelayModeChange(char *w, char *m, char *p, int delay);
77   ~DelayModeChange();
78 };
79
80 class Person
81 {
82 public:
83   char *pattern;
84   char *passwd;
85   int level;
86 public:
87   Person(char *p, int l, char *pwd);
88   ~Person();
89 };
90
91 //-----------------------------------------------------------------------------
92
93 #endif