That really won't help. It is entirely possible for someone to PM you "hi" within 3 seconds. You'd have to check what was said (or at least the $len) for it to be helpful, I think. You can estimate that people can type up to perhaps 10-15 characters within 3 seconds.

Also, your use of $comchan wouldn't work if you were in multiple channels with the person.