Some medications, such as antidepressants and sedatives, can affect your dream recall. And timing plays a big role.