It sounds like water was causing the misfire. Make sure your spark plug wires are on snug at the plug and coil pack. Get a spray bottle full of water, adjust it to a mist, get out there after dark and spray where the spark plug wires go on the coil pack and watch for sparks.
Spray along the length of each wire, and at the boot. A great amount of heat builds up under the hood of these trucks, thanks to the EPA insisting that they be run so hot for emissions purposes, sometimes the wires deteriorate and it isn't visually obvious.
If your truck is the coil on plug setup- same thing, get things moist and watch for sparks to fly.
1999 Ranger Extended Cab, 4x4, 4.0, automatic.