There is a bug, if something 'kills' you pet, all it does is stop moving. Go back to the energy temple and let the energy lasers hit your pet. Your pet stops moving, and wont do anything untill you switch pets, whence it resumes following you normally.