|
Joined: Mar 2005
Posts: 46
Ameglian cow
|
OP
Ameglian cow
Joined: Mar 2005
Posts: 46 |
Well I've made this script here, but I cant for the life of me figure out why it isn't Identifying. Hopefully somebody can enlighten me... dialog aid {
title "AIDv2"
size -1 -1 80 129
option dbu
list 1, 2 15 50 100, size
edit "", 2, 2 2 50 10, autohs
button "Add", 3, 53 1 26 12
button "Remove", 4, 53 16 26 12
button "Clear All", 5, 53 29 26 12
button "OK", 6, 2 116 37 12, ok
button "Cancel", 7, 41 116 37 12, cancel
menu "File", 8
menu "On/Off", 9, 8
item "Enabled", 14, 9
item break, 15, 9
item "Disabled", 16, 9
item break, 10, 8
item "Help", 11, 8
item break, 12, 8
item "About", 13, 8
}
on *:dialog:aid:sclick:5:{ did -r aid 1 | remini aid.ini NP }
on *:dialog:aid:sclick:3:{
if ($did(aid,2) != $null) {
if ($chr(32) !isin $did(aid,2)) { echo -a Read the Help Please. (Click File > Help) }
else { did -a aid 1 $did(aid,2) | writeini $+(",$scriptdiraid.ini,") NP $gettok($did(aid,2),1,32) $gettok($did(aid,2),2,32) | did -r aid 2 }
}
}
on *:dialog:aid:sclick:4:{
if ($did(aid,1).sel) {
var %sel.txt = $did(aid,1).seltext
var %sel.num = $did(aid,1).sel
did -d aid 1 %sel.num
remini $+(",$scriptdiraid.ini,") NP $gettok(%sel.txt,1,32)
}
}
on *:dialog:aid:menu:14:aidON
on *:dialog:aid:menu:16:aidOFF
on *:dialog:aid:init:0:{
$iif(%aidtog,did -c aid 14,did -c aid 16)
var %totl = $ini(aid.ini,NP,0)
while (%totl) {
did -a aid 1 $ini($+(",$scriptdiraid.ini,"),NP,%totl) $readini($+(",$scriptdiraid.ini,"),NP,$ini(aid.ini,NP,%totl))
dec %totl
}
}
on *:notice:*:*:{
if ($nick == nickserv) {
if (*registered*and*protected* isin $1-) {
if ($ini($+(",$scriptdiraid.ini,"),NP,$me) && (%aidtog)) {
nickserv identify $readini($+(",$scriptdiraid.ini,"),NP,$ini($+(",$scriptdiraid.ini,"),NP,$me))
}
}
}
}
menu status,channel {
-
AIDv2:dialog -dm aid aid
-
}
alias -l aidOFF {
if (%aidtog) { unset %aidtog | did -u aid 14 }
did -c aid 16
}
alias -l aidON {
if (!%aidtog) { set %aidtog on | did -u aid 16 }
did -c aid 14
}
|
|
|
|
Joined: Dec 2002
Posts: 3,547
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 3,547 |
Try using iswm rather than isin. If $ini($+(",$scriptdiraid.ini,"),NP,$me) is true it has a value of 1. So you can change nickserv identify $readini($+(",$scriptdiraid.ini,"),NP,$ini($+(",$scriptdiraid.ini,"),NP,$me)) to nickserv identify $me $readini($+(",$mircdiraid.ini,"),NP,$me)
dialog aid {
title "AIDv2"
size -1 -1 80 129
option dbu
list 1, 2 15 50 100, size
edit "", 2, 2 2 50 10, autohs
button "Add", 3, 53 1 26 12
button "Remove", 4, 53 16 26 12
button "Clear All", 5, 53 29 26 12
button "OK", 6, 2 116 37 12, ok
button "Cancel", 7, 41 116 37 12, cancel
menu "File", 8
menu "On/Off", 9, 8
item "Enabled", 14, 9
item break, 15, 9
item "Disabled", 16, 9
item break, 10, 8
item "Help", 11, 8
item break, 12, 8
item "About", 13, 8
}
on *:dialog:aid:sclick:5:{ did -r aid 1 | remini aid.ini NP }
on *:dialog:aid:sclick:3:{
if ($did(aid,2) != $null) {
if ($chr(32) !isin $did(aid,2)) { echo -a Read the Help Please. (Click File > Help) }
else { did -a aid 1 $did(aid,2) | writeini $+(",$scriptdiraid.ini,") NP $gettok($did(aid,2),1,32) $gettok($did(aid,2),2,32) | did -r aid 2 }
}
}
on *:dialog:aid:sclick:4:{
if ($did(aid,1).sel) {
var %sel.txt = $did(aid,1).seltext
var %sel.num = $did(aid,1).sel
did -d aid 1 %sel.num
remini $+(",$scriptdiraid.ini,") NP $gettok(%sel.txt,1,32)
}
}
on *:dialog:aid:menu:14:aidON
on *:dialog:aid:menu:16:aidOFF
on *:dialog:aid:init:0:{
$iif(%aidtog,did -c aid 14,did -c aid 16)
var %totl = $ini(aid.ini,NP,0)
while (%totl) {
did -a aid 1 $ini($+(",$scriptdiraid.ini,"),NP,%totl) $readini($+(",$scriptdiraid.ini,"),NP,$ini(aid.ini,NP,%totl))
dec %totl
}
}
on *:notice:*:*:{
if ($nick == nickserv) {
if ([color:red]*registered and protected* iswm $1-[/color]) {
if ($ini($+(",$scriptdiraid.ini,"),NP,$me) && (%aidtog)) {
[color:red]nickserv identify $me $readini($+(",$scriptdiraid.ini,"),NP,$me)[/color]
}
}
}
}
menu status,channel {
-
AIDv2:dialog -dm aid aid
-
}
alias -l aidOFF {
if (%aidtog) { unset %aidtog | did -u aid 14 }
did -c aid 16
}
alias -l aidON {
if (!%aidtog) { set %aidtog on | did -u aid 16 }
did -c aid 14
}
|
|
|
|
Joined: Mar 2005
Posts: 46
Ameglian cow
|
OP
Ameglian cow
Joined: Mar 2005
Posts: 46 |
Thanks a lot Slade, had to take the $me out of the nickserv identify line but it works now, I guess my problem with the isin $1-, sorry to post all that over such a simple mistake on my part, but i thank you all the same
|
|
|
|
Joined: Dec 2002
Posts: 3,547
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 3,547 |
You're most welcome. No need to be sorry hehe. Glad to help.
|
|
|
|
|