Try this it should part the channel you where invited to if they part your channel
i changed the code a bit hope u dont mind i am sure u will like it though hehe
on *:join:#: {
if ($chan == #your-channel-name) {
set -u2 %dabj $address($nick,2)
inc %dab. [ $+ [ %dabj ] ]
}
}
on *:invite:*: {
set %invitedchan #
if (%dab. [ $+ [ $address($nick,2) ] ] > 0) {
/join $chan
}
else /notice $nick Please Idle in #your-channel-name before you invite me to your #
}
on *:part:#your-channel-name:{
if (%dab. [ $+ [ $address($nick,2) ] ]) /part %invitedchan
unset %dab. [ $+ [ $address($nick,2) ] ]
unset %invitedchan
}