what year truck?
if you've already done plugs, wires, cap, and rotor - the next routine maintenance that can affect how it runs is the front O2 sensor.
do you feel the misfires, or is the CEL your only hint.
if you clear the codes, do you get only 1 or 2 cylinders misfiring, like 301 or 308, or are they scattered?
an an experiment, you could unplug the front O2 and run it disconnected. you'll get an new CEL related to O2 problem, but if it runs better it confirms the O2 is causing the problem.