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
51
52
|
on *:text:?? *:#:{
if ($readini(stamper.ini, setup, $address($nick, 0)) == 5) {
;dictionary
if ($1 != ??) return
if ($2 iswm add) && ($3-4) {
while (!$readini(stamper.ini,words,$3)) {
writeini -n stamper.ini words $3 $4-
timer 1 0 notice $nick $+(',$3,') saved
timer 1 1 notice $nick $4-
halt
}
if ($readini(stamper.ini,words,$3)) {
timer 1 0 notice $nick $+(',$3,') is already known
timer 1 1 notice $nick to edit $+(',$3,'), use: ?? edit $3 <definition>
halt
}
}
if ($1 != ??) return
if ($2 iswm del) && ($3) {
while ($readini(stamper.ini,words,$3)) {
remini bot.ini words $3
notice $nick definition for $3 has been deleted.
halt
}
if (!$readini(stamper.ini,words,$3)) {
timer 1 0 notice $nick failed to delete $+(',$3,') from the dictionary
timer 1 1 notice $nick $3 wasn't found
halt
}
}
if ($1 != ??) return
if ($2 iswm edit) && ($3-4) {
while ($readini(stamper.ini,words,$3)) {
timer 1 0 notice $nick definition for $+(',$3,') has been changed.
timer 1 1 notice $nick $readini(stamper.ini,words,$3) has been replaced with $4-
writeini -n stamper.ini words $3 $4-
halt
}
if (!$readini(stamper.ini,words,$3)) {
notice $nick $+(',$3,') was not found
halt
}
}
if ($1 != ??) return
if ($2 iswm viewdictionary) {
run stamper.ini
}
}
else {
halt
}
} |