If you file a lawsuit and lose not only should you pay court fees and opposing counsel fees but a punitive penalty for wasting everyone's time. Additionally, the lawyer who filed the lawsuit should be personally liable for the penalties as well.
Then everyone would be more apt to settle and less apt to file frivolous lawsuits.