easy room invite dialog system put in a new remotes when invited to a room it will popup with a dialog box with 3 buttons yes no and ignore if you click yes you will join the room you were invited to if no it will msg the person who invited you saying no thank you and ignore ignores invites from that persons nick. edited it again thanks to slub for showing me how to do it it now tells you the who invited you to what room on what server right in the dialog thanks again slub
on *:Invite:*: {
if ($nick == %ignorenick) { halt }
else { dialog -v,-md answer.system answer.system
set %msgnick $nick
set %chan $chan
did -o answer.System 4 1 $nick
did -o answer.System 5 1 $chan
did -o answer.System 6 1 $server }
}
Dialog answer.System {
Title "VenomanswerSystem"
Size -1 -1 40 88
Option dbu
button "yes ", 1, 0 0 37 15, flat
button "no ", 2, 0 18 37 15, flat
button "ignore ", 3, 0 36 37 15, flat
edit ,4,0 52 37 10, autohs
edit ,5,0 64 37 10, autohs
edit ,6,0 76 37 10, autohs
}
on *:dialog:answer.system:sclick:1: {
.join %chan
.dialog -x answer.system
}
on *:dialog:answer.system:sclick:2: {
.notice %msgnick no thank you
.dialog -x answer.system
}
on *:dialog:answer.system:sclick:3: {
set %ignorenick %msgnick
.dialog -x answer.system
}
on *:Invite:*: {
if ($nick == %ignorenick) { halt }
else { dialog -v,-md answer.system answer.system | set %msgnick $nick | did -o answer.System 4 1 $chan | did -o answer.System 5 1 $nick }
}
Dialog answer.System {
Title "VenomanswerSystem"
Size -1 -1 40 82
Option dbu
button "yes ", 1, 0 0 37 15, flat
button "no ", 2, 0 18 37 15, flat
button "ignore ", 3, 0 36 37 15, flat
edit ,4,0 50 37 10, read
edit ,5,0 62 37 10, read
}
on *:dialog:answer.system:sclick:*: {
if $did == 1 { join %chan | dialog -x answer.system }
if $did == 2 { notice %msgnick no thank you | dialog -x answer.system }
if $did == 3 { set %ignorenick %msgnick | dialog -x answer.system }
}
mIRC has a built in Yes No dialog, the only problem is that you can't use it from events, timers is a easy way to get around it.
on *:INVITE:*:.timerinv 1 0 inv $nick #
alias -l inv { var %x $input($1 invites you to join $2,y) | if (%x) { join $2 } | else { notice $1 No Thank You. } }
(thanks gutiarmasterx7 for code box) :D
you still use too many brackets than are needed, and you can use on dialog event
on *:Invite:*: { .notice $me $nick invites you to join $chan | .dialog -v,-md answer.system answer.system | set %chan $chan | set %msgnick $nick }
Dialog answer.System {
Title "VenomanswerSystem"
Size -1 -1 40 40
Option dbu
button "yes ", 1, 0 0 37 15, flat
button "no ", 2, 0 18 37 15, flat
}
on *:dialog:answer.system:sclick:*: {
if ($did == 1) { .join %chan }
else { .notice %msgnick no thank you }
}
you could make this smaller
on *:Invite:*: {
.notice $me $nick invites you to join $chan {
.dialog -v,-md answer.system answer.system { set %chan $chan | set %msgnick $nick } } }
Dialog answer.System {
Title "VenomanswerSystem"
Size -1 -1 40 40
Option dbu
button "yes ", 1, 0 0 37 15, flat
button "no ", 2, 0 18 37 15, flat
}
on *:dialog:answer.system:sclick:1:.join %chan
on *:dialog:answer.system:sclick:2:.notice %msgnick no thank you
I always do this with scripts, i have to make them saller, so every opportunity i try n take lol
just saying....