Mafiosos,
I am in the middle of code hell. It all started when my coolant temp sensor went bad. I replaced that without a hitch, it was surprisingly easy. In the process I pulled off the air cleaner just so I could get a better look at the expansion tank to make sure that didn't have any cracks.
I got a code, initially for running the car with the MAF disconnected when I was making sure that there was enough coolant in the car (running it, cold, with the rad cap off). That went away after a couple of restarts in normal driving.
Now my car is throwing codes for both cam position sensors, the mass air sensor, air temp, and sparkplug sensor.

I've gotten the safemode stall immediately after start twice. The valves are louder than usual and if I play with the gas I get a clicking sound when the revs start to drop.

What demon has possessed my car?

The specific codes I'm getting are as follows:
P0304 CPS A
p0365 CPS B
P1318 Sparkplug detection module reset circut malfunction

The logged codes are:
P0304
P0365
P0102 MAF circuit low input
P0113 Air temp circuit high input
P1318