Shutting them down quickly.
patron: Hey jack sparrow! Pirate: Where! he owes me money, you a friend of his? you gonna pay his debt? whats in YOUR wallet bird lover? optional: Is that your wife? she would settle the score quite nicely.
patron: ARRRRR! Pirate: S, T, U, V, DOUBLEYARRR!
Since these comments are usually made in passing, if you can make em pause and think for just a moment or better yet make their friends laugh at them, usually gives ya just enough time to pass on by without further heckling.
Take it from someone who has had to walk the street alone in a pirate outfit handing out fliers for a kiddie pirate ship in places like Key West, HUMOUR IS ALWAYS YOUR BEST DEFENSE!