Your way didn't work for me, as I just tested it. But I removed the bracket, and changed some things:
on *:JOIN:#thunderbolt: {
set %join.rand $rand(1,3)
if (%join.rand == 1) msg $chan welcome on the $chan chat $nick
if (%join.rand == 2) msg $chan welcome on the $chan chat chanal $nick.
if (%join.rand == 3) msg $chan welcome $nick, stick to the rules and I will not kick you ;)
}
- Stewie (I@m.Sexy.Stewie) has joined #thunderbolt
<&thunderbolt|ghost> welcome on the #thunderbolt chat Stewie