Endorphins and dopamine are different neurotransmitters that play different roles in the nervous system.
Endorphins are endogenous opioid peptides that regulate pain perception and emotional states. Endorphins work similarly to opioids in that they bind to opioid receptors in the brain, thereby reducing pain, producing a feeling of euphoria and suppressing anxiety.
Dopamine is a neurotransmitter that plays an important role in the central nervous system and is involved in regulating a variety of physiological and psychological processes, including movement, memory, emotion, motivation, reward, etc. Dopamine binds to dopamine receptors in the brain, thereby regulating the excitability and inhibition of neurons and affecting related behaviors and emotions.
Thus, the roles and mechanisms of endorphins and dopamine in neuromodulation are different, although they can both influence affective states and reward system activity.