Try resoldering the AFM pins. Take out the AFM, open the box and resolder the pins going from the PCB to the loom connector.
Resolder them even if the old solder is still intact. You'll find that a lot of idle issues have been resolved simply by resoldering the connecting pins if you do a quick search (including mine, contacts were intact however I still ended up resoldering them just to rule it out and.it ended up fixing my idle issue).
Additionally, check that the AAC has been cleaned properly including mating surfaces and tightened properly when you reinstalled it. Check all the hoses going to and from the intake manifold for leaks.
Clean the throttle body and check/adjust the TPS to correct setting.
Reset the ECU and the idle once you've done all of the above. There is a step by step guide on cleaning the AAC and resetting the idle, do a quick search.
I have a feeling that your missfire issue is related to your idle problem so hopefully sorting out the idle will sort out the misfire.
Check the belts for wear, if worn, replace them. If not, check/adjust the tension, could be as simple as that.