-
Notifications
You must be signed in to change notification settings - Fork 0
/
modmode.txt
40 lines (36 loc) · 1.08 KB
/
modmode.txt
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
$${
// USE: Bind to onChat and copy paste the modmode gui section from .gui.xml to your own .gui.xml
// NOTE: This is completely useless to non-staff.
UNSAFE(0);
IFMATCHES(%CHATCLEAN%,^\[(Auc|Tr|G|D|L)\] [^ ]+ has been kicked.);
ELSE;
IFMATCHES(%CHATCLEAN%,^\[(Auc|Tr|G|D|L)\]);
MATCH(%CHAT%,^[^:]*: (.+),{&chat})
MATCH(%CHAT%,^..\[(.+?)\]\s?.*?\]?[^\]]*\]? ([^:]+)(.[0-9a-f]): .*,{&channel,&username,&chatcolor});
SET(&newchat,%&chatcolor%%&chat%);
#id = 15;
DO(15);
#id2 = %#id%-1;
SET(@&zcolor[%#id%],%@&zcolor[%#id2%]%);
SET(@&zchat[%#id%],%@&zchat[%#id2%]%);
SET(@&zname[%#id%],%@&zname[%#id2%]%);
SET(@&zchannel[%#id%],%@&zchannel[%#id2%]%);
DEC(#id);
LOOP;
SET(@&zcolor[0],%&chatcolor%);
SET(@&zname[0],%&username%);
SET(@&zchannel[0],%&channel%);
SET(@&zchat[0],%&newchat%);
#id = 0
#id2 = 15
DO(16);
SETLABEL(chat%#id%,%@&zchat[%#id2%]%);
SETLABEL(name%#id%,%@&zname[%#id2%]%);
SETLABEL(channel%#id%,%@&zcolor[%#id2%]%[%@&zchannel[%#id2%]%]);
INC(#id);
DEC(#id2);
LOOP;
ENDIF;
ENDIF;
ENDUNSAFE;
}$$