Well what about d20 modern, and it's d20 past splatbook? Surely in this version, longbows will be an inferior option.
As before, we'll examine four characters. Ephram and Faulkner are first level fast heroes, designed to be good at the use of their chosen weapons. Geoffrey and Harald are first level tough ordinaries, with no martial training at all.
Ephram, the musketman, can be built with a wheellock musket, or the more advanced brown bess musket. Both are muzzle loaders that require two full-round actions to reload, or one with the Rapid Reload feat (which Ephram has). His wheellock has a 40' range, and deals 2d8 (average of 9) damage. The brown bess has a range increment of only 20', but deals 2d10 (average 11) damage on a hit. It requires the Personal Firearms Proficiency feat, and Ephram used his last feat on Point-Blank Shot, for the usual +1 to hit and damage when firing at a target within 30'. Ephram only gets the benefit of his +2 dexterity bonus with the brown bess, the more primitive wheellock doesn't allow this for some reason.
Faulkner, the bowman, has the compound longbow from the d20 modern book. This is a bit of an anachronism, as this bow is made from modern materials and allows the character to use any amount of their strength bonus at no additional cost, which is different than D&D's composite bows, which are meant to represent the technology of the english longbow, a super-weapon of it's day. His compound bow can be fired every round, with no rapid-shot feat included in the D20 modern book as there would be in D&D. He can take advantage of his dexterity and strength bonuses, so his weapon is at a +2 to hit and deals 1d8+2 (average of 6.5/hit).
So this is an improvement over 3.5, for the musketman. 11 damage every other round is at least equivalent to 6.5 every round. However, the shots every round are going to hit more often than when they only get to fire every other round.
The shot every other round sounds slow, but remember that in either version, a combat round lasts 6 seconds. Here is a video of a competitive shooter putting out three shots in 46 seconds. That means this man would only have the personal firearms proficiency, and does not have the Rapid Reload feat. I don't think that seems correct.
The bowman firing once every six seconds, on the other hand, seems reasonable. This man is firing only a 20 lb bow, which is very easy to pull, but his 10 shots in 30 seconds means he's firing twice per round, which would jibe with the rapid shot feat in D&D, which isn't available to my D20 modern character. A D&D character at 10th level can be like the guy at the 2 minute mark of this video. 12 aimed shots in 17.5 seconds, call that 4 shots/round, which would be consistent with Manyshot and iterative attacks on a full-round action. (At 11th level he goes up to 5 shots per round). With primitive firearms there's no way to stack up that many shots because the reload time is too high.
The basic reason cited most often for why the gun supplanted the bow is training time. It takes a long time for a character to reach 3rd, or 6th, or 11th level, especially if this is through some sort of intensive training regimen, not the insanely rapid leveling that can take place with adventurers. Call it one year per level, and that means the bowman is getting steady increases in number of missiles he can fire, and a greatly cascading damage output. The musketman will only see a steady improvement in his chance to hit, every other round. If we treat the training time for a soldier as "time to reach first level", then a musketeer reaches his effective maximum in potential damage every round in one year, and from there only improves how often he succeeds. The bowman sees tangible improvements in damage output at almost every level, with the same increasing odds of hitting the target.
Let's pretend that last paragraph was in my previous post, ok? Rapid Shot and Manyshot aren't in d20 modern. So the bowman and musketman in this scenario, Ephram and Faulkner, both see similarly stagnant growth in damage output, with Ephram seeing an extra shot every five levels because of iterative attacks (second shot at -5, third shot at -10, etc), or would if this were a strong hero. Fast heroes have a slower BAB progression, but all the strong hero talents are completely worthless for a ranged character. I digress..
Geoffrey and Harald are tough ordinaries, farmers conscripted to fight. They have no stat bonuses or penalties, and no feats relevant to use of their weapons, a compound bow or musket, respectively. Geoffrey is able to fire once per round, at a -4 penalty to hit, and deals 4.5 damage per round if successful. Harald, lacking the Rapid Reload feat, fires once every three rounds, making his 9 or 11 average damage unimpressive to say the least. Conscripted bowman wins.
So in both of our examples, a trained soldier and a hapless conscript, the bow is superior in every respect to the muzzle-loading musket. The situation changes quite a bit if we bring breechloaders in, but this isn't about modern firearms, and the 18th century is definitely heading in that direction sharply from the muskets of the past.
Cost? Far from being a cheaply cast, mass-producable alternative to the bow, the wheellock musket is listed with a PDC of 23, which page 204 of my d20 modern book tells me is the equivalent of $5,000. The compound bow's PDC of 10 is only $120 dollars. The disparity is higher than is should be, as I'm taking the cost of the wheellock out of the d20 past book, which assumes it is a high-tech and somewhat exotic item for it's day, but the bow is in d20 modern, and it's a mass-produced sporting good. Modern firearms weigh in between $500 and $2,0000. I would personally adjust these numbers, but for now I'm only examining the rules-as-written. House rules will be coming later.
So in D&D and d20 modern/past, firearms are more expensive, require the same level of training for basic competency, and have an inferior damage output overall. How accurate are these? Next time I'll examine historical sources, like 2nd edition.