External stimuli during sleep, including auditory ones, can affect your dreams.German researchers noted that music dreams formed 6.3% of all reported dreams in a study to determine whether music at bedtime affects dreams.So, it affects your dreams the same way you can hear an alarm blaring in your dream only to wake up to the same reality.