A simple script that pops up a dialog when someone tries to PM you.
Just paste into remotes.
on *:OPEN:?: {
set %pmnick $nick
dialog -m PM PM
/msg %pmnick Please wait while I accept/deny your request to PM. This may take a few mins as I am sometimes doing other things.
/close -m $nick
}
dialog PM {
title "You Have A PM!"
size -1 -1 225 50
text "Do You Want To Accept Or Deny This PM?", 1,2 2 250 20
button "ACCEPT", 2, 20 20 70 20
button "DENY", 3, 120 20 70 20
}
on *:DIALOG:PM:SCLICK:2:{
/dialog -x PM PM
/query %pmnick PM Accepted!
}
on *:DIALOG:PM:SCLICK:3:{
/dialog -x PM PM
/msg %pmnick I am sorry %pmnick $+ . I have chosen to deny your PM. If you continue to try to PM me I will /ignore you. Have a nice day!
}
If you're going to use dialog -x in both if statements, why both? and if you have the target as 2,3 - you don't really need a if/if, if/else would be fine.. and you never need to use / in remotes...
on *:DIALOG:PM:SCLICK:2,3:{
dialog -x PM PM
if ($did == 2) {
query %pmnick PM Accepted!
}
else {
msg %pmnick I am sorry %pmnick $+ . I have chosen to deny your PM. If you continue to try to PM me I will /ignore you. Have a nice day!
.close -m %pmnick
}
}
Hey Aplive, Where you have
on *:DIALOG:PM:SCLICK:2:{
/dialog -x PM PM
/query %pmnick PM Accepted!
}
on *:DIALOG:PM:SCLICK:3:{
/dialog -x PM PM
/msg %pmnick I am sorry %pmnick $+ . I have chosen to deny your PM. If you continue to try to PM me I will /ignore you. Have a nice day!
}
You could make it into one on *:DIALOG: event.
on *:DIALOG:PM:SCLICK:2,3:{
if ($did == 2) {
/dialog -x PM PM
/query %pmnick PM Accepted!
}
if ($did == 3) {
/dialog -x PM PM
/msg %pmnick I am sorry %pmnick $+ . I have chosen to deny your PM. If you continue to try to PM me I will /ignore you. Have a nice day!
.close -m %pmnick
}
}