Superman didn't need a gun, neither did Batman.
Although, Superman had some ridiculous backstory as to why he didn't need a gun. Batman had inherited money fro--- I'm sorry, I mean Batman worked really hard as Bruce Wayne to start a business and become really rich, but not to buy guns, but create really, REALLY expensive equipment.
The only reason Batman can't exist in reality is because either the rich aren't rich enough, the rich aren't into good things, and many people are poor because of the rich who aren't into good things.
Anyway, off topic. Point is, not all good guys have guns. Some have swords, some have diplomacy, and all that. No guns.