There is a theory in sociology about the crime triangle. For a crime to take place you need a victim, a person inclined to commit a crime, and opportunity. If any of those three things are missing, no crime. So locks reduce opportunity, teaching martial arts to "victims" reduces their risk and programs to help "at risk" criminals (drug treatment for example) reduces their inclination to commit a crime.
I think infidelity is the same. Many of us have been "hit on" when we are in a place where there is opportunity, but we are strong enough to resist or the other person isn't effective enough.
So it doesn't just happen, but there are likely folks that would never have been WS or APs if some part of the triangle had been stronger. They were still the same person they ever were, but either the situation or the person pushed them over the edge. Many of us who are BSs might become WSs in the right environment - but that environment is much less likely.
My H had his first affair when he was directly propositioned for sex by a very attractive co-worker at a time when they had a lot of opportunity and we were in the throes of raising young kids after 15 years of marriage. Had she not been so direct and attractive, he probably never would have made the first move.