There are various studies on masking out there using different exposure types, generally they involve a lot of folks in presumably "normal" exposure situations or in hospitals, and the fidelity of masks being worn in that group can be suspect. I've looked at a number of them and I THINK masks are very modestly effective at preventing transmission, e.g., given a thousand people in a situation, if ten are infected and wearing a mask, maybe they infect 25 people over a set time period, and unmasked folks infect 50. Of course, the situations will vary a lot, so you need a large population to ferret out a smallish benefit.
As far as preventing a healthy person from contrating COVID, the figures are much closer to zero. (I made up the 25 and 50 merely for illustration).
My understanding is within the 6ish foot distance rule, time is the most relevant factor. The longer an infected person talks in the direction of someone, the more viral load the other person is breathing in.
Contracting the virus is not a all-or-nothing event, viral load is very important. i.e., someone may have breathed their covid cooties on you, but only for a few seconds, so you actually "get" it, but your immune system kicks it back before you ever even knew you had it. Otoh, if they talk in your face for 10 minutes or 30 minutes, you've taken in a much greater viral load and may get sick.
This extends to how severely people get sick (and how they handle it depends on other health risks and factors, obviously). Your body may handle covid the same each time, but if you contracted a small viral load, maybe you don't get too bad while you're sick. Or if you take in a huge viral load, you may get very sick.
Masks are intended to reduce the viral load spread, and have
some effectiveness in that regard. Whether or not it actually makes a difference depends on a ton of other variables.