He’s traumatized by what’s been going on in war. As humans, we tend to never forget the bad things that happen to us. However, when it’s something good we want to remember, there are little snippets of that good memory. That’s possibly why he gets flashbacks and nightmares. He gets a little snippet of his good memories, while he’s dreaming, and gets scared. He gets scared because, when he tries to remember the good memories purposely, it’s difficult for him. This is the best possible answer I can give