You can have a bow on your boat when you show up in the Caymans, you just have to declare it and customs impounds it for the stay. The same goes for your spear guns. You notify customs before departure and they return it to you. It's when you don't declare it that you get into a jam if they find it.
The general rule of thumb is that whatever is legal in your home port it is legal on your boat in international waters. When you enter a foreign port you declare your weapons and then they impound it, let you keep it or If you have a suitable customs locker on your boat some countries may chose to keep it there for the stay with a customs seal. Virtually every country but Mexico and North Korea abides by this. Being from Texas it's legal for me to sail with almost anything short of a nuclear weapon.
The problem is that even if I tone it down and bring something gentlemanly and sporty, like, say, my single shot 12ga H&R trap gun, the paperwork and bureaucratic hassles are a total pain even for that. In the Caribbean not so bad sometimes, but Europe, massive hassle. Unlike the Bahamas and Latin America, the general concept in much of Europe is not to use guns against humans for defense, just target shooting and hunting. However, I can do that with a bow.
There are cool places in Central America like Rio Dulce Guatemala. The primary place to avoid right now is Venezuela.
Oddly enough, the drug trade means that most of the outlaw types with any real moxie are out running dope, not slumming it by knocking over yachts for watches, spare change, and maybe a laptop. Your typical water bandit is a moonlighting fisherman, usually active in a harbor, sometime out on the water with an outboard and an open skiff with rusty shotguns. They are not supermen nor invincible. Usually, if they just see a gun, they back off. Brave, they are not.
Cuba would be good to see before it goes mainstream and they have to tear down most of old Havana (decades of neglected maintenance).
One idea is to check your gun into customs at Gibraltar, do the Med, and get them on the way out. But that adds inflexibility to a trip that doesn't really have a time schedule.
In British waters they want you to have a customs locker suitable for guns by their standards. This means bolted to a bulkhead and the deck with a separate lockable space for youe ammo.