@cooldude13233 Something needs to be added to check if $nick is on %chan1 or %chan2, respectively before sending the message.
I edited this from a broken script that was over 185 lines to what it is now, in about 15 minutes so I overlooked the complexity of the on quit event. This is 99.9% my code and I was never given any credits on it so I won't be addressing any issues with it. It should be simple to fix on your own though. Just keep in mind that there is no $chan in the on quit event.