Dopamine, the brain chemical best known for its role in pain and pleasure, could also play an important part in regulating sleep, according to a new study in the journal PLoS Bioogy.

Researchers from the University of Barcelona and the Centro de Investigacion Biomedica en Red de Enfermedades Neurodegenerativas (also called CIBERNED) in Spain found that dopamine has a function in the pineal gland in the brain, a vital player in the body's circadian rhythms.

The pineal gland receives light signals from the retinas in the eyes, which then in turn tell it to make melatonin (which promotes sleep) for the body's sleep cycle, researchers explained. And the hormone norepinephrine is involved in controlling the making and release of melatonin.

Dopamine plays a role in sleep and wakefulness by stopping norepinephrine's effects -- meaning that there is less melatonin being made and released, thereby alerting the body to wake up, researchers found.

"These results are interesting as they demonstrate a mechanism in which dopamine, normally increased at times of stimulation, can directly inhibit production and release of a molecule, melatonin, that induces drowsiness and prepares the body for sleep," study researcher Peter McCormick, of the University of Barcelona, said in a statement.

Recently, a study in the Journal of Neuroscience showed that dopamine levels in certain brain regions may also play a role in determining whether someone is going to be a procrastinator or a motivated go-getter, LiveScience reported.

A brain region called the anterior insula "showed a strong negative relationship between dopamine level and willingness to work hard," study researcher Michael Treadway, a graduate student at Vanderbilt University, told LiveScience.