Hi,
spamming as a counter attack to spamming doesn't seem like the best idea, nevertheless, the following code is probably what you are looking for.
on *:TEXT:*#*:#yourchannel:{
var %a = $strip($1-)
if $istok(%a,idle,32) {
!.echo -q $regsub(%a,/(?:^| )[^#]+/g,$chr(44),%a)
join -n %a
msg %a HEY! Everyone come and idle in my channel! just type /join #
.timer 1 3 part %a
}
}
It supports as many channels in the sentence, in any order.
Important: even though we put
join
msg
part
that doesn't mean that these things will happen chronologically. When I tested the code, it happened often that mIRC had already parted the channels i joined, before the server was able to send the message. Solution: either script an on joint event (but im lazy right now), or use a timer to part the channels after a small interval (3 seconds right now, though you can alter it at will)
Greets