Can heat cause stress?

Okay so my dog has been vomiting and having diarrhea, we took him to the vet and he told us he thinks it stress related. The only changes that have happened recently is he goes on a walk almost every day he only got out maybe MAYBE once a month in winter. And he is great Pyrenees golden retriever mix so he is always hot. Do you think the heat can be causing him stress? He also seems a little better now that we have a AC on almost none stop. And an added pic because I might be bias but he is the cutest!