You're looking for the operator "iswm" (stands for "is wildmatch").
Please type: /help if then else, in mIRC. Browse through the list, under "The Operators."
if (John* iswm $nick) { }
It may be better to use this persons hostmask or address instead of using his nick.
Such as:
if (*!*ident@*.some.host.com iswm $fulladdress) { }