The glow plugs are fine. GM officially says 1 OHM or less, but if they're intact and have resistance that low, you're good. I had a bad glow plug that was over 200 OHMS... that was bad.
As far as the ticking on the driver's side goes, it's normal and not related to the fireworks you caused by shorting the batt to ground. At one time or another, you'll notice a random tick that can be heard more from the driver's wheel well... almost all Dmax engines do this and it's commonly called the typewriter tick. Something to do with air bubbles in the oil getting between the main bearings and the crank (I don't understand that and neither does anyone else IMO since no one can explain why it comes and goes)
The ECM on these trucks is very, very, very sensitive to the correct voltage. The fact that you shorted the batteries to ground and basically dropped the voltage to zero is probably why it's throwing the sensor codes- the sensors themselves are probably fine. It may have likely damaged the ECM, GPCM and or the BCM however.
When you reset the codes, does it still act wacky?