Anyway I finished waking nightmare with no problems, went back to Dawnstar and a dragon appeared. I killed it and everything seemed ok. NPCs started walking back to their usual places.
Only then I noticed that some are stuck frozen in position while walking. Some are spinning in circles, they can still be talked to and everything. Erandur won't follow me, he just stands there. The weird thing is that NPCs performing actions like the bard and blacksmith are acting normal. It's just everyone else. Anyone else had this problem?