Among the three factors to maintain engine running,
most likely spark is the one afftected in this case. Becasue a worn ignition coil will leak during wet environment. Probably a damaged or missing shield or splash guard will cause higher humidity under the hood, which makes the leaking even worse. Take a look at the shield or splash guard, it will just cost several minutes. But more important thing is to have your ignition system checked.