Use $nick(#, N).pnick to get the mode prefix.