Jethro commented on a Page, Teamspeak 3 IRC Bot  -  Aug 17, 2010

Nice effort you've put into this script. As for the regex part, you could do:

on $*:text:/^[!@`~](tsinfo|users|channels|ts_start)$/Si:#: {
  var %e = $iif($sock(ts3),sockwrite -n ts3 serverlist,msg $chan $msg_style(Error) Not Connected)
  if ($regml(1) == tsinfo) { %e }
  else if ($regml(1) == users) { %e }
  else if ($regml(1) == channels) { %e }
  else { ts }
}

You already specified the three matches, the last one has to be ts_start. So there was no need for another elseif statement but an else condition. Also, make sure your regex starts with the command symbols and ends exactly as the matched trigger strings.

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.