The "on snotice" event will catch them...
On ^*:snotice:& & is doing a /whois on you:{
if !$window(@whois) { window -n @whois }
aline @whois $1-
haltdef
}
The couple of &'s in the matchtext section of this event are
wildcards, each representing a single word, and the /aline command redirects the notice to a custom @window.
If you would like to change the message that is displayed in the @window, change the /aline to something like -
- aline @whois $2 is /whoising you.