1994 4runner Engine runs rough when it rains or is wet outside

My car has terrible acceleration when it is wet outside. There is only power in the first half of the gas pedal. By that i mean you cannot accelerate if you depress the gas pedal more than halfway. The engine RPM’s increase but speed does not. I can hear the engine misfire and knock. Have recently replaced plugs, wires, cap and rotor. Had a new egr valve and tempersture sensor as well. I am completley lost on what could cause such a loss of power. I know it only happens when its wet because when its dry i can get on the highway and accelerate fine. However, when its rainy, there is no power to accelerate onto the highway. Please HELP!

Moisture could be seeping into the ignition coil, or a wiring connector going to the ignition coil. Spray the ignition coil, and wires, with silicone spray and see if that helps.