whoa I solved it with a dumb way before you posted. The $target solution is just what I need. Thanks!

BTW: Here's how I solved it:
Code:
  set %channame $mid($rawmsg, $calc($pos($rawmsg, $chr(32), 2)+1), $calc($len($chan) + 1))
  if ($left(%channame, 1) == @) {


My ally is the compiler, and a powerful ally it is!