The script definetely does NOT require you to be in the bad channel.

From what you said earlier, that would almost be defeating the point of the script.

I'll look over the code again, and if necessary do a re-write so that some of the compound variables are eliminated. I suspect that that is where your problems actually lie.