The scrotum is a very sensitive area. It would be like if someone hit you in a very sensitive area, wouldn't that be painful for you? Don't hit people period unless they ask you too, and even then say no.
The scrotum houses a high number of nerve endings (along with the testicles and many blood vessels) and has no bone or cartilage to protect the delicate organ tissue inside.
From the view of evolution, the primary purpose of the species is to reproduce and pass forward genes. Thus, the testicles have a very high sensitivity to pain to ensure they are protected at all costs.
There are so many nerves there for transmitting information to the brain for sexual pleasure and procreation. In the same way pain will be transmitted fast and easily.