Sounds simple to me. Your body gets a build up of seminal fluids that need to be released in one way or another. If you don't release it through masturbation or sex, then it will esape through Nocturnal Emissions.
Solution: Masturbate at least once a week.