-
Notifications
You must be signed in to change notification settings - Fork 1
/
UrIRC.u
51 lines (39 loc) · 1.31 KB
/
UrIRC.u
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
48
49
50
/*
The porpose of this class is to hold all the UrIRC library.
Every library class will be an UrIRC slot.
By beeing a slot of Object, we make this lib accessible everywhere.
One problem of urbiscript classes is that you can't access a class inside another due to the protyped programming orientation.
Problem:
class A {}; // A is now a slot of Lobby
class B { // B is now a slot of Lobby
var a = A.new // lookup error, B does not provide an A slot
};
Solution:
class Object.Lib {}; // Lib is now a slot of Object
class Lib.A {}; // A is now a slot of Lib
class B {}
var a = Lib.A.new; // ok
;
While adding only one slot to Object, we are now able to access all the Lib classes.
*/
class Object.UrIRC {
};
/*
* Load all plugins
* Soon : autoload plugins
* Urbi error in case of recursive require : NOTHING.
* This is the reason of this "lib scale" require
*/
requireFile("core/UrPlugin.u");
requireFile("core/UrChan.u");
requireFile("core/UrUser.u");
requireFile("core/UrBot.u");
requireFile("core/UrSocket.u");
requireFile("core/UrPong.u");
requireFile("core/UrEventDispatcher.u");
requireFile("plugins/UrHelloWorld.u");
requireFile("plugins/UrParrot.u");
requireFile("plugins/UrAutoKick.u");
requireFile("plugins/UrQueryOnKick.u");
requireFile("plugins/UrVoteKick.u");
requireFile("plugins/UrRandomReply.u");