You can't leave crossbow bolts, arrows, sling stones, thrown dagger, darts etc. etc. etc. out of this.
Currently, the rules say that if a roll to hit misses, then whatever had that roll to hit is assumed to miss everything and just fly off into unoccupied space.
You're designing rules to say:
- If a roll-to-hit spell effect misses, let's plot out the remainder of its flight path to see what else it might hit.
This is a HUGE buff to magic spells and is totally logically inconsistent with not applying the same rules to other ranged attacks.
Even if you apply it to ranged attacks, you've still got a problem in that you're giving a TREMENDOUS advantage to ranged and spell attacks over melee. All of a sudden you're making the fighter a lot weaker.
Everybody in your campaign will start using spell or ranged attacks and only melee as a last resort. . . and why shouldn't they? With a ranged attack under these rules, you get multiple chances to hit. With a melee attack if you miss you miss.
This rule is a colossally bad idea for game balance had has no logical internal consistency whatsoever if you apply it only to spell attacks and not all ranged attacks. That causes LESS realism, not more.